(re)set relations to null if not specified
This commit is contained in:
parent
40c290efbc
commit
15127efd4d
1 changed files with 6 additions and 3 deletions
|
@ -133,7 +133,8 @@ public class DbMapping {
|
||||||
parent = parentRel.other;
|
parent = parentRel.other;
|
||||||
else
|
else
|
||||||
parent = (DbMapping) app.getDbMapping (parentMapping);
|
parent = (DbMapping) app.getDbMapping (parentMapping);
|
||||||
}
|
} else
|
||||||
|
parentRel = null;
|
||||||
|
|
||||||
String subnodeMapping = props.getProperty ("_subnodes");
|
String subnodeMapping = props.getProperty ("_subnodes");
|
||||||
if (subnodeMapping != null) {
|
if (subnodeMapping != null) {
|
||||||
|
@ -142,7 +143,8 @@ public class DbMapping {
|
||||||
subnodes = subnodesRel.other;
|
subnodes = subnodesRel.other;
|
||||||
else
|
else
|
||||||
subnodes = (DbMapping) app.getDbMapping (subnodeMapping);
|
subnodes = (DbMapping) app.getDbMapping (subnodeMapping);
|
||||||
}
|
} else
|
||||||
|
subnodesRel = null;
|
||||||
|
|
||||||
String propertiesMapping = props.getProperty ("_properties");
|
String propertiesMapping = props.getProperty ("_properties");
|
||||||
if (propertiesMapping != null) {
|
if (propertiesMapping != null) {
|
||||||
|
@ -154,7 +156,8 @@ public class DbMapping {
|
||||||
// take over groupby flag from subnodes, if properties are subnodes
|
// take over groupby flag from subnodes, if properties are subnodes
|
||||||
if (propertiesRel.subnodesAreProperties && subnodesRel != null)
|
if (propertiesRel.subnodesAreProperties && subnodesRel != null)
|
||||||
propertiesRel.groupby = subnodesRel.groupby;
|
propertiesRel.groupby = subnodesRel.groupby;
|
||||||
}
|
} else
|
||||||
|
propertiesRel = null;
|
||||||
|
|
||||||
IServer.getLogger().log ("rewiring: "+parent+" -> "+this+" -> "+subnodes);
|
IServer.getLogger().log ("rewiring: "+parent+" -> "+this+" -> "+subnodes);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue