Hello,
I have a question regarding the ability to limit what records someone can see on a list page based on value(s) in a field. I have a users table that has a field named "view_multiple_items". This field contains anywhere from 1 to 30 numbers. If there is just one number there is nothing else in the field but that number, however if there is more than one value in the field, the values are separated by commas. This is set up by checking multiple check boxes on the users add/edit page and the data comes from another table containing the values that may be entered into "view_multiple_items"
The list pages contains a field called "wl". What I need to be able to do is allow someone to view a record on the list page if one of the values in the "view_multiple_items" is equal to "wl" from the list page.
An example would be User A has values 00, 71, 72, 73 in the "view_multiple_items" field. The list page contains 3 records; the values for "wl" on the list page are 00, 73, 25. When User A logs in, they should be able to 2 out of the three records.
I understand that I will need to set up session values on the After successful login page and something like this on the List Page: Before SQL Query. $strWhereClause = whereAdd($strWhereClause," wl = ??????????)");
My question is how do I set this up? Do I have to use the array function?
Much appreciated,
Brian