Project

General

Profile

Revision 3000a28d

ID3000a28df096b59e7e287786a530f33f729bde5a
Parent 7fa459c8
Child 35a38115

Added by Andreas Kohlbecker about 2 years ago

ref #8365 stripping collection code from accession number only if followed by whitespace

View differences:

cdmlib-services/src/main/java/eu/etaxonomy/cdm/api/facade/DerivedUnitFacadeCacheStrategy.java
103 103
            result = facade.getAccessionNumber();
104 104
            String code = getCode(facade);
105 105
            result = result.trim();
106
            if(isNotBlank(code) && result.startsWith(code)){
107
                result = result.replaceAll("^" + code, "");
106
            if(isNotBlank(code) && result.startsWith(code + " ")){
107
                result = result.replaceAll("^" + code + "\\s", "");
108 108
            }
109 109
        }else if (isNotBlank(facade.getBarcode())){
110 110
            result = facade.getBarcode();
cdmlib-services/src/main/java/eu/etaxonomy/cdm/api/service/name/TypeDesignationSetManager.java
663 663
                    } else {
664 664
                        DerivedUnitFacadeCacheStrategy cacheStrategy = new DerivedUnitFacadeCacheStrategy();
665 665
                        String titleCache = cacheStrategy.getTitleCache(du, true);
666
                        // removing parentheses from accesssion number, see https://dev.e-taxonomy.eu/redmine/issues/8365
666
                        // removing parentheses from code + accession number, see https://dev.e-taxonomy.eu/redmine/issues/8365
667 667
                        titleCache = titleCache.replaceAll("[\\(\\)]", "");
668 668
                        typeSpecimenTitle += titleCache;
669 669

  

Also available in: Unified diff

Add picture from clipboard (Maximum size: 40 MB)