ai*
This commit is contained in:
17
ai_website/views/res_config_settings_views.xml
Normal file
17
ai_website/views/res_config_settings_views.xml
Normal file
@@ -0,0 +1,17 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo>
|
||||
<record id="res_config_settings_view_form" model="ir.ui.view">
|
||||
<field name="name">res.config.settings.view.form.inherit.ai.website</field>
|
||||
<field name="model">res.config.settings</field>
|
||||
<field name="inherit_id" ref="website.res_config_settings_view_form"/>
|
||||
<field name="arch" type="xml">
|
||||
<block id="website_info_settings" position="inside">
|
||||
<setting id="ai_website_scripts"
|
||||
string="AI JavaScript"
|
||||
help="Always let the AI website builder add JavaScript to your pages. When off, it asks before adding any scripts.">
|
||||
<field name="ai_allow_scripts"/>
|
||||
</setting>
|
||||
</block>
|
||||
</field>
|
||||
</record>
|
||||
</odoo>
|
||||
13
ai_website/views/snippets/snippets.xml
Normal file
13
ai_website/views/snippets/snippets.xml
Normal file
@@ -0,0 +1,13 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo>
|
||||
|
||||
<template id="snippets" inherit_id="website.snippets">
|
||||
<!-- Use xpath to make the snippet appear before other snippets -->
|
||||
<xpath expr="//t[@t-snippet='website.s_title_form']" position="before">
|
||||
<t t-install="ai_website_livechat" string="AI Live Chat" group="contact_and_forms" label="AI"
|
||||
t-image-preview="/ai_website/static/src/img/snippet_previews/ai_livechat.webp"/>
|
||||
<t id='ai_livechat_hook'/>
|
||||
</xpath>
|
||||
</template>
|
||||
|
||||
</odoo>
|
||||
14
ai_website/views/website_templates.xml
Normal file
14
ai_website/views/website_templates.xml
Normal file
@@ -0,0 +1,14 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<odoo>
|
||||
<template id="layout" inherit_id="website.layout">
|
||||
<xpath expr="//head" position="inside">
|
||||
<!-- We need it to be ready before ai-gen scripts run. -->
|
||||
<t t-call-assets="ai_website.ai_assets" t-css="false"/>
|
||||
<!-- Recording what a script changes is only worth anything to
|
||||
someone who can open the builder and revert it, so visitors
|
||||
are not served it at all. -->
|
||||
<t groups="website.group_website_restricted_editor"
|
||||
t-call-assets="ai_website.ai_editor_assets" t-css="false"/>
|
||||
</xpath>
|
||||
</template>
|
||||
</odoo>
|
||||
Reference in New Issue
Block a user