appy.shared: added support for country codes (iso-3166-1) - appy.gen: non-string variables are now allowed in i18n variable replacements; bugfix while browsing translation pages with the 'next' arrows in 'edit' mode.

This commit is contained in:
Gaetan Delannay 2011-04-26 20:49:33 +02:00
parent 4e848ce0a8
commit 9e7ddcc771
7 changed files with 298 additions and 14 deletions

View file

@ -1245,6 +1245,7 @@ class BaseMixin:
res = self.formatText(res, format)
# Perform variable replacements
for name, repl in mapping.iteritems():
if not isinstance(repl, basestring): repl = str(repl)
res = res.replace('${%s}' % name, repl)
return res