Hello guys,
I get alerts now every time I change the name of a node in the
GenericDataAdminTree. I does not matter if the node is content or a folder. It
alerts "can't rename node bla/bla", but then the node IS actually renamed. It
is all due to this method in the class mentioned:
public String renameNode(String newLabel) throws AccessDeniedException,
ExchangeException, PathNotFoundException, RepositoryException {
String result = super.renameNode(newLabel);
if (!getHierarchyManager().isNodeData(this.getPath())) {
Content current = getHierarchyManager().getContent(this.getPath());
Content dialogConfig =
DialogHandlerManager.getInstance().getDialogConfigNode(getDialogName());
String nameField = "name";
if (dialogConfig.hasNodeData(DataConsts.NODE_NAME_FIELD)) {
nameField =
dialogConfig.getNodeData(DataConsts.NODE_NAME_FIELD).getString();
}
NodeDataUtil.getOrCreateAndSet(current, nameField,
current.getName());
current.save();
}
return result;
}
The first line of the method does the correct renaming, but then at line 3, the
error occurs. I have been staring at this code for a bit now, but I have no
clue to what it actually should be performing? If I take the whole if-block
out, everything seems to be working fine. Any help is appreciated!
Bye, Bert
----------------------------------------------------------------
For list details see
http://www.magnolia-cms.com/home/community/mailing-lists.html
To unsubscribe, E-mail to: <[email protected]>
----------------------------------------------------------------