private TermComboElement<DefinedTerm> combo_preservationMethod;
- private SpecimenCollectionDetailSection section_duplicates;
-
private SourceCollectionDetailSection section_source;
private OriginalLabelDataElement textOriginalLabel;
private DerivedUnitMediaSection mediaDetailElement;
-
+
/**
this.showOnlyDerivedUnitData = showOnlyDerivedUnitData;
}
- /** {@inheritDoc} */
@Override
protected void createControls(ICdmFormElement formElement, DerivedUnitFacade entity, int style) {
// Disable for now
super.createControls(formElement, entity, style);
-
-
+
+
section_source = formFactory.createSourceCollectionDetailSection(getConversationHolder(), formElement, StoreUtil.getSectionStyle(SourceCollectionDetailSection.class, entity.getClass().getCanonicalName()));
section_source.setLayoutData(LayoutConstants.FILL_HORIZONTALLY(2, 1));
section_source.setEntity(entity);
* The contents of this file are subject to the Mozilla Public License Version 1.1
* See LICENSE.TXT at the top of this package for the full license terms.
*/
-
package eu.etaxonomy.taxeditor.ui.section.occurrence;
import eu.etaxonomy.cdm.api.facade.DerivedUnitFacade;
-import eu.etaxonomy.cdm.model.agent.AgentBase;
import eu.etaxonomy.cdm.model.agent.Person;
import eu.etaxonomy.cdm.model.agent.Team;
import eu.etaxonomy.cdm.model.common.LanguageString;
import eu.etaxonomy.cdm.model.location.NamedArea;
import eu.etaxonomy.cdm.model.occurrence.Collection;
-import eu.etaxonomy.cdm.model.occurrence.OccurrenceStatus;
import eu.etaxonomy.cdm.model.occurrence.SpecimenOrObservationType;
-import eu.etaxonomy.cdm.model.term.DefinedTerm;
-import eu.etaxonomy.cdm.model.term.DefinedTermBase;
import eu.etaxonomy.taxeditor.preference.PreferencesUtil;
import eu.etaxonomy.taxeditor.store.StoreUtil;
import eu.etaxonomy.taxeditor.ui.combo.EnumComboElement;
-import eu.etaxonomy.taxeditor.ui.combo.term.TermComboElement;
import eu.etaxonomy.taxeditor.ui.element.CdmFormFactory;
import eu.etaxonomy.taxeditor.ui.element.CheckboxElement;
import eu.etaxonomy.taxeditor.ui.element.GatheringEventUnitElement;
/**
* @author n.hoffmann
* @created Dec 16, 2010
- * @version 1.0
*/
public class DerivedUnitGeneralDetailElement extends
AbstractCdmDetailElement<DerivedUnitFacade> {
combo_specorobstype = formFactory.createEnumComboElement(SpecimenOrObservationType.class, formElement, style);
combo_specorobstype.setSelection(entity.getType());
combo_specorobstype.setEnabled(showSpecimenType);
- selection_country = formFactory.createSelectionElement(NamedArea.class, //getConversationHolder(),
+ selection_country = formFactory.createSelectionElement(NamedArea.class,
formElement, "Country",
entity.getCountry(), EntitySelectionElement.DELETABLE, style);
text_accessionNumber = formFactory.createTextWithLabelElement(
formElement, "Accession Number", entity.getAccessionNumber(),
style);
+ text_barcode = formFactory.createTextWithLabelElement(formElement, "Barcode", entity.getBarcode(), style);
+
uriPreferredStableUri = formFactory.createUriWithLabelElement(formElement, "Pref. Stable URI", entity.getPreferredStableUri(), style);
section_status = formFactory.createStatusCollectionDetailSection(getConversationHolder(), formElement, StoreUtil.getSectionStyle(SourceCollectionDetailSection.class, entity.getClass().getCanonicalName()));
section_status.setLayoutData(LayoutConstants.FILL_HORIZONTALLY(2, 1));
section_status.setEntity(entity);
-
+
checkIsPublish = formFactory.createCheckbox(formElement, "Publish", entity.innerDerivedUnit().isPublish(), style);
}
* The contents of this file are subject to the Mozilla Public License Version 1.1
* See LICENSE.TXT at the top of this package for the full license terms.
*/
-
package eu.etaxonomy.taxeditor.ui.section.occurrence.derivedUnit;
import eu.etaxonomy.cdm.model.name.TaxonName;
import eu.etaxonomy.taxeditor.ui.element.LayoutConstants;
import eu.etaxonomy.taxeditor.ui.element.TextWithLabelElement;
import eu.etaxonomy.taxeditor.ui.section.AbstractCdmDetailElement;
-import eu.etaxonomy.taxeditor.ui.section.occurrence.SpecimenCollectionDetailSection;
import eu.etaxonomy.taxeditor.ui.selection.EntitySelectionElement;
/**
- * <p>
- * DerivedUnitBaseDetailElement class.
- * </p>
- *
* @author n.hoffmann
* @created Jun 24, 2010
- * @version 1.0
*/
public class PreservedSpecimenDetailElement extends
AbstractCdmDetailElement<DerivedUnit> {
private TermComboElement<DefinedTerm> combo_preservationMethod;
- private SpecimenCollectionDetailSection section_duplicates;
-
private PreservedSpecimenSourceCollectionDetailSection section_source;
/**
super(formFactory, formElement);
}
- /** {@inheritDoc} */
@Override
protected void createControls(ICdmFormElement formElement, DerivedUnit entity, int style) {
// Disable for now
section_source.setEntity(entity);
}
- /** {@inheritDoc} */
@Override
public void handleEvent(Object eventSource) {
if (eventSource == text_derivedUnitDefinitions) {
/**
* @author pplitzner
* @date 17.12.2013
- *
*/
public class PreservedSpecimenGeneralDetailElement extends AbstractCdmDetailElement<DerivedUnit> {
private EntitySelectionElement<Collection> selection_collection;
private TextWithLabelElement text_accessionNumber;
-
- /**
- * @param formFactory
- * @param formElement
- */
public PreservedSpecimenGeneralDetailElement(CdmFormFactory formFactory,
ICdmFormElement formElement) {
super(formFactory, formElement);
}
- /*
- * (non-Javadoc)
- *
- * @see
- * eu.etaxonomy.taxeditor.section.AbstractCdmDetailElement#createControls
- * (eu.etaxonomy.taxeditor.forms.ICdmFormElement, java.lang.Object, int)
- */
@Override
protected void createControls(ICdmFormElement formElement,
DerivedUnit entity, int style) {
formElement, "Title Cache", entity.getTitleCache(),
entity.isProtectedTitleCache(), style);
selection_collection = formFactory
- .createSelectionElement(Collection.class,//getConversationHolder(),
+ .createSelectionElement(Collection.class,
formElement, "Collection",
entity.getCollection(),
EntitySelectionElement.ALL, style);
style);
}
- /*
- * (non-Javadoc)
- *
- * @see
- * eu.etaxonomy.taxeditor.section.AbstractCdmDetailElement#handleEvent(java
- * .lang.Object)
- */
@Override
public void handleEvent(Object eventSource) {
if (eventSource == toggleableText_titleCache) {
} else if (eventSource == text_accessionNumber) {
getEntity().setAccessionNumber(text_accessionNumber.getText());
}
+
if (eventSource != toggleableText_titleCache) {
toggleableText_titleCache.setText(getEntity().getTitleCache());
}
}
-
}