I have a parent-child table/form.
On the parent form (A) I have a tabpanel that relates to the child form (B).
On Form B I have a button to add a new record. This is a local form method.
But when using a simple controller.newRecord() function it still uses the relationship that is used on Form A.
Is this normal behavior ?
In my case it’s a real pain because I use globals in some places as parent key and that gives even stranger results (like no or duplicate PK in the child record).
Servoy Developer
Version R2 2.2.1-build 333
Java version 1.4.2-54 (Mac OS X)
(yes I know 2.2.2 is out, but this is for a client that is still on 2.2.1)
I don’t think this was always the case.
Keep in mind I am creating a record locally in form B and suddenly it’s in the context of the relationship from form A.
As far as I know we always had to create records over relationships ourselves by using relationshipName.newRecord().
Also techniques like creating a record, putting the PK in a global and show that record via a relationship from that global is now impossible unless you use some other form?!
No, I am using this since the beginning of Servoy.
When you create a new record which is ‘viewed’ in a related tabpanel, it uses the relation!! (Not, if you go to that form itself)
Look at the CRM demo- there you will find this all over the place!