Calling Script Include function in Argument of module to filter list of records is not working
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-10-2024 03:40 AM
Hi Developers,
Need your help in calling Script Include function in Arguments of Link Type (URL from Arguments) in a module to filter list of records based on logged user groups.
Actually my other function in Argument is working fine but I have added new function & it is not working.
Arguments - /table_name_list.do?sysparm_fixed_query=u_payment_type=XYZ^u_status!=Deleted^u_user_countryINjavascript:new Terminationerhruser().getCountryRequests('single')^u_is_avanade_creatorINjavascript:new Terminationerhruser().getAvanadeRequests('single')^javascript:new Terminationerhruser().getHrPartner();
Highlighted part is newly added and that only not working properly. Others functions are working exactly fine.
Script Include code :-
Thanks in Advance,

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-10-2024 04:46 AM
@Krishnakant Arv Could you please try updating the code as follows and see if it works.
Arguments - /table_name_list.do?sysparm_fixed_query=u_payment_type=XYZ^u_status!=Deleted^u_user_countryINjavascript:new Terminationerhruser().getCountryRequests('single')^u_is_avanade_creatorINjavascript:new Terminationerhruser().getAvanadeRequests('single')^u_hr_partner_creator=javascript:new Terminationerhruser().getHrPartner();
Script Include:
getHrPartner: function() {
var query;
if (gs.getUser().isMemberOf('abc')) {
query = 'true';
} else {
query = 'false';
}
return query;
},
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-10-2024 10:33 PM
Hi @Sandeep Rajput ,
Thanks for you reply on my query.
I tried above changes but still it's not working. Filter condition I am getting -
Other Filter condition >HR Partner Creator = javascript
Please let me know what else I can do to make it correct.
Thank You So Much
Krishnakant.