e830953570d5f28aee9bdcdf97af18d3e3246030
Major changes:
- Remove some of the recursively when compiling
- Compile attributes became a directive
- Compile options became a directive
- `t-field` compilation now uses the same logic as `t-out`
- Simplification of ``t-if`` directive compilation
- Improved handling of errors wrapped by QWebException
- Constants defined outside the class
Odoo
┗━► _render (returns MarkupSafe)
┗━► _compile (returns function) ◄━━━━━━━━━━┓
┗━► _compile_node (returns code string array) ◄━━━━━━━━┓ ┃
┃ (skip the current node if found t-qweb-skip) ┃ ┃
┃ (add technical directives: t-tag-open, t-tag-close, t-inner-content) ┃ ┃
┃ ┃ ┃
┣━► _directives_eval_order (defined directive order) ┃ ┃
┣━► _compile_directives (loop) Consume all remaining directives ◄━━━┓ ┃ ┃
┃ ┃ (e.g.: to change the indentation) ┃ ┃ ┃
┃ ┣━► _compile_directive ┃ ┃ ┃
┃ ┃ ┗━► t-if ━━► _compile_directive_if ━┫ ┃ ┃
┃ ┃ ┗━► t-foreach ━━► _compile_directive_foreach ━┛ ┃ ┃
┃ ┃ ┗━► t-inner-content ━━► _compile_directive_inner_content ◄━━━━━┓ ━┛ ┃
┃ ┃ ┗━► t-options ━━► _compile_directive_options ┃ ┃
┃ ┃ ┗━► t-call ━━► _compile_directive_call ━┫ ━━━┛
┃ ┃ ┗━► t-att ━━► _compile_directive_att ┃
┃ ┃ ┗━► t-tag-open ━━► _compile_directive_open ◄━━┓ ┃
┃ ┃ ┗━► t-tag-close ━━► _compile_directive_close ◄━━┫ ┃
┃ ┃ ┗━► t-out ━━► _compile_directive_out ━┛ ━┫ ◄━━┓
┃ ┃ ┗━► t-field ━━► _compile_directive_field ┃ ━┫
┃ ┃ ┗━► t-esc ━━► _compile_directive_esc ┃ ━┛
┃ ┃ ┗━► t-* ━━► ... ┃
┃ ┃ ┃
┗━━┻━► _compile_static_node ━┛
closes odoo/odoo#81024
Related: odoo/enterprise#22942
Signed-off-by: Christophe Monniez (moc) <moc@odoo.com>
…
…
Odoo
Odoo is a suite of web based open source business apps.
The main Odoo Apps include an Open Source CRM, Website Builder, eCommerce, Warehouse Management, Project Management, Billing & Accounting, Point of Sale, Human Resources, Marketing, Manufacturing, ...
Odoo Apps can be used as stand-alone applications, but they also integrate seamlessly so you get a full-featured Open Source ERP when you install several Apps.
Getting started with Odoo
For a standard installation please follow the Setup instructions from the documentation.
To learn the software, we recommend the Odoo eLearning, or Scale-up, the business game. Developers can start with the developer tutorials
Languages
Python
49.6%
JavaScript
47.8%
SCSS
2%
CSS
0.3%
HTML
0.2%