// $Id$
/**
* Copyright (C) 2007 EDIT
-* European Distributed Institute of Taxonomy
+* European Distributed Institute of Taxonomy
* http://www.e-taxonomy.eu
-*
+*
* 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.preference.menu;
-import eu.etaxonomy.cdm.model.occurrence.PreservationMethod;
+import eu.etaxonomy.cdm.model.common.DefinedTerm;
/**
* <p>PreservationMethodMenuPreferences class.</p>
* @created Jun 25, 2010
* @version 1.0
*/
-public class PreservationMethodMenuPreferences extends AbstractMenuPreferences<PreservationMethod> {
-
+public class PreservationMethodMenuPreferences extends AbstractMenuPreferences<DefinedTerm> {
+//FIXME:3.3MC---- see Ticket #3732
+//extends AbstractMenuPreferences<PreservationMethod> {
+ //FIXME:3.3MC----
+
/**
* <p>Constructor for PreservationMethodMenuPreferences.</p>
*/
public PreservationMethodMenuPreferences() {
- super("Preservation Method Preferences",
- "Select preservation methods to be shown in selections",
+ super("Preservation Method Preferences",
+ "Select preservation methods to be shown in selections",
false);
}
*/
/** {@inheritDoc} */
@Override
- protected Class<PreservationMethod> getTermClass() {
- return PreservationMethod.class;
+ protected Class<DefinedTerm> getTermClass() {
+ return DefinedTerm.class;
}
}
// $Id$
/**
* Copyright (C) 2007 EDIT
- * European Distributed Institute of Taxonomy
+ * European Distributed Institute of Taxonomy
* http://www.e-taxonomy.eu
- *
+ *
* 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.
*/
import eu.etaxonomy.cdm.api.facade.DerivedUnitFacade;
import eu.etaxonomy.cdm.api.facade.MethodNotSupportedByDerivedUnitTypeException;
-import eu.etaxonomy.cdm.model.name.NomenclaturalCode;
import eu.etaxonomy.cdm.model.name.TaxonNameBase;
-import eu.etaxonomy.cdm.model.occurrence.PreservationMethod;
-import eu.etaxonomy.cdm.model.occurrence.SpecimenOrObservationType;
import eu.etaxonomy.taxeditor.model.AbstractUtility;
import eu.etaxonomy.taxeditor.store.CdmStore;
-import eu.etaxonomy.taxeditor.ui.combo.EnumComboElement;
-import eu.etaxonomy.taxeditor.ui.combo.TermComboElement;
import eu.etaxonomy.taxeditor.ui.element.CdmFormFactory;
import eu.etaxonomy.taxeditor.ui.element.ICdmFormElement;
import eu.etaxonomy.taxeditor.ui.element.LayoutConstants;
* <p>
* DerivedUnitBaseDetailElement class.
* </p>
- *
+ *
* @author n.hoffmann
* @created Jun 24, 2010
* @version 1.0
private EntitySelectionElement<TaxonNameBase> selection_storedUnder;
private TextWithLabelElement text_exsicatum;
-
-
- private TermComboElement<PreservationMethod> combo_preservationMethod;
+
+ //FIXME:3.3MC---- see Ticket #3732
+// private TermComboElement<PreservationMethod> combo_preservationMethod;
+ //FIXME:3.3MC----
private SpecimenCollectionDetailSection section_duplicates;
* <p>
* Constructor for DerivedUnitBaseDetailElement.
* </p>
- *
+ *
* @param formFactory
* a {@link eu.etaxonomy.taxeditor.ui.element.CdmFormFactory}
* object.
text_barcode = formFactory.createTextWithLabelElement(formElement, "Barcode", entity.getBarcode(), style);
text_catalogNumber = formFactory.createTextWithLabelElement(formElement, "Catalog Number", entity.getCatalogNumber(), style);
-
- try {
- combo_preservationMethod = formFactory.createTermComboElement(PreservationMethod.class, formElement, "Preservation Method", entity.getPreservationMethod(), style);
- } catch (MethodNotSupportedByDerivedUnitTypeException e) {
- // we ignore this
- AbstractUtility.info(e.getMessage());
- }
+
+ //FIXME:3.3MC----
+// try {
+// combo_preservationMethod = formFactory.createTermComboElement(PreservationMethod.class, formElement, "Preservation Method", entity.getPreservationMethod(), style);
+// } catch (MethodNotSupportedByDerivedUnitTypeException e) {
+// // we ignore this
+// AbstractUtility.info(e.getMessage());
+// }
+ //FIXME:3.3MC----
selection_storedUnder = formFactory.createSelectionElement(TaxonNameBase.class, getConversationHolder(), formElement, "Stored Under", entity.getStoredUnder(), EntitySelectionElement.ALL, style);
try {
getEntity().setBarcode(text_barcode.getText());
} else if (eventSource == text_catalogNumber) {
getEntity().setCatalogNumber(text_catalogNumber.getText());
- } else if (eventSource == combo_preservationMethod) {
- try {
- getEntity().setPreservationMethod(
- combo_preservationMethod.getSelection());
- } catch (MethodNotSupportedByDerivedUnitTypeException e) {
- AbstractUtility
- .errorDialog(
- "MethodNotSupportedByDerivedUnitTypeException",
- this,
- "MethodNotSupportedByDerivedUnitTypeException when trying to set preservation method for derive unit",
- e);
- }
+ //FIXME:3.3MC----
+// } else if (eventSource == combo_preservationMethod) {
+// try {
+// getEntity().setPreservationMethod(
+// combo_preservationMethod.getSelection());
+// } catch (MethodNotSupportedByDerivedUnitTypeException e) {
+// AbstractUtility
+// .errorDialog(
+// "MethodNotSupportedByDerivedUnitTypeException",
+// this,
+// "MethodNotSupportedByDerivedUnitTypeException when trying to set preservation method for derive unit",
+// e);
+// }
+ //FIXME:3.3MC----
} else if (eventSource == selection_storedUnder) {
getEntity().setStoredUnder(selection_storedUnder.getEntity());
} else if (eventSource == text_exsicatum) {