Re: [web2py] Record-level access authorization question

2012-04-21 Thread Michael Ellis
Thanks Khalil, but I'm not sure how that solves my problem. I want, if possible, to automate a filtering operation that will apply to every query and exclude records the user is not allowed to see based on where his email address appears in the organization --> site --> building hierarchy. Th

Re: [web2py] Record-level access authorization question

2012-04-21 Thread Khalil KHAMLICHI
Create a custom field called "site" in auth_user table and when registering a new user give him his affected site, for any page user will view make sure you check for this value in you queries.

[web2py] Record-level access authorization question

2012-04-21 Thread Michael Ellis
Given a set of tables in strict hierarchy, e.g. organization --> site --> building --> system --> circuit where --> denotes a one-to-many relationship and each of the first 3 tables contains an email address field, "f_contact_email", that corresponds to a registered user, what's the best way to