Re: [rt-users] Allow only a specific user to see a Callback

2009-03-24 Thread Potla, Ashish Bassaliel
I think you can also get the current user`s obj and get his name like : $session{'CurrentUser'}-UserObj-Name and put in a condition to see if its John or not. Based on this condition you should call the callback. But going into the future if you want to add more users this functionality, it

Re: [rt-users] Allow only a specific user to see a Callback

2009-03-24 Thread Potla, Ashish Bassaliel
Try this in your condition and let me know : if ($group-HasMemberRecursively($session{'CurrentUser'}-PrincipalObj)) { -Ashish From: holland holland [laholla...@gmail.com] Sent: Tuesday, March 24, 2009 3:55 PM To: Potla, Ashish Bassaliel Subject: Re:

[rt-users] Allow only a specific user to see a Callback

2009-03-23 Thread holland holland
Dear all, I would like only a specific user, e.g 'John' to see a callback. Currently I only see methods based on user rights, like: %INIT if ($session{'CurrentUser'}-UserObj-HasRight( Right = 'AdminUsers', Object = $RT::System, )) { $toptabs-{'My Callback'} = { title =loc(My

[rt-users] Allow only a specific user to see a Callback

2009-03-23 Thread holland holland
Dear all, I would like only a specific user, e.g 'John' to see a callback. Currently I only see methods based on user rights, like: %INIT if ($session{'CurrentUser'}-UserObj-HasRight( Right = 'AdminUsers', Object = $RT::System, )) { $toptabs-{'My Callback'} = { title =loc(My Callback),

Re: [rt-users] Allow only a specific user to see a Callback

2009-03-23 Thread Tom Lahti
I'm no RT API expert, but I think from a best practices standpoint you really ought to create a new group for the purpose, make 'John' a member of that group, and then have the scrip allow the callback based on membership in that group. holland holland wrote: Dear all, I would like only a