How to hide a user record from ALL Requests

GB14
Kilo Patron

We have a TEST account in the sys_user table, and we would like to hide it to be used for requests. 

 

We do not want to disable the account for some specific reasons. 

 

Any suggestions will be appreciated. 

 

Thanks,
G

1 ACCEPTED SOLUTION

Robbie
Kilo Patron
Kilo Patron

Hi @GB14,

 

We can hide certain records by leveraging a before Query business rule at the table level.

See the below screen shots to help you implement on the sys_user table and adjust accordingly.

 

To help others (or for me to help you more directly), please mark this response correct by clicking on Accept as Solution and/or Kudos.


Thanks, Robbie

 

Screenshot 2024-06-27 at 16.45.52.pngScreenshot 2024-06-27 at 16.45.43.png

 

 

(function executeRule(current, previous /*null when async*/) {

	current.addQuery("user_name", "!=", "abel.tuter"); //Change the 3rd parameter abel.tuter with the userID of the user you wish to hide

})(current, previous);

 

View solution in original post

8 REPLIES 8

Hello,

Thanks for the suggestions. 
It works great where we have used the OOB variable "requested for" but it doesn't work for the other variables. 

Is it possible to hide the user from the "Sys_user" table without disabling/deactivating the account? e.g. with Client script or something?

 

Thanks,
G

 

Hi @GB14,

 

No worries. We can lock this down by leveraging a before Query business rule.

See the below screen shots to help you implement on the sys_user table and adjust accordingly.

 

To help others (or for me to help you more directly), please mark this response correct by clicking on Accept as Solution and/or Kudos.


Thanks, Robbie

 

Screenshot 2024-06-27 at 16.45.52.pngScreenshot 2024-06-27 at 16.45.43.png

 

(function executeRule(current, previous /*null when async*/) {

	current.addQuery("user_name", "!=", "abel.tuter"); //Change the 3rd parameter abel.tuter with the userID of the user you wish to hide

})(current, previous);

Robbie
Kilo Patron
Kilo Patron

Hi @GB14,

 

We can hide certain records by leveraging a before Query business rule at the table level.

See the below screen shots to help you implement on the sys_user table and adjust accordingly.

 

To help others (or for me to help you more directly), please mark this response correct by clicking on Accept as Solution and/or Kudos.


Thanks, Robbie

 

Screenshot 2024-06-27 at 16.45.52.pngScreenshot 2024-06-27 at 16.45.43.png

 

 

(function executeRule(current, previous /*null when async*/) {

	current.addQuery("user_name", "!=", "abel.tuter"); //Change the 3rd parameter abel.tuter with the userID of the user you wish to hide

})(current, previous);

 

Thanks Robbie!