public static String RemotingMoveTaxonNodeHandler_TARGET_NODE_MESSAGE;
public static String RemotingMoveTaxonNodeHandler_UNSAVED_PARENT;
public static String RemotingMoveTaxonNodeHandler_UNSAVED_PARENT_MESSAGE;
+ public static String RemotingMoveTaxonNodeHandler_DIFFERENT_PUBLISH_TITLE;
+ public static String RemotingMoveTaxonNodeHandler_DIFFERENT_PUBLISH_MESSAGE;
public static String RemotingMoveTaxonOperation_MOVE_OP;
public static String RemotingUpdatePolytomousKeyAllNodesOperation_UPDATE_OP;
public static String Root_CREATE_CLASSIFICATION;
RemotingMoveTaxonNodeHandler_TARGET_NODE_MESSAGE=Do you want to move the Taxonnode as child or behind the target node.
RemotingMoveTaxonNodeHandler_UNSAVED_PARENT=Unsaved Parent Taxon
RemotingMoveTaxonNodeHandler_UNSAVED_PARENT_MESSAGE=There are unsaved changes in the parent taxon. Please save first.
+RemotingMoveTaxonNodeHandler_DIFFERENT_PUBLISH_TITLE=Different publish states
+RemotingMoveTaxonNodeHandler_DIFFERENT_PUBLISH_MESSAGE=The new parent taxon and the moved taxon/taxa do not have the same publish status.
RemotingMoveTaxonOperation_MOVE_OP=Move Taxon operation
RemotingUpdatePolytomousKeyAllNodesOperation_UPDATE_OP=Update All Polytomous Key Nodes operation
Root_CREATE_CLASSIFICATION=Creating initial classification
RemotingMoveTaxonNodeHandler_TARGET_NODE_MESSAGE=Wollen Sie den Taxonknoten als Kind oder hinter den Zielknoten verschieben.
RemotingMoveTaxonNodeHandler_UNSAVED_PARENT=Ungespeichertes Eltern-Taxon
RemotingMoveTaxonNodeHandler_UNSAVED_PARENT_MESSAGE=Es gibt ungespeicherte Änderungen im Eltern-Taxon. Bitte speichen Sie erst.
+RemotingMoveTaxonNodeHandler_DIFFERENT_PUBLISH_TITLE=Unterschiedliche Publikationsstatus
+RemotingMoveTaxonNodeHandler_DIFFERENT_PUBLISH_MESSAGE=Das neue Elterntaxon und das verschobene Taxon bzw. die verschobenen Taxa haben unterschiedliche Publikationsstatus.
RemotingMoveTaxonOperation_MOVE_OP=Taxon verschieben
RemotingUpdatePolytomousKeyAllNodesOperation_UPDATE_OP=Alle polytomen Schlüssel updaten
Root_CREATE_CLASSIFICATION=Initiale Klassifikation erstellen
this.targetITaxonTreeNode = targetITaxonTreeNode;
Set<UUID> uuids = new HashSet<UUID>();
TaxonNodeDto node = null;
+ boolean targetIsPublish = targetITaxonTreeNode.isPublish();
+ boolean isPublishEqual = true;
while(taxIterator.hasNext()){
node = taxIterator.next();
uuids.add(node.getUuid());
+ isPublishEqual &= targetIsPublish == node.isPublish();
}
+ if (!isPublishEqual){
+ MessageDialog.openWarning(null, "Publish status differ", Messages.RemotingChangeAcceptedTaxonToSynonym_warning_publish);
+ }
+
IUndoContext workspaceUndoContext = taxonNavigator.getUndoContext();
int movingTypeInt = 0;
if (PreferencesUtil.isNodesSortedNaturally()){
Set<UUID> excludeTaxa = new HashSet<>();
Set<UUID> secUuids = new HashSet<>();
Set<UUID> nodeUuids = new HashSet();
+ boolean published = true;
for (TaxonNodeDto oldNode:oldTaxonNodes){
excludeTaxa.add(oldNode.getTaxonUuid());
secUuids.add(oldNode.getSecUuid());
nodeUuids.add(oldNode.getUuid());
+
}
TaxonNode newAcceptedTaxonNode = TaxonNodeSelectionDialog.select(shell,
// new ConversationHolderMock(),
}
+
RemotingChangeAcceptedTaxonToSynonymOperation rcattso =
new RemotingChangeAcceptedTaxonToSynonymOperation(getTrigger(),
false,
private Set<UUID> oldTaxonNodeUUIDs = new HashSet<>();
private TaxonNavigatorE4 navigator;
private UUID classificationUuid = null;
+ boolean isPublish = true;
public RemotingMoveTaxonNodeHandlerE4() {
super(TaxonNavigatorLabels.MOVE_TAXON_LABEL);
obj = iter.next();
if(obj instanceof TaxonNodeDto) {
oldTaxonNodeUUIDs.add(((TaxonNodeDto)obj).getUuid());
+ isPublish &= ((TaxonNodeDto)obj).isPublish();
if (classificationUuid == null){
classificationUuid = ((TaxonNodeDto)obj).getClassificationUUID();
}
classificationUuid, true);
}
+ if (parentTaxonNode.getTaxon().isPublish() != isPublish){
+ MessageDialog.openWarning(shell,
+ Messages.RemotingMoveTaxonNodeHandler_DIFFERENT_PUBLISH_TITLE,
+ Messages.RemotingMoveTaxonNodeHandler_DIFFERENT_PUBLISH_MESSAGE);
+ }
if(parentTaxonNode != null){
if(NavigationUtil.isDirty(parentTaxonNode, partService)){
}
}
- if ( oldTaxaPublished != newTaxon.isPublish()){
+ if (newTaxon != null && oldTaxaPublished != newTaxon.isPublish()){
MessagingUtils.warningDialog("Publish flag", null, Messages.RemotingChangeAcceptedTaxonToSynonym_warning_publish);
}
updateNameEditor();