how to hide embedded list

chunn
Tera Expert

Hello, can you help me.

I want to hide embedded list on the form about 運用作業日付s embedded list, when run the type of change to monthly .  

I want to client script for implementation it ? 

 

songchunpu_0-1675129197581.png

 

1 ACCEPTED SOLUTION

@chunn ,

 

You can do similar script in UI policy:

 

Condition : Run = monthly

 

Execute if true script:

function onCondition(){
var list = $$('div[tab_caption="運用作業日付"]')[0];//embeded list name
        list.hide();
}

 

Execute if false script:

function onCondition(){
var list = $$('div[tab_caption="運用作業日付"]')[0];//embeded list name
        list.show();
}

 

Please mark the answer correct/helpful based on Impact.
Regards, Shekhar

View solution in original post

12 REPLIES 12

Gaurav Shirsat
Mega Sage

Hello @chunn 

Kindly refer this Thread from SN Guru.

Mark my Response as Correct or Helpful, if you find it Appropriate.
Gaurav Shirsat : ServiceNow Community MVP 2022
https://www.linkedin.com/in/gauravshirsat/

SoniaShridhar13
Giga Guru

@chunn  Hi ! 

Please let me know whether you are trying in Service Portal? Certain features are not supported in Service Portal.

What script are you using? this is the standard script for hiding this in Client script

 

g_form.setSectionDisplay("embedded_list_section",false);

 

Please mark it helpful if it helps...

Anurag Tripathi
Mega Patron
Mega Patron

Hi,

You cant hide the embedded list but if it is in a separate section you can just hide the entire section.

-Anurag