# HG changeset patch # User sylvain.thenault@logilab.fr # Date 1234906623 -3600 # Node ID 937dd226f72a7de22432829ecfb8edea31a1913d # Parent 0c2c8f0a6ded71f020ff20e18a3eaacc6fff9ba6 turn simpletal optional diff -r 0c2c8f0a6ded -r 937dd226f72a schema.py --- a/schema.py Tue Feb 17 22:34:18 2009 +0100 +++ b/schema.py Tue Feb 17 22:37:03 2009 +0100 @@ -954,9 +954,14 @@ # translation PERM_USE_TEMPLATE_FORMAT = _('use_template_format') +from cubicweb.mttransforms import HAS_TAL + class FormatConstraint(StaticVocabularyConstraint): - need_perm_formats = (_('text/cubicweb-page-template'), - ) + if HAS_TAL: + need_perm_formats = (_('text/cubicweb-page-template'),) + else: + need_perm_formats = () + regular_formats = (_('text/rest'), _('text/html'), _('text/plain'),