[midPoint] Swallow change to approval work item

Sylvaire kevin TIPA sylvaire-kevin.tipa at mythalesgroup.io
Sat Apr 17 17:34:02 CEST 2021


Hello all,

I need help for adding delta to approval process. I have an approval workflow than work correctly. But depend of some parameter, I need to swallow additional modification. I use a hook in primary state for doing that, it work great but it not swallow change to approbation. So, if the manager approve, all work (role assignment is apply, and role deletion is apply). But if it refuse, role deletion is apply anyway (and I don't want).

So, how in hook I can create delta and add it to current workitem ? in order to create dependency between this delta and workitem result ?

In this screen, I want to see the 2 modifications in "change waiting to be approved".

[cid:image001.png at 01D733AF.DACA8DC0]

Current code
...
newAssignmentDelta.addValuesToDelete(assignmentValueToRemove)
modelContext.getFocusContext().swallowToPrimaryDelta(newAssignmentDelta)
modelContext.rot()


Nota MP : 3.9

Thanks, br

This message contains confidential information and is intended only for the individual(s) addressed in the message. If you are not the named addressee, you should not disseminate, distribute, or copy this e-mail. If you are not the intended recipient, you are notified that disclosing, distributing, or copying this e-mail is strictly prohibited.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.evolveum.com/pipermail/midpoint/attachments/20210417/a19617c9/attachment-0001.htm>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: image001.png
Type: image/png
Size: 35038 bytes
Desc: image001.png
URL: <https://lists.evolveum.com/pipermail/midpoint/attachments/20210417/a19617c9/attachment-0001.png>


More information about the midPoint mailing list