[FIX] website{,_forum}: add summernote for non designer

In saas-6 the editor assets were always included.

In 9.0 it was only included depending on groups, but should be available
to be overwritten (for example by website_forum which needs to always
include the editor for message posting).

fixes #9402
This commit is contained in:
Nicolas Lempereur
2015-12-04 12:01:33 +01:00
parent 7f71611215
commit de5a00ac92
2 changed files with 9 additions and 10 deletions
+3 -10
View File
@@ -132,7 +132,10 @@
<t t-call-assets="web.assets_common" t-js="false"/>
<t t-call-assets="website.assets_frontend" t-js="false"/>
<t t-call-assets="web.assets_common" t-css="false"/>
<t groups="base.group_website_designer" t-call-assets="web_editor.summernote"/>
<t groups="base.group_website_designer" t-call-assets="web_editor.editor"/>
<t t-call-assets="website.assets_frontend" t-css="false"/>
<t groups="base.group_website_publisher" t-call-assets="website.assets_editor" async="True"/>
<script type="text/javascript">
odoo.define('web.csrf', function (require) {
var token = "<t t-esc="request.csrf_token(None)"/>";
@@ -200,16 +203,6 @@
</html>
</template>
<template id="layout_editor" inherit_id="website.layout" name="Editor" groups="base.group_website_publisher,base.group_website_designer">
<xpath expr='//t[@t-call-assets="website.assets_frontend"][@t-css="false"]' position="before">
<t groups="base.group_website_designer" t-call-assets="web_editor.summernote"/>
<t groups="base.group_website_designer" t-call-assets="web_editor.editor"/>
</xpath>
<xpath expr='//t[@t-call-assets="website.assets_frontend"][@t-css="false"]' position="after">
<t t-call-assets="website.assets_editor" async="True"/>
</xpath>
</template>
<template id="layout_footer_copyright" inherit_id="website.layout" name="Footer Copyright">
<xpath expr="//footer" position="inside">
<div class="container mt16 mb8">
@@ -10,6 +10,12 @@
</xpath>
</template>
<template id="summernote_assets" inherit_id="website.layout" name="Forum Summernote Assets">
<xpath expr='//t[@t-call-assets="web_editor.summernote"]' position="attributes">
<attribute name="groups"/>
</xpath>
</template>
<template id="assets_frontend" inherit_id="website.assets_frontend" name="Forum Assets">
<xpath expr="." position="inside">
<link rel='stylesheet' href="/web/static/lib/jquery.textext/jquery.textext.css"/>