Hide Incident Variable Editor

ashok17
Tera Contributor

Hi All,

 

How to Hide Variable section( Incident Variable  Editor) on incident form.

 

Please suggest if any one have idea for this requirement. 

6 REPLIES 6

Maik Skoddow
Tera Patron
Tera Patron

Hi @ashok17 

 

open the form designer and search for the "Incident variable editor" formatter. Then remove it.

In the below screenshot it is not placed on the form but available to be dragged to the canvas.

MaikSkoddow_0-1704013862064.png

 

Maik

Hi Maik,

 

Thanks for response but I have configured variable section in incident form using form design incident variable editor but my question was how to hide the variable section in incident form if variable part is empty, Attached screenshot ,please suggest if you have idea.

 

 

 

Hi @ashok17 

in your screenshot you have marked the section (the tab) and not the variable editor which is inside the section. Therefore it's not clear what exactly you want to achieve, and I have to make assumptions.

In case you want to hide the complete section, you will need a client script of type "onLoad" which performs

g_form.setSectionDisplay('variables', false);

 Maik

Aniket Chavan
Tera Sage
Tera Sage

Hello @ashok17 ,

You can simply use either UI policy or onLoad Client script to achieve this and use below syntax to hide the form section.

g_form.setSectionDisplay('<section_name>', false); 

 

The section name is lower case with an underscore replacing the first space in the name, and with the remaining spaces being removed, for example "Section Four is Here" becomes "section_fourishere". Other non-alphanumeric characters, such as ampersand (&), are removed. Section names can be found by using the getSectionNames() method.

But before using UI policy or client script decide the trigger condition for that, like based on which field value or choice you are going to hide the section or in your scenario if variable part is empty then accordingly add/use those conditions in UI policy or client script.

Refer the below links as well for better understanding:

 

Let me know your views on this and Mark Correct if this solves your query and also mark 👍Helpful if you find my response worthy based on the impact.

 

Thanks,
Aniket