Revision d82999cd
Added by Katja Luther over 2 years ago
eu.etaxonomy.taxeditor.store/src/main/java/eu/etaxonomy/taxeditor/ui/section/reference/ReferenceDetailElement.java | ||
---|---|---|
48 | 48 |
public class ReferenceDetailElement extends AbstractIdentifiableEntityDetailElement<Reference> |
49 | 49 |
implements IErrorIntolerableElement, IExceptionHandler { |
50 | 50 |
|
51 |
private ToggleableTextElement toggleableAbbrevCache; |
|
51 |
boolean isNomenclaturalReference = false; |
|
52 |
|
|
53 |
|
|
54 |
|
|
55 |
private ToggleableTextElement toggleableAbbrevCache; |
|
52 | 56 |
|
53 | 57 |
private TextWithLabelElement text_edition; |
54 | 58 |
private TextWithLabelElement text_editor; |
... | ... | |
97 | 101 |
ICdmFormElement formElement, int style) { |
98 | 102 |
super(cdmFormFactory, formElement); |
99 | 103 |
} |
104 |
|
|
105 |
public ReferenceDetailElement(CdmFormFactory cdmFormFactory, |
|
106 |
ICdmFormElement formElement, boolean isNomenclaturalReference, int style) { |
|
107 |
this(cdmFormFactory, formElement, style); |
|
108 |
this.isNomenclaturalReference = isNomenclaturalReference; |
|
109 |
|
|
110 |
} |
|
111 |
public boolean isNomenclaturalReference() { |
|
112 |
return isNomenclaturalReference; |
|
113 |
} |
|
114 |
|
|
115 |
public void setNomenclaturalReference(boolean isNomenclaturalReference) { |
|
116 |
this.isNomenclaturalReference = isNomenclaturalReference; |
|
117 |
} |
|
100 | 118 |
|
101 | 119 |
@Override |
102 | 120 |
protected void createControls(ICdmFormElement formElement, |
... | ... | |
125 | 143 |
ReferenceType referenceType = entity.getType(); |
126 | 144 |
// author team |
127 | 145 |
if(referenceType != null && !referenceType.equals(ReferenceType.Journal) && !referenceType.equals(ReferenceType.PrintSeries) ) { |
128 |
selection_authorTeam = formFactory |
|
129 |
.createSelectionElement(TeamOrPersonBase.class, |
|
130 |
formElement, "Author", |
|
131 |
entity.getAuthorship(), |
|
132 |
EntitySelectionElement.ALL, style); |
|
146 |
if (isNomenclaturalReference){ |
|
147 |
selection_authorTeam = formFactory |
|
148 |
.createSelectionElementWithAbbreviatedTitle(TeamOrPersonBase.class,getConversationHolder(), |
|
149 |
formElement, "Author", |
|
150 |
entity.getAuthorship(), |
|
151 |
EntitySelectionElement.ALL, style); |
|
152 |
}else{ |
|
153 |
selection_authorTeam = formFactory |
|
154 |
.createSelectionElement(TeamOrPersonBase.class, |
|
155 |
formElement, "Author", |
|
156 |
entity.getAuthorship(), |
|
157 |
EntitySelectionElement.ALL, style); |
|
158 |
} |
|
133 | 159 |
} |
134 | 160 |
|
135 | 161 |
if (referenceType != null) { |
Also available in: Unified diff
ref #9900: fix consistent use of abbrev title for authors of nomenclatural reference