--- a/web/views/editforms.py Fri Nov 27 22:04:54 2009 +0100
+++ b/web/views/editforms.py Fri Nov 27 22:05:10 2009 +0100
@@ -512,7 +512,7 @@
"""fetch and render the form"""
entity = self._entity()
divid = '%s-%s-%s' % (self.peid, self.rtype, entity.eid)
- title = self.req.pgettext(i18nctx, 'This %s' % entity.e_schema)
+ title = self.form_title(entity, i18nctx=i18nctx, **kwargs)
removejs = self.removejs % (self.peid, self.rtype, entity.eid)
countkey = '%s_count' % self.rtype
try:
@@ -523,6 +523,9 @@
divid=divid, title=title, removejs=removejs, i18nctx=i18nctx,
counter=self.req.data[countkey], **kwargs))
+ def form_title(self, entity, i18nctx, **kwargs):
+ return self.req.pgettext(i18nctx, 'This %s' % entity.e_schema)
+
def add_hiddens(self, form, entity):
"""to ease overriding (see cubes.vcsfile.views.forms for instance)"""
iid = 'rel-%s-%s-%s' % (self.peid, self.rtype, entity.eid)