wants to restrict to edit state field on list view
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-28-2019 07:50 AM
my concern here is ,
there are itil users they can edit the state field on list view.
now the requirement is the itil users should not change the state field when it is in closed state.
only admin should edit when the state is closed from list view.
how can i acheive this .
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-28-2019 07:55 AM
Hello,
You will want to create a list-edit ACL that only allows edit if the state does not equal Closed and be sure you set "itil" as the role and have the admin override checkbox marked true.
This should allow the itil users the ability to edit the state field on the List view only if the record is not already in a Closed state.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎08-28-2019 08:00 AM
Hello Lakng,
You should make an onLoad or onChange client script for that field.
Try something like this
function onLoad() {
if(g_form.getValue('your field') == 'Your value'){
if (!g_user.hasRole('Admin')) {
g_form.setReadOnly('your field',true);
}
}
}