Script Condition for ACL If field contains current user grant read access

jaubert
Tera Guru

Not sure if this is possible but I'm trying to see the best way to check the value of a watch list.  The condition I'm trying to create is as follow:  If the logged in user/current user is on the watch list grant them read access to the RITM.  The below is the script that I tried in the script condition, I've even tried ".search" but it will only grab the first value/user access but if two users are on the watch list the other doesn't get access to see the record. 

 

 

answer=false;
if(current.watch_list.indexOf(gs.getUserID())>-1)
{
answer=true;
}
1 ACCEPTED SOLUTION

James Chun
Kilo Patron

Hi @jaubert,

 

Have you tried using the Data Condition instead of scripting?

JamesChun_0-1719949071659.png

 

Cheers

View solution in original post

2 REPLIES 2

James Chun
Kilo Patron

Hi @jaubert,

 

Have you tried using the Data Condition instead of scripting?

JamesChun_0-1719949071659.png

 

Cheers

OMG! It was right there in my face. 🙂  Thank you so much!