I wonder what is the easiest way to solve following use case:
Imagine a datastructure - parent with child entitity. Then a workflow that in
- first step loads the data for that structure from db
- modifies the data by a transformation - modify one ore more child entity rows.
- saves the modified data structure to db
I would like to trigger validation on any change of child structure (child added/modified/deleted) . This validation would validate all the data of childs rows and parent row. I would like the validation to be called only once even though there could be more child changes at once. (not to repeat the same validation)
I would like to solve it with state machines (not call validation explicitely as an extra step from wf),