Commit c646e1af authored by Aurel's avatar Aurel

allow to defined message translation like 'lang | catalog' to export

other catalog that ui


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@10809 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 8d8d3f68
......@@ -3458,10 +3458,12 @@ class MessageTranslationTemplateItem(BaseTemplateItem):
def build(self, context, **kw):
localizer = context.getPortalObject().Localizer
for lang in self._archive.keys():
# Export only erp5_ui at the moment.
# This is safer against information leak.
for catalog in ('erp5_ui', ):
for lang_key in self._archive.keys():
if '|' in lang_key:
lang, catalog = lang_key.split(' | ')
else: # XXX backward compatibilty
lang = lang_key
catalog = 'erp5_ui'
path = os.path.join(lang, catalog)
mc = localizer._getOb(catalog)
self._objects[path] = mc.manage_export(lang)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment