Project

General

Profile

« Previous | Next » 

Revision ff522f12

Added by Andreas Kohlbecker over 3 years ago

fix #8317 TaxonNamePopupEditor exAuthor only when != combinationAuthor

View differences:

src/main/java/eu/etaxonomy/cdm/vaadin/view/name/NameTypeDesignationPopupEditor.java
43 43
public class NameTypeDesignationPopupEditor extends AbstractCdmPopupEditor<NameTypeDesignation, NameTypeDesignationPresenter>
44 44
    implements NameTypeDesignationEditorView {
45 45

  
46
    private static final long serialVersionUID = 8233876984579344340L;
47

  
46 48
    private static final int GRID_COLS = 4;
47 49
    private static final int GRID_ROWS = 7;
48 50

  
src/main/java/eu/etaxonomy/cdm/vaadin/view/name/TaxonNamePopupEditor.java
630 630

  
631 631
    protected TeamOrPersonBase inferExCombinationAuthors() {
632 632
        NameRelationshipDTO nameRelationDTO = validationField.getValue();
633

  
634
        TeamOrPersonBase inferredExAuthor = null;
633 635
        if(nameRelationDTO != null && nameRelationDTO.getOtherName() != null){
634 636
            TaxonName validatedName = nameRelationDTO.getOtherName();
635 637
            if(validatedName.getCombinationAuthorship() != null) {
636
                return validatedName.getCombinationAuthorship();
638
                inferredExAuthor = validatedName.getCombinationAuthorship();
637 639
            } else if(validatedName.getNomenclaturalReference() != null){
638
                return validatedName.getNomenclaturalReference().getAuthorship();
640
                inferredExAuthor = validatedName.getNomenclaturalReference().getAuthorship();
639 641
            }
640 642
        }
641
        return null;
643
        if(inferredExAuthor != null && inferredExAuthor.equals(inferCombinationAuthors())) {
644
            // If and only if ex author = author the ex author is not included
645
            // into the author teams due to the ICN 46.10. (see #8317)
646
            inferredExAuthor = null;
647
        }
648
        return inferredExAuthor;
642 649
    }
643 650

  
644 651
    @Override

Also available in: Unified diff