Remove dot at the end of derivative labels
authorPatrick Plitzner <p.plitzner@bgbm.org>
Wed, 21 Jun 2017 08:53:45 +0000 (10:53 +0200)
committerPatrick Plitzner <p.plitzner@bgbm.org>
Wed, 21 Jun 2017 08:53:45 +0000 (10:53 +0200)
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/view/derivateSearch/DerivateLabelProvider.java

index 7ca576b65ad48511ee33eb4914f9e63e38375f94..91c08921aea19b6bc5f2b6d99f16d2910685c3dd 100644 (file)
@@ -148,9 +148,8 @@ public class DerivateLabelProvider extends ColumnLabelProvider {
 
         //Use titlecache for FieldUnits
         if(element instanceof FieldUnit){
-            return ((FieldUnit) element).getTitleCache();
+            text = ((FieldUnit) element).getTitleCache();
         }
-
         else if(element instanceof MediaSpecimen){
             text = CdmFormatterFactory.format(element,
                     new FormatKey[]{
@@ -203,6 +202,10 @@ public class DerivateLabelProvider extends ColumnLabelProvider {
             else{
                 text = element.toString();
             }
+        }
+        //remove dot at the end
+        if(text.endsWith(".")){
+            text = text.substring(0, text.length()-1);
         }
                return text;
     }