Esempio n. 1
0
 def get_default_odm_query(self):
     user = self.get_user()
     query = Q('contributors', 'eq', user) & default_node_list_query()
     if user != self.request.user:
         query &= default_node_permission_query(self.request.user)
     return query
Esempio n. 2
0
 def get_default_queryset(self):
     user = self.get_user()
     query = MQ('contributors', 'eq', user) & default_node_list_query()
     if user != self.request.user:
         query &= default_node_permission_query(self.request.user)
     return Node.find(query)
Esempio n. 3
0
 def get_default_queryset(self):
     user = self.get_user()
     query = MQ('contributors', 'eq', user) & default_node_list_query()
     if user != self.request.user:
         query &= default_node_permission_query(self.request.user)
     return AbstractNode.find(query)