Project

General

Profile

Revision d4cccf9c

IDd4cccf9c745354a2a58a3cabdefc84840972825e
Parent 47ce5432
Child b9492486

Added by Patrick Plitzner over 1 year ago

ref #8146 Add termType to vocabulary selection dialog

View differences:

eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/newWizard/NewFeatureVocabularyWizard.java
9 9
package eu.etaxonomy.taxeditor.newWizard;
10 10

  
11 11
import eu.etaxonomy.cdm.api.service.IVocabularyService;
12
import eu.etaxonomy.cdm.model.common.DefinedTermBase;
12 13
import eu.etaxonomy.cdm.model.common.TermType;
13 14
import eu.etaxonomy.cdm.model.common.TermVocabulary;
14 15
import eu.etaxonomy.taxeditor.store.CdmStore;
......
22 23

  
23 24
    private VocabularyWizardPage vocabularyPage;
24 25

  
26
    private TermType termType;
27

  
28
    public NewFeatureVocabularyWizard(TermType termType) {
29
        this.termType = termType;
30
    }
31

  
25 32
    @Override
26 33
    public void addPages() {
27 34
        vocabularyPage = new VocabularyWizardPage(formFactory, getConversationHolder(), getEntity());
......
30 37

  
31 38
    @Override
32 39
    protected TermVocabulary createNewEntity() {
40
        if(termType!=null){
41
            return TermVocabulary.NewInstance(termType);
42
        }
33 43
        return TermVocabulary.NewInstance(TermType.Feature);
34 44
    }
35 45

  
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/dialog/selection/TermVocabularySelectionDialog.java
80 80

  
81 81
	@Override
82 82
	protected AbstractNewEntityWizard getNewEntityWizard(String parameter) {
83
        return new NewFeatureVocabularyWizard();
83
        return new NewFeatureVocabularyWizard(termType);
84 84
	}
85 85

  
86 86
}

Also available in: Unified diff

Add picture from clipboard (Maximum size: 40 MB)