Revision 0d795e97
Added by Katja Luther over 6 years ago
eu.etaxonomy.taxeditor.navigation/src/main/java/eu/etaxonomy/taxeditor/navigation/navigator/e4/TreeNodeDropAdapterE4.java | ||
---|---|---|
146 | 146 |
if (logger.isDebugEnabled()){ |
147 | 147 |
logger.debug("selectedTaxa: " + taxonNode.getTaxon() == null? "-" : taxonNode.getTaxon().getTitleCache()); //$NON-NLS-1$ |
148 | 148 |
} |
149 |
boolean isClassification = !taxonNode.hasTaxon(); |
|
150 |
if (isClassification) { |
|
151 |
if(logger.isDebugEnabled()){ |
|
152 |
logger.debug("CANCEL_STATUS for selected taxonNode " + taxonNode.getId()); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ |
|
153 |
} |
|
154 |
return false; |
|
155 |
} |
|
149 | 156 |
boolean isSameTaxonNode = taxonNode.equals(target); |
150 | 157 |
boolean hasTaxonNodePermission = CdmStore.currentAuthentiationHasPermission(taxonNode, UPDATE); |
151 |
boolean hasTaxonPermission = taxonNode.getTaxon() == null ? |
|
152 |
true :
|
|
158 |
|
|
159 |
boolean hasTaxonPermission =
|
|
153 | 160 |
CdmStore.currentAuthentiationHasPermission(taxonNode.getTaxon(), UPDATE);CdmStore.currentAuthentiationHasPermission(taxonNode.getTaxon(), UPDATE); |
154 | 161 |
if ( |
155 | 162 |
isSameTaxonNode |
156 | 163 |
|| !hasTaxonNodePermission |
157 | 164 |
|| !hasTaxonPermission |
158 |
) {
|
|
165 |
) {
|
|
159 | 166 |
if(logger.isDebugEnabled()){ |
160 | 167 |
logger.debug("CANCEL_STATUS for selected " + isSameTaxonNode + Messages.TreeNodeDropAdapter_10 + hasTaxonNodePermission + " " + hasTaxonPermission + " "); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ |
161 | 168 |
} |
Also available in: Unified diff
fix #7041: do not allow to drag a classification in taxonNavigator