Saving associated objects

0
My model consists of an Employee entity with an 1-1 relation to a Picture entity. The picture is uploaded in a popup and has a default save button.   I change something in the employee field, but do not save it. I open the popup to change the picture and save it. The changes I made in the employee page are now also committed. I did not expect that, does saving an associated object also saves it's parent object?   And the other way around, does saving a object also commit the changes in his associated objects?
asked
2 answers
1

When you use the default save button the main object and all associated objects are saved. If you create a save microflow you will have to save all objects explicitly. But that is half the story.

In case of 1:1 assocations AND images (or filedocuments) the uploaded image is always created and stored immediately after upload, not just after pressing save. Because the image has a 1:1 with the main object this is also saved. In case you would press Cancel the main object is canceled but not the image.

answered
0

To the best of my knowledge, the default 'save' button will indeed save the referenced object(s) as well. 

If this is not the desired behavior, you can create your own 'save' button using a microflow that will commit only the main object and close the page.

 

answered