web/views/tableview.py
branch3.5
changeset 3228 7b05b2709439
parent 3129 fab471bee6c1
child 3230 1d25e928c299
child 3689 deb13e88e037
equal deleted inserted replaced
3227:f1695b2da6c3 3228:7b05b2709439
   142                                             displayactions)
   142                                             displayactions)
   143         elif displayfilter:
   143         elif displayfilter:
   144             actions += self.show_hide_actions(divid, True)
   144             actions += self.show_hide_actions(divid, True)
   145         self.w(u'<div id="%s"' % divid)
   145         self.w(u'<div id="%s"' % divid)
   146         if displayactions:
   146         if displayactions:
   147             for action in self.vreg['actions'].possible_actions(req, self.rset).get('mainactions', ()):
   147             actionsbycat = self.vreg['actions'].possible_actions(req, self.rset)
   148                 actions.append( (action.url(), req._(action.title), action.html_class(), None) )
   148             for action in actionsbycat.get('mainactions', ()):
       
   149                 for action in action.actual_actions():
       
   150                     actions.append( (action.url(), req._(action.title),
       
   151                                      action.html_class(), None) )
   149             self.w(u' cubicweb:displayactions="1">') # close <div tag
   152             self.w(u' cubicweb:displayactions="1">') # close <div tag
   150         else:
   153         else:
   151             self.w(u'>') # close <div tag
   154             self.w(u'>') # close <div tag
   152         # render actions menu
   155         # render actions menu
   153         if actions:
   156         if actions: