Project

General

Profile

« Previous | Next » 

Revision 46bdf341

Added by Katja Luther about 3 years ago

ref #9533: fix NPE in taxonnode detail element

View differences:

eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/classification/TaxonNodeDetailElement.java
138 138
                    .createSelectionElement(Taxon.class,//getConversationHolder(),
139 139
                            formElement,
140 140
                            REUSE_EXISTING_TAXON, null,
141
                            EntitySelectionElement.DELETABLE, style);
141
                            EntitySelectionElement.SELECTABLE, style);
142 142
	        selection_reuseExistingTaxon.setIndent(10);
143 143
            selection_reuseExistingName = formFactory
144 144
                    .createSelectionElement(TaxonName.class,//getConversationHolder(),
......
183 183
	        selection_reuseExistingTaxon = formFactory
184 184
                  .createSelectionElement(Taxon.class, formElement,
185 185
                          Messages.TaxonNodeWizardPage_TAXON, taxon,
186
                          EntitySelectionElement.DELETABLE, SWT.NULL);
186
                          EntitySelectionElement.SELECTABLE, SWT.NULL);
187 187

  
188 188
	        selection_reuseExistingTaxon.setIndent(10);
189 189
	        textTaxonSec = formFactory.createTextWithLabelElement(formElement,SECUNDUM_REFERENCE, "", SWT.NULL);
......
344 344
		            checkbox_publish.setSelected(getTaxon().isPublish());
345 345
		        }
346 346
            }else{
347
                selection_SecRef.setEntity(null);
347
                if (isCreateNew()){
348
                    selection_SecRef.setEntity(null);
349
                }else{
350
                    textTaxonSec.setText(null);
351
                }
348 352
                setDefaultPublish();
349 353
            }
350 354
		    boolean enabled = selection_reuseExistingTaxon.getEntity() == null;
......
506 510
				secundum = this.selection_SecRef.getEntity();
507 511
			}
508 512
		}
513
		textNewTaxonName.setText(taxonName.getTitleCache());
509 514

  
510 515
	}
511 516

  

Also available in: Unified diff