Remove vocabulary from cache when its terms are edited
authorPatrick Plitzner <p.plitzner@bgbm.org>
Wed, 22 May 2019 10:04:58 +0000 (12:04 +0200)
committerPatrick Plitzner <p.plitzner@bgbm.org>
Wed, 22 May 2019 10:04:58 +0000 (12:04 +0200)
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/editor/definedterm/e4/DefinedTermEditorE4.java

index 35d5d8df78d99cb8a5a6e292a018e4862f359a0e..d9225ab5a93a151f7d917a81304fb3925cf4ed6c 100644 (file)
@@ -241,12 +241,14 @@ IPartContentHasDetails, IPartContentHasSupplementalData, IE4SavablePart, IContex
             TermDto termDto = TermDto.fromTerm(definedTermBase);
                viewer.update(termDto, null);
                changedTerms.add(definedTermBase);
+            contentProvider.removeVocabularyFromCache(termDto.getVocabularyDto());
            }
            else if(element instanceof TermVocabulary){
                TermVocabulary vocabulary = (TermVocabulary)element;
                TermVocabularyDto vocabularyDto = new TermVocabularyDto(vocabulary.getUuid(), vocabulary.getRepresentations(), vocabulary.getTermType());
                viewer.update(vocabularyDto, null);
                changedTerms.add(vocabulary);
+            contentProvider.removeVocabularyFromCache(vocabularyDto);
            }
                setDirty(true);
                viewer.update(element, null);