equal
deleted
inserted
replaced
1 # copyright 2003-2010 LOGILAB S.A. (Paris, FRANCE), all rights reserved. |
1 # copyright 2003-2012 LOGILAB S.A. (Paris, FRANCE), all rights reserved. |
2 # contact http://www.logilab.fr/ -- mailto:contact@logilab.fr |
2 # contact http://www.logilab.fr/ -- mailto:contact@logilab.fr |
3 # |
3 # |
4 # This file is part of CubicWeb. |
4 # This file is part of CubicWeb. |
5 # |
5 # |
6 # CubicWeb is free software: you can redistribute it and/or modify it under the |
6 # CubicWeb is free software: you can redistribute it and/or modify it under the |
259 else: |
259 else: |
260 return html |
260 return html |
261 return wrapped |
261 return wrapped |
262 |
262 |
263 def _compiled_template(self, instance): |
263 def _compiled_template(self, instance): |
264 for fileordirectory in instance.config.vregistry_path(): |
264 for fileordirectory in instance.config.appobjects_path(): |
265 filepath = join(fileordirectory, self.filename) |
265 filepath = join(fileordirectory, self.filename) |
266 if isdir(fileordirectory) and exists(filepath): |
266 if isdir(fileordirectory) and exists(filepath): |
267 return compile_template_file(filepath) |
267 return compile_template_file(filepath) |
268 raise Exception('no such template %s' % self.filename) |
268 raise Exception('no such template %s' % self.filename) |
269 _compiled_template = cached(_compiled_template, 0) |
269 _compiled_template = cached(_compiled_template, 0) |