Ejemplo n.º 1
0
 def __call__(self, *args, **kwargs):
     query = kwargs.get("query")
     if not args:
         args = [self._rfield]
     if query is not None:
         del kwargs["query"]
     else:
         return self.select(*args, **kwargs)
     return Set.__call__(self, query).select(*args, **kwargs)
 def __init__(self, db, query, rfield, model, rid, via, **kwargs):
     self._rfield = rfield
     self._model = model
     self._rid = rid
     self._via = via
     Set.__init__(self, db, query, **kwargs)
 def __init__(self, db, query, rfield, model, rid, via, **kwargs):
     self._rfield = rfield
     self._model = model
     self._rid = rid
     self._via = via
     Set.__init__(self, db, query, **kwargs)
Ejemplo n.º 4
0
 def __call__(self, query=None, **kwargs):
     if query is None:
         return self.select(self._rfield, **kwargs)
     return Set.__call__(self, query).select(**kwargs)
Ejemplo n.º 5
0
 def __call__(self, query=None, **kwargs):
     if query is None:
         return self.select(self._rfield, **kwargs)
     return Set.__call__(self, query).select(**kwargs)