ref #9838: change order of ui element creation and setting entity in collection elements
[taxeditor.git] / eu.etaxonomy.taxeditor.store / src / main / java / eu / etaxonomy / taxeditor / ui / section / vocabulary / RecommendedModifierDtoVocabulariesElement.java
index 5120e5c1cdb3a39258a95d7fbce762163ac28e63..8788e50bb9290e9026fb66c02e33069dceaf9d51 100755 (executable)
@@ -50,15 +50,18 @@ public class RecommendedModifierDtoVocabulariesElement extends AbstractEntityCol
     @Override
     public void createControls(ICdmFormElement element, int style) {
         comboStateVocabulary = formFactory.createVocabularyComboElement(TermType.Modifier, "Modifier Vocabulary", null, element, style);
+        if (entity != null){
+               setEntity(entity);
+        }
     }
 
     @Override
     public void setEntity(TermVocabularyDto entity) {
         this.entity = entity;
-//        if(entity.getId()!=0){
+        if(comboStateVocabulary != null){
             comboStateVocabulary.setSelectionDto(entity);
             comboStateVocabulary.removeEmptyElement();
-//        }
+        }
     }