Hi azielinsky
Nice question. I will like to share this a scenario as how you can go about on the same. But this is possible only after the office is added. Cuz that will give ability to assign the newly created office id. Of course this will require a certain tweeks but surely should work out.
Here is what i can suggest..
If you doing it all from read ... great - no need to deal a lot of this ..
THE READ WAY - Where you can add 2 column and have a callback_column on both
1 - add for a button
2 - add space / iframe.
Also you have to add up a script that will execute the function to call up the employee grid into the iframe with pre-passed office id ... that can go as hidden value with the employees being added out there.
IF you planning to do the same with Add form -
What you need to do is = follow up almost the same things as for the READ state - but an additional stuff would be - u need to add callback after insert (of each employee) and store the ID of each employee added for the new office into the session.
And you need to add one callback after insert (for the office) and there you have to assign the generated office id to all the employees in the session.
I know looks a little complex but a doable solution for sure ....
Happy GCing 