widget in simple list

Community Alums
Not applicable

Hello Team,

 

I want to create the simple list widget where we need to display the list of currently  logged in incident tickets and side we need one button named  "more details ". if click on more details button need to that particular ticket with all mandatory fields on incident form .

 

PLease Advise.

2 REPLIES 2

Sayali Gurav
Tera Guru
Tera Guru

Create a List Widget

- Navigate to Self-Service > Widgets.
- Click on "New".
Fill in the necessary details. For example:
- Name: Logged-in Incidents Widget
- Table: incident
- View: List
- Filter: active=true^assigned_to=javascript:gs.getUserID()

Add the necessary columns including the "More Details" button. In the "More Details" column, add a UI Action link.

Create a UI Action

- Navigate to System Definition > UI Actions.
- Click on "New".
Fill in the necessary details. For example:
- Name: Show Incident Details
- Table: incident
- Action name: show_details

In the "Script" field, you'll write a script to open the incident form with all mandatory fields.

Here's an example :

function showIncidentDetails() {
var currentIncident = new GlideRecord('incident');
if (currentIncident.get(g_request)) {
g_form.setActiveTab('details');
g_form.showRelatedList('activity_log');
}
}
showIncidentDetails();

Link UI Action to the "More Details" Button

- Go back to your List Widget configuration.
- Edit the "More Details" button.
- Set the "Link to Action" field to the UI Action you just created (show_details in this example).

 

Mark Correct or helpful if applicable.

Thanks & Regards,

Sayali Gurav

Community Alums
Not applicable

@Sayali Gurav  can you explain me step by step to create list widget and Add more details button on that ? we need to create simple list widget where we configure all those . I am not clear on this . please Advise.