always set a decent name for relational nodes ("prototype id"), and

always get the href of user objects right.
This commit is contained in:
hns 2001-07-27 13:37:22 +00:00
parent 7eddb2e9c1
commit 6ab83c5676

View file

@ -172,7 +172,14 @@ public class Node implements INode, Serializable {
String nameField = dbmap.getNameField ();
name = nameField == null ? id : rec.getValue (nameField).asString ();
if (name == null || name.length() == 0)
name = id;
name = m.getTypeName() + " " + id;
// set parent for user objects to internal userroot node
if ("user".equals (prototype)) {
this.parentID = "1";
this.parentmap = nmgr.getDbMapping("__userroot__");
anonymous = false;
}
created = lastmodified = System.currentTimeMillis ();
for (Enumeration e=dbmap.getDB2Prop ().elements (); e.hasMoreElements(); ) {