web/views/ajaxedit.py
branchstable
changeset 7879 9aae456abab5
parent 6927 340aba0c8c9e
child 8190 2a3c1b787688
equal deleted inserted replaced
7874:be04706eacc9 7879:9aae456abab5
     1 # copyright 2003-2010 LOGILAB S.A. (Paris, FRANCE), all rights reserved.
     1 # copyright 2003-2011 LOGILAB S.A. (Paris, FRANCE), all rights reserved.
     2 # contact http://www.logilab.fr/ -- mailto:contact@logilab.fr
     2 # contact http://www.logilab.fr/ -- mailto:contact@logilab.fr
     3 #
     3 #
     4 # This file is part of CubicWeb.
     4 # This file is part of CubicWeb.
     5 #
     5 #
     6 # CubicWeb is free software: you can redistribute it and/or modify it under the
     6 # CubicWeb is free software: you can redistribute it and/or modify it under the
    68         """
    68         """
    69         # use entity.unrelated if we've been asked for a particular etype
    69         # use entity.unrelated if we've been asked for a particular etype
    70         if getattr(self, 'etype', None):
    70         if getattr(self, 'etype', None):
    71             rset = entity.unrelated(self.rtype, self.etype, role(self),
    71             rset = entity.unrelated(self.rtype, self.etype, role(self),
    72                                     ordermethod='fetch_order')
    72                                     ordermethod='fetch_order')
    73             self.pagination(self._cw, rset, w=self.w)
    73             self.paginate(self._cw, rset=rset, w=self.w)
    74             return rset.entities()
    74             return rset.entities()
    75         super(AddRelationView, self).unrelated_entities(self)
    75         super(AddRelationView, self).unrelated_entities(self)
    76 
    76 
    77 
    77 
    78 def ajax_composite_form(container, entity, rtype, okjs, canceljs,
    78 def ajax_composite_form(container, entity, rtype, okjs, canceljs,