Unable to hide the section on form

rameshrv999
Giga Contributor

Hi All,

I am trying to hide the Configuration section on cmdb_ci_solaris_server table through client script, the actual problem I am facing hear is two sections are there with Configuration name for two different views one is for Default view another is for Compliance.

When I ran that script Default view section is hidden but Compliance one is not hiding please I believe that names for sections are different but I am not find the names, please let me know how can we fix this issue.

8 REPLIES 8

False alert! Just realized that the 'state' field was not included in the view. Although the state flow banner is displayed on top and shows the correct state the actual field needs to be on the view.


That's correct. I've been caught by this once or twice. If an element isn't on the form, UI policies and client scripts cannot react to it.


Hi Sergio,



use g_form.setSectionDisplay('test', false); to hide the section //Replace test with the section name you want to hide



Also make sure that you have given correct name in the view and also if there are any fields mandatory in the section, you have to make it non mandatory before hiding sections.


Jaspal Singh
Mega Patron
Mega Patron

Hi Venkata,



Probably the client script that is written would have been for compliance view.


Open up the client script & check for the view. If it has compliance view change it to Default view & script would work as desired.