introduce render_entity_toolbox on default primary view to display components in the ctxtoolbar context, such as pdf icon, notification registration (nosylist)...
--- a/web/views/primary.py Fri Nov 13 14:22:09 2009 +0100
+++ b/web/views/primary.py Fri Nov 13 14:24:29 2009 +0100
@@ -45,6 +45,7 @@
def render_entity(self, entity):
self.render_entity_title(entity)
+ self.render_entity_toolbox(entity)
# entity's attributes and relations, excluding meta data
# if the entity isn't meta itself
boxes = self._prepare_side_boxes(entity)
@@ -87,6 +88,9 @@
if title:
self.w(u'<h1>%s</h1>' % title)
+ def render_entity_toolbox(self, entity):
+ self.content_navigation_components('ctxtoolbar')
+
def render_entity_metadata(self, entity):
# XXX deprecated
entity.view('metadata', w=self.w)
--- a/web/views/tabs.py Fri Nov 13 14:22:09 2009 +0100
+++ b/web/views/tabs.py Fri Nov 13 14:24:29 2009 +0100
@@ -188,6 +188,7 @@
def cell_call(self, row, col):
entity = self.complete_entity(row, col)
self.render_entity_title(entity)
+ self.render_entity_toolbox(entity)
self.render_tabs(self.tabs, self.default_tab, entity)
@@ -200,7 +201,5 @@
def render_entity_title(self, entity):
pass
-
- def render_entity_metadata(self, entity):
+ def render_entity_toolbox(self, entity):
pass
-