- moved OriginalLabelData to specimen details section (#4776)
authorPatric Plitzner <p.plitzner@bgbm.org>
Tue, 26 May 2015 08:28:06 +0000 (08:28 +0000)
committerPatric Plitzner <p.plitzner@bgbm.org>
Tue, 26 May 2015 08:28:06 +0000 (08:28 +0000)
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/occurrence/DerivedUnitBaseDetailElement.java
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/view/detail/DetailsViewer.java

index e67aaaf80293886b14adaeddef50f59d5a338a4c..7c589fe5042dfedf57447abc3591a0001db5a84f 100644 (file)
@@ -24,6 +24,7 @@ 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;
+import eu.etaxonomy.taxeditor.ui.element.OriginalLabelDataElement;
 import eu.etaxonomy.taxeditor.ui.element.TextWithLabelElement;
 import eu.etaxonomy.taxeditor.ui.section.AbstractCdmDetailElement;
 import eu.etaxonomy.taxeditor.ui.selection.EntitySelectionElement;
@@ -56,6 +57,8 @@ public class DerivedUnitBaseDetailElement extends
 
        private SourceCollectionDetailSection section_source;
 
+    private OriginalLabelDataElement textOriginalLabel;
+
        /**
         * <p>
         * Constructor for DerivedUnitBaseDetailElement.
@@ -113,6 +116,9 @@ public class DerivedUnitBaseDetailElement extends
         section_source = formFactory.createSourceCollectionDetailSection(getConversationHolder(), formElement, ExpandableComposite.TWISTIE);
                section_source.setLayoutData(LayoutConstants.FILL_HORIZONTALLY(2, 1));
                section_source.setEntity(entity);
+
+        textOriginalLabel = formFactory.createOriginalLabelDataElement(formElement);
+        textOriginalLabel.setEntity(getEntity());
        }
 
     /** {@inheritDoc} */
index 67ec1c0d5a366d4ff2319e6cbbc1d47d0bed94ae..bd6ce27ad4d1129158cf94543be077144abe38c3 100644 (file)
@@ -90,7 +90,6 @@ import eu.etaxonomy.taxeditor.ui.section.occurrence.EmptySection;
 import eu.etaxonomy.taxeditor.ui.section.occurrence.FieldUnitDetailSection;
 import eu.etaxonomy.taxeditor.ui.section.occurrence.FieldUnitGeneralDetailSection;
 import eu.etaxonomy.taxeditor.ui.section.occurrence.GatheringEventDetailSection;
-import eu.etaxonomy.taxeditor.ui.section.occurrence.OriginalLabelDataSection;
 import eu.etaxonomy.taxeditor.ui.section.occurrence.association.TaxonAssociationDetailSection;
 import eu.etaxonomy.taxeditor.ui.section.occurrence.dna.DnaQualityDetailSection;
 import eu.etaxonomy.taxeditor.ui.section.occurrence.dna.DnaSampleGeneralDetailSection;
@@ -227,7 +226,7 @@ public class DetailsViewer extends AbstractCdmDataViewer {
             }
             else{
                 Set<Marker> descriptionMarkers = ((DescriptionBase<?>) input).getMarkers();
-               
+
                 Boolean isUseDescription = false;
                 for (Marker marker : descriptionMarkers) {
                     if (marker.getMarkerType()!= null && marker.getMarkerType().getUuid().equals(UsageTermCollection.uuidUseMarkerType)) {
@@ -246,7 +245,7 @@ public class DetailsViewer extends AbstractCdmDataViewer {
             }
         } else if (input instanceof DescriptionElementBase) {
             Set<Marker> descriptionMarkers = ((DescriptionElementBase) input).getInDescription().getMarkers();
-               
+
             Boolean isUseDescription = false;
             for (Marker marker : descriptionMarkers) {
                 if (marker.getMarkerType()!= null && marker.getMarkerType().getUuid().equals(UsageTermCollection.uuidUseMarkerType)) {
@@ -650,11 +649,6 @@ public class DetailsViewer extends AbstractCdmDataViewer {
         DerivedUnitBaseDetailSection derivedUnitBaseDetailSection = formFactory.createDerivedUnitBaseDetailSection(getConversationHolder(), parent, this, ExpandableComposite.TWISTIE | ExpandableComposite.EXPANDED);
         addPart(derivedUnitBaseDetailSection);
 
-        formFactory.createHorizontalSeparator(parent, SWT.BORDER);
-
-        OriginalLabelDataSection originalLabelDataSection = formFactory.createOriginalLabelDataSection(getConversationHolder(), parent, this, ExpandableComposite.TWISTIE);
-        addPart(originalLabelDataSection);
-
         //for editors working with facades
         if(AbstractUtility.getActivePart() instanceof IDerivedUnitFacadePart){
             formFactory.createHorizontalSeparator(parent, SWT.BORDER);
@@ -676,7 +670,11 @@ public class DetailsViewer extends AbstractCdmDataViewer {
             TaxonAssociationDetailSection taxonAssociationDetailSection = formFactory.createTaxonAssociationDetailSection(getConversationHolder(), parent, this, ExpandableComposite.TWISTIE | ExpandableComposite.EXPANDED);
             addPart(taxonAssociationDetailSection);
         }
-        
+
+//        formFactory.createHorizontalSeparator(parent, SWT.BORDER);
+//        IdentifierDetailSection identifierDetailSection = formFactory.createIdentifierDetailSection(getConversationHolder(), parent, ExpandableComposite.TWISTIE);
+//        addPart(identifierDetailSection);
+
     }
 
     private void createFieldUnitSection(RootElement parent) {