Hello,
still studying the Parent-Child bizobj structure, I have a small suggestion:
in dBizobj._setParentLinkField, wouldn't it be nice to insert a check if the named parent link field
is in Parent.NonUpdateFields?? -- And if is not, log a warning or something? As this is an one-time-operation,
it is not expensive.
Or otherwise, could dBizobj.setFieldVal be adapted to notify its children so they can "move" to the
right dataset? (BTW: currently, setFieldVal references an undefined variable ret if self._CurrentCursor is None.)
In my small example, I did on the parent
parent.setFieldVal("non_pk_key", "myvalue") # child.ParentLinkField? = "non_pk_key"
parent.requeryAllChildren()
which works nice (i.e. the child shows the right dataset). If I call parent.new() before that,
however, the child's dataset remains empty.
Below there is a testcase showing the problem.