making variables read only using ACL

pmelmoth
Kilo Contributor

Hi

I thought this should be a straight forward question but I haven't been able to find a decent answer.

We have variables inherited from the Catalog Item visible on the Request Item. Some of those are read-only others are not. This is controlled through Catalog UI Policies.

The thing is, they should be all set to Read Only when the RITM is set to active=false as a blanket rule.

I would expect to do this via ACL but the following rule does not work.

Operation: write

Name: sc_req_item.variables

Condition: active=true

Instead I tried this in an onLoad client script:

if (g_form.getValue('state') >= 3)

  g_form.setVariablesReadOnly(true);

That works fine but surely there is a better way.

Any advice?

Cheers

6 REPLIES 6

ghsrikanth
Tera Guru

In the worst case, you can always go with DOM element id and that will work fine. Good luck


Ashutosh Munot1
Kilo Patron
Kilo Patron

Hi,

 

g_form.setVariablesReadOnly(true);

 

This is always a good option.


Thanks,

Ashutosh Munot