UpdateHierarchyState Activity
You can use the UpdateHierarchyState activity to update state of a hierarchy by specifying appropriate value for the Status parameter. The activity works according to the actions being performed on hierarchy. If the associated hierarchy approval work item is accepted, this activity runs in UpdateHierarchyStateAsApproved mode. If the associated hierarchy approval work item is rejected, the activity runs in UpdateHierarchyStateAsRejected mode.
- When the hierarchy is saved without any node rejections (from hierarchy approval work item), the UpdateHierarchyState activity updates its state to CONFIRMED.
- When the hierarchy is modified and any of the node or nodes are rejected from work item, the
RejectedNodes parameter contains the details of rejections. In this case, the UpdateHierarchyState activity updates the hierarchy log details with rejections in the database.
However, if the hierarchy is sent back for correction (to RejectionParticipantID) from work item, the UpdateHierarchyState activity continues to lock the hierarchy and does not release the lock.
- When a hierarchy is deleted and the delete operation is rejected from an associated work item, the UpdateHierarchyState activity restores the deleted hierarchy and updates the deleted version as REJECTED.
However, if the delete operation is confirmed from an associated work item, the UpdateHierarchyState activity updates the deleted version as CONFIRMED.
- Finally, the UpdateHierarchyState activity unlocks or releases the lock acquired on the hierarchy by the current user or member and current event.