Re: Django ACL Design Question

2009-04-20 Thread Mitch Guthrie
Tim, Thanks for the sample code. It was exactly what I was looking for. I'm still debating my route but it's nice to know what I want to do is possible. Thanks. On Mon, Apr 20, 2009 at 3:35 AM, Tim Chase wrote: > > >def MustHavePermission(*required_perms): > > def decorate(f): > >

Re: Django ACL Design Question

2009-04-20 Thread Tim Chase
>def MustHavePermission(*required_perms): > def decorate(f): >def new_f(request, *args, **kwargs): > perms = UserCompanies.objects.filter( >user=request.user, >company=determine_company(request), >) > for perm in required_perms

Re: Django ACL Design Question

2009-04-18 Thread Tim Chase
> Any ideas on how to best integrate this with what Django already has > or be able to extend it without having to rewrite an Auth/ACL system > completely from scratch? If I have to write my own ACL is there a way > to integrate it with what Django has? Well, Django makes it fairly easy to use y

Django ACL Design Question

2009-04-18 Thread mguthrie
I've spent quite a bit of time investigating several frameworks for a project I am starting. I initially wrote off Django due to it not being able to handle my ACL needs. After reviewing other frameworks I've determined that I will probably have to write something custom regardless of the framew