web/views/workflow.py
changeset 10006 8391bf718485
parent 9440 6880674c1a26
child 10666 7f6b5f023884
equal deleted inserted replaced
10005:7769d0f61810 10006:8391bf718485
     1 # copyright 2003-2011 LOGILAB S.A. (Paris, FRANCE), all rights reserved.
     1 # copyright 2003-2014 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
   167     __select__ = component.EntityCtxComponent.__select__ & WFHistoryView.__select__
   167     __select__ = component.EntityCtxComponent.__select__ & WFHistoryView.__select__
   168     context = 'navcontentbottom'
   168     context = 'navcontentbottom'
   169     title = _('Workflow history')
   169     title = _('Workflow history')
   170 
   170 
   171     def render_body(self, w):
   171     def render_body(self, w):
   172         if hasattr(self, 'cell_call'):
   172         self.entity.view('wfhistory', w=w, title=None)
   173             warn('[3.10] %s should now implement render_body instead of cell_call'
       
   174                  % self.__class__, DeprecationWarning)
       
   175             self.w = w
       
   176             # pylint: disable=E1101
       
   177             self.cell_call(self.entity.cw_row, self.entity.cw_col)
       
   178         else:
       
   179             self.entity.view('wfhistory', w=w, title=None)
       
   180 
   173 
   181 
   174 
   182 class InContextWithStateView(EntityView):
   175 class InContextWithStateView(EntityView):
   183     """display incontext view for an entity as well as its current state"""
   176     """display incontext view for an entity as well as its current state"""
   184     __regid__ = 'incontext-state'
   177     __regid__ = 'incontext-state'