Re: add permission to new model instances

2010-04-23 Thread Adonis
FYI, I have been looking to django authority as well http://packages.python.org/django-authority/index.html Which apparently supports per-object-permissions (row-level). I just can't get it to work yet... Regards, On Apr 22, 6:04 pm, Shawn Milochik wrote: > What you're describing is more of a r

Re: add permission to new model instances

2010-04-22 Thread Shawn Milochik
What you're describing is more of a row-level permissions system. The permissions system that ships with contrib.auth is table-level, not row-level. There has been some talk on this list about ways to go about it, but I don't think there's an out-of-the-box solution for it yet. Off of the top

Re: add permission to new model instances

2010-04-22 Thread Adonis
Thank you for your answer Shawn. I have been reading through Signal documentation and related examples...It is quite useful and it helps keep your code tidy. My problem continues because i cannot find a way to use a signal to add a permission to the meta class of the Layer model every time a user

Re: add permission to new model instances

2010-04-21 Thread Shawn Milochik
This can easily be done with signals. http://docs.djangoproject.com/en/1.1/topics/signals/ And, it (rightly) won't be done in the view, because that leaves open the very likely chance of a problem if someone writes a new view and forgets to call your extra code. The only sticky problem at the

add permission to new model instances

2010-04-21 Thread Adonis
hi, I think that what i am trying to do is NOT doable with django existing authentication or authority tools. Before developing my own code i thought of sharing it with the django community. I have a model called 'Layers'. I want a new permission to be created for each new entry in that table. Th