ref #10288: add second publisher information to editor
authorKatja Luther <k.luther@bgbm.org>
Mon, 27 Mar 2023 08:19:35 +0000 (10:19 +0200)
committerKatja Luther <k.luther@bgbm.org>
Mon, 27 Mar 2023 08:19:35 +0000 (10:19 +0200)
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/reference/ReferenceDetailElement.java

index 57f881dd830d4527512236689e9fd67bf1005412..f7e53cebb2e1a0085ddb88cbd7680f8192e659d4 100644 (file)
@@ -57,7 +57,9 @@ public class ReferenceDetailElement extends AbstractIdentifiableEntityDetailElem
        private TextWithLabelElement text_organisation;
        private TextWithLabelElement text_pages;
        private TextWithLabelElement text_placePublished;
+       private TextWithLabelElement text_placePublished2;
        private TextWithLabelElement text_publisher;
+       private TextWithLabelElement text_publisher2;
        private TextWithLabelElement text_referenceAbstract;
        private TextWithLabelElement text_series;
 //     private TextWithLabelElement text_seriesPart;
@@ -304,6 +306,14 @@ public class ReferenceDetailElement extends AbstractIdentifiableEntityDetailElem
                // publisher
                text_publisher = formFactory.createTextWithLabelElement(element,
                                "Publisher", reference.getPublisher(), style);
+               
+               // placePublished2
+               text_placePublished2 = formFactory.createTextWithLabelElement(element,
+                                               "Second Place Published", reference.getPlacePublished2(), style);
+
+               // publisher2
+               text_publisher2 = formFactory.createTextWithLabelElement(element,
+                               "Second Publisher", reference.getPublisher2(), style);
 
                if (referenceType.equals(ReferenceType.Journal)) {
                        // issn
@@ -450,9 +460,13 @@ public class ReferenceDetailElement extends AbstractIdentifiableEntityDetailElem
                        getEntity().setPages(text_pages.getText());
                } else if (eventSource == text_placePublished) {
                        getEntity().setPlacePublished(text_placePublished.getText());
-               } else if (eventSource == text_publisher) {
+               }  else if (eventSource == text_placePublished2) {
+                       getEntity().setPlacePublished2(text_placePublished2.getText());
+               }else if (eventSource == text_publisher) {
                        getEntity().setPublisher(text_publisher.getText());
-               } else if (eventSource == text_referenceAbstract) {
+               } else if (eventSource == text_publisher2) {
+                       getEntity().setPublisher2(text_publisher2.getText());
+               }else if (eventSource == text_referenceAbstract) {
                        getEntity().setReferenceAbstract(text_referenceAbstract.getText());
                } else if (eventSource == text_series) {
                        getEntity().setSeriesPart(text_series.getText());
@@ -557,7 +571,7 @@ public class ReferenceDetailElement extends AbstractIdentifiableEntityDetailElem
 
                List<Object> except = new ArrayList<>();
 
-           except.addAll( Arrays.asList(new Object[] { toggleable_cache, toggleableAbbrevCache, text_editor, text_isbn, text_issn, text_organisation, text_pages, text_placePublished, text_publisher, text_referenceAbstract,  text_uri, selection_institution}));
+           except.addAll( Arrays.asList(new Object[] { toggleable_cache, toggleableAbbrevCache, text_editor, text_isbn, text_issn, text_organisation, text_pages, text_placePublished,text_placePublished2, text_publisher, text_publisher2, text_referenceAbstract,  text_uri, selection_institution}));
 
            if (abbrev){
              except.add(text_title);