Jazz Forum Welcome to the Jazz Community Forum Connect and collaborate with IBM Engineering experts and users

How can we make all the attributes as read-only if the required tags are present

Hi Team,
In the Workitem ,As soon as the  sequential approval  tags are present in the tags attribute , I would like to have a read-only state for all attributes , except for the approval action and tags in order to avoid implementing a dedicated state and this needs to be done for Team Member and Stakeholder.Otherwise the sequential approval would not be able to modify.So tags and approval action should be editable, other attributes should be read only we would need this only for in progress  state.

Please Suggest
Thank you

0 votes



One answer

Permanent link

You have the following options to make attributes read-only with out of the box capabilities.

  1. The precondition/advisor read-only by type and state.
  2. The precondition/advisor read-only by condition, which works using a Javascript condition. See https://rsjazz.wordpress.com/2022/11/25/ewm-attribute-customization-introduction/ for an introduction .


Another option would be creating a custom work item save precondition/advisor that prevents saving the work item based on the rules it tests for. This is possible, but quite costly and can usually not be deployed in cloud hosted environments. 

'approval action should be editable' this makes no sense. Actions are not editable. Actions can be performed based on permissions and roles. The preconditions above can not control actions. A custom preconditions could prevent actions being performed based on some criteria.

1 vote

Comments
As Ralph says above, the only approach is number 2 where you would create a custom Javascript based Condition that fetches whatever information you need to check from the work item, and then returns true or false. 

Then you use the Condition script in the "Preconditions & Follow-up Actions" area with a "Read-Only Attributes For Condition" precondition to mark whatever fields you want as read-only if the code returns true.

1 vote

Your answer

Register or log in to post your answer.

Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.

Search context
Follow this question

By Email: 

Once you sign in you will be able to subscribe for any updates here.

By RSS:

Answers
Answers and Comments
Question details
× 12,120

Question asked: Feb 11 '25, 7:18 a.m.

Question was seen: 1,105 times

Last updated: Feb 13 '25, 5:20 p.m.

Confirmation Cancel Confirm