what is GlideModal('show_list');

chanikya
Tera Guru

Hi,

can any one help me what is 

new GlideModal('show_list');

 

what is the use of it, i didn't find show_list in UI Pages any where . what is the purpose of this useing?

1 ACCEPTED SOLUTION

Swapnil Soni1
Giga Guru

Hi chanikya,

show_list is actually nothing. It's ignored because the real param that matters here is "table".

GlideModal uses the RenderInfo processor and that looks at the preference name "table" to decide what UI page to show. In this case table = incident_list

The platform then decides to use the list template because it's a table + list suffix. Don't worry if this is confusing because it's all hidden away in the inner workings of the platform.

The real thing to take away from this is:

  

var m = new GlideModal("some_ui_page");
m.render(); // Will render a ui page


var m = new GlideModal("some_ui_page");
m.setPreference('table', 'incident_list');
m.render(); // Will render the incident list

 

**Please mark correct or helpful. If this helps you**

Thanks

Swapnil Soni

View solution in original post

6 REPLIES 6

Ankur Bawiskar
Tera Patron
Tera Patron

Hi Chanikya,

basically it is used to show the table list layout as GlideDialogWindow such as incident_list; problem_list when it loads

that may be internal page to which we don't have access to; only ServiceNow might have access to it

Mark Correct if this solves your issue and also mark 👍 Helpful if you find my response worthy based on the impact.
Thanks
Ankur

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

can we use GlideDialogWindow ('show_list') ?

Hi,

Yes you can use it. Like I see an example which uses this GlideDialogWindow ('show_list') -

var gdw = new GlideDialogWindow('show_list'); 

gdw.setTitle('Test');

gdw.setSize(750,300);

gdw.adjustBodySize();

gdw.render();

 

**Please mark correct or helpful. If this helps you**

Thanks

Swapnil Soni

Swapnil Soni1
Giga Guru

Hi chanikya,

show_list is actually nothing. It's ignored because the real param that matters here is "table".

GlideModal uses the RenderInfo processor and that looks at the preference name "table" to decide what UI page to show. In this case table = incident_list

The platform then decides to use the list template because it's a table + list suffix. Don't worry if this is confusing because it's all hidden away in the inner workings of the platform.

The real thing to take away from this is:

  

var m = new GlideModal("some_ui_page");
m.render(); // Will render a ui page


var m = new GlideModal("some_ui_page");
m.setPreference('table', 'incident_list');
m.render(); // Will render the incident list

 

**Please mark correct or helpful. If this helps you**

Thanks

Swapnil Soni