Best practice to restrict the selectable users in a reference field on the sys_user table in a custom app.

jdnauman
Kilo Contributor

Hi,

I'm looking for some guidance on best practice to restrict the list of users that show up dynamically in the reference field.  I have some onchange client scripts that trigger sporadically.  HI support suggested it could be the references on the lookup field.  The list should be limited dynamically based on the if the user is the manager and can view their direct reports, or based on department to control who can view HR records.  We just went live and are getting reports that the client scripts do not trigger for some roles.  

Thanks in advance for any ideas.

Regards,

Jeff

 

 

 

1 ACCEPTED SOLUTION

Dominik Simunek
Tera Guru

Hi Jeff,

The first thing I would think about when restricting dynamically what is shown in a reference field is Reference Qualifier. You might need some onChange client scripts to clear out chosen value if it depends on other fields.

Then if you really need to make sure that anybody is not able to "hack" it, you need to write a before insert/update business rule and check it there as well.

Best regards,

Dominik

View solution in original post

2 REPLIES 2

Dominik Simunek
Tera Guru

Hi Jeff,

The first thing I would think about when restricting dynamically what is shown in a reference field is Reference Qualifier. You might need some onChange client scripts to clear out chosen value if it depends on other fields.

Then if you really need to make sure that anybody is not able to "hack" it, you need to write a before insert/update business rule and check it there as well.

Best regards,

Dominik

jdnauman
Kilo Contributor

Thanks Dominik!