The Zurich release has arrived! Interested in new features and functionalities? Click here for more

I want to view "Watch List" tickets in the "My requests" page in employee center portal

Community Alums
Not applicable

Hello Everyone,

 

We have a have requirement to show "Watch List" tickets for the logged in user in "My Requests" page in Employee center portal.

OOTB widget(my request) we have open, closed filter configured so I have added one more filter "Watchlist requests".

 

Pandu6_1-1706775370447.png

 

So when I click on that, it should fetch the tickets for which the user is added in watch list.

If anyone has worked on it please help me with the changes that needs to be done.

 

Thank you!

 

15 REPLIES 15

Hi @Community Alums ,
Can you please share the solution what you found. We also have a similar requirement. 
Thank you

Community Alums
Not applicable

Hi @Gautam16 

 

You can find it in the below conversation.

Maruthi Ram
Tera Contributor

Hi @Community Alums 

 

Can you please drop the solution here.

Community Alums
Not applicable

Hi Ram,

 

Follow the below steps

 

1)Clone the widget "My Requests" Id:my-requests-v2 .

Add the below lines in the HTML template of the widget to add the option to the dropdown.

 <option value="watchlist">{{::data.messages.watchlist}}</option>

Refer the screenshot to know where to add the above line.

 

Pandu6_0-1711713857809.png

 

Now add the below code in the server script of the widget.

After Line 10;

msg.watchlist=gs.getMessage('WatchList Requests');

Refer the screenshot to know where to add the above line.

Pandu6_1-1711714092089.png

 

After Line 22;

else if (localInput && localInput.view === 'watchlist')
        data.filterMsg = gs.getMessage("Search WatchList requests");

Refer the screenshot to know where to add the above line.

Pandu6_2-1711714211696.png

 

Add below condition after line 113 and 127 in server script in my request widget.

else if (localInput && localInput.view === 'watchlist')
x.addQuery('watch_list', 'CONTAINS',gs.getUserID());

//x will be "task" and "ritmGR".

 

Now open My Request Filter(request_filter.LIST) table and create a new filter as per your requirement.

 

Refer the below screenshot for your understanding.

Pandu6_3-1711715110809.png

 

After creating the filter you are good to go. It will show up in the portal.

 

---------------------------------------------------

Please mark it helpful if this solves your query.

Thank You!

 

 

 

Thanks @Community Alums for the quick response.

 

I am not able to see the lines you mentioned in html and server side script. Below is the screenshot.

 

Please let me know if i am referring to wrong data.I have highlighted the widget name and the text that i am searching for.

MaruthiRam_1-1711768895497.png