How to make a custom ticket field not editable for end users | Community
Skip to main content

How to make a custom ticket field not editable for end users

  • March 31, 2022
  • 5 replies
  • 0 views

Hello,

I would like to make a custom drop-down ticket field uneditable for end users. We want the users the select a value from the drop-down, the field must then lock or grey out, so the users won't have the option to edit or change the value.

Please can someone help?

 

5 replies

Dave12
  • April 1, 2022
Hi Johnny,
 
I don't know of a way to do that - perhaps it might be possible via Javascript. In any case, it might be a problem if a user accidentally selects the wrong value (something I know I do fairly often).

  • Author
  • April 1, 2022

Hi Dave,

Thank you, I am unable to find the exact script in the community posts:(

And, we also tried hiding the custom dropdown field from users, so they will not have the option to change the value. But the problem is when we apply conditions to that custom field, the other conditional fields don't appear. Is there a way we make the conditional fields visible?

Any help would be much appreciated.


Pulkit12
  • April 3, 2022

Hi Johnny J

Can you Please share the live URL of the help center and point me out there which field you want to make disabled.
It can be done with a few lines of Javascript 

Thank You 

Pulkit

Team Diziana


  • Author
  • April 3, 2022

Hi Pulkit, 

Thank you for helping, we are actually building up the forms in the UAT environment. Can I share the Sandbox URL? Will that help?


  • October 31, 2023

This is possible using the readOnly operator on the element:

document.querySelector("#request_custom_fields_yourFieldID").readOnly = true;