I'm working on a web aplication in which I have a supertype node which is 
subtyped by organization, person and thing. Nodes can have permission to 
create/update/delete addresses, events, articles, pages etc. which all have 
a foreignkey referencing node.

I'm struggling with the authentication and authorization. If I add a node 
to the user I could use UserPassesTestMixin like this:

def test_func(self):
    obj = self.get_object()
    return obj.node == self.request.node

However, the consequence is that every node is related to a user 
one-to-one, which in case of things is not ideal.

I hope someone could point me in the right direction to solve this problem.

Kind regards,

Anne

-- 
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to django-users+unsubscr...@googlegroups.com.
To view this discussion on the web visit 
https://groups.google.com/d/msgid/django-users/03685bda-5257-42e0-88ef-1973de3411dfn%40googlegroups.com.

Reply via email to