entity.py
changeset 3452 7c008d31ef1f
parent 3418 7b49fa7e942d
child 3459 e134d2dd9992
equal deleted inserted replaced
3451:6b46d73823f5 3452:7c008d31ef1f
   261     def has_perm(self, action):
   261     def has_perm(self, action):
   262         return self.e_schema.has_perm(self._cw, action, self.eid)
   262         return self.e_schema.has_perm(self._cw, action, self.eid)
   263 
   263 
   264     def view(self, vid, __registry='views', **kwargs):
   264     def view(self, vid, __registry='views', **kwargs):
   265         """shortcut to apply a view on this entity"""
   265         """shortcut to apply a view on this entity"""
   266         view = self._cw.vreg[__registry].select(vid, self._cw, rset=self.cw_rset)
   266         view = self._cw.vreg[__registry].select(vid, self._cw, rset=self.cw_rset, **kwargs)
   267         return view.render(row=self.cw_row, col=self.cw_col, **kwargs)
   267         return view.render(row=self.cw_row, col=self.cw_col, **kwargs)
   268 
   268 
   269     def absolute_url(self, *args, **kwargs):
   269     def absolute_url(self, *args, **kwargs):
   270         """return an absolute url to view this entity"""
   270         """return an absolute url to view this entity"""
   271         # use *args since we don't want first argument to be "anonymous" to
   271         # use *args since we don't want first argument to be "anonymous" to