Issue with RegisterAccessControlRule()

Hi,

I have the following that filters if the user is not the owner.

if (!UserIsInRole("Owners"))
RegisterAccessControlRule("CreatorID", AccessPermission.Allow, UserId);

I'm adding a second filter to also show records that have been assigned to a user (users role) ====> this should be triggered where there is a "TicketID"

RegisterAccessControlRule(
"TicketID",
"select TicketID from Tickets where CreatorID = @UserId or AssignedTo = @UserId ",
// "select TicketID from Tickets where CreatorID = @UserId or AssignedTo = @UserId ",
AccessPermission.Allow,
new { UserId });

But the result is ====> the user does not see tickets that have been assigned to them.

Please help?
1 person has
this problem
+1
Reply