Locking Annotations In Change Workflows
You can have annotations associated to the change be locked and/or unlocked at various points in the workflow. This section how to add annotation locking and unlocking to Workflow Templates.
Prerequisite Knowledge
To achieve the intended result you need to have an understanding of the following:
Modifying and/or creating Workflow Templates.
Working with expressions in workflow nodes using the Java Language
Define a Workflow Robot to Lock Annotations
To lock annotations on a Change Notice after the Change Notice is resolved, insert a new robot in between the “Set Change Notice Resolution Date” node and the “Or” node:
1. Select the new Execute Expression robot from the toolbar.
2. Insert the expression in between the “Set Change Notice Resolution” and the “Or” as indicated below
3. Add a description and name.
4. Enter the following Java into the Expression tab to lock the annotations:
wt.fc.collections.WTSet changeObjects =
wt.fc.collections.CollectionsHelper.singletonWTSet(primaryBusinessObject);
wt.change2.ChangeLockHelper.service.
lockRelatedMaterials(revisedChangeObjects,
wt.change2.ChangeApplicationLock.
LOCK_SUPPORTINGMATERIAL);
Define a Workflow Robot to Lock Annotations
To lock annotations on a Change Notice after the Change Notice is resolved, insert a new robot in between the “Set Change Notice Resolution Date” node and the “Or” node:
1. Select the new Execute Expression robot from the toolbar.
2. Insert the expression in between the “Set Change Notice Resolution” and the “Or” as indicated below
3. Add a description and name.
4. Enter the following Java into the Expression tab to lock the annotations:
wt.fc.collections.WTSet changeObjects =
wt.fc.collections.CollectionsHelper.singletonWTSet(primaryBusinessObject);
wt.change2.ChangeLockHelper.service.
lockRelatedMaterials(revisedChangeObjects,
wt.change2.ChangeApplicationLock.
LOCK_SUPPORTINGMATERIAL);
도움이 되셨나요?