4 <menuitem id="im_livechat" name="Live Chat" parent="mail.mail_feeds_main" groups="group_im_livechat"/>
6 <record model="ir.actions.act_window" id="action_support_channels">
7 <field name="name">Live Chat Channels</field>
8 <field name="res_model">im_livechat.channel</field>
9 <field name="view_mode">kanban,form</field>
10 <field name="help" type="html">
11 <p class="oe_view_nocontent_create">
12 Click to define a new live chat channel.
14 You can create channels for each website on which you want
15 to integrate the live chat widget, allowing you website
16 visitors to talk in real time with your operators.
18 Each channel has it's own URL that you can send by email to
19 your customers in order to start chatting with you.
23 <menuitem name="Channels" parent="im_livechat" id="support_channels" action="action_support_channels" groups="group_im_livechat"/>
26 <record model="ir.ui.view" id="support_channel_kanban">
27 <field name="name">support_channel.kanban</field>
28 <field name="model">im_livechat.channel</field>
29 <field name="arch" type="xml">
32 <field name="web_page"/>
33 <field name="are_you_inside"/>
34 <field name="user_ids"/>
36 <t t-name="kanban-box">
37 <div class="oe_group_image">
38 <a type="open"><img t-att-src="kanban_image('im_livechat.channel', 'image_medium', record.id.value)" class="oe_group_photo"/></a>
40 <div class="oe_group_details">
41 <h4><a type="open"><field name="name"/></a></h4>
42 <div class="oe_kanban_footer_left">
44 <span class="oe_e">+</span> <t t-esc="(record.user_ids.raw_value || []).length"/>
47 <div class="oe_group_button">
48 <button t-if="record.are_you_inside.raw_value" name="quit" type="object" class="oe_group_join">Quit</button>
49 <button t-if="! record.are_you_inside.raw_value" name="join" type="object">Join</button>
59 <record id="support_channel_form" model="ir.ui.view">
60 <field name="name">support_channel.form</field>
61 <field name="model">im_livechat.channel</field>
62 <field name="arch" type="xml">
63 <form string="Support Channels" version="7.0">
65 <field name="image" widget='image' class="oe_avatar oe_left" options='{"preview_image": "image_medium"}'/>
66 <div class="oe_title">
67 <label for="name" class="oe_edit_only"/>
69 <field name="name" placeholder="e.g. YourWebsite.com"/>
72 <button type="object" name="join" class="oe_highlight" string="Join Channel" attrs='{"invisible": [["are_you_inside", "=", True]]}'/>
73 <button type="object" name="quit" string="Leave Channel" attrs='{"invisible": [["are_you_inside", "=", False]]}'/>
74 <button type="object" name="test_channel" string="Test" attrs='{"invisible": [["web_page", "=", False]]}'/>
75 <field name="are_you_inside" invisible="1"/>
80 <group string="Operators">
81 <field name="user_ids" widget="many2many_kanban" nolabel="1" colspan="2">
85 <t t-name="kanban-box">
87 <a t-if="! read_only_mode" type="delete" style="position: absolute; right: 0; padding: 4px; diplay: inline-block">X</a>
88 <div class="oe_group_details" style="min-height: 40px">
89 <img t-att-src="kanban_image('res.users', 'image', record.id.value)"
90 class="oe_avatar oe_kanban_avatar_smallbox" style="float:left; margin-right: 10px;"/>
91 <h4><field name="name"/></h4>
99 <group string="Options">
100 <field name="button_text"/>
101 <field name="input_placeholder"/>
102 <field name="default_message" placeholder="e.g. Hello, how may I help you?"/>
106 <div attrs='{"invisible": [["web_page", "=", False]]}'>
107 <separator string="How to use the Live Chat widget?"/>
109 Copy and paste this code into your website, within the &lt;head&gt; tag:
111 <field name="script" readonly="1" class="oe_tag"/>
113 or copy this url and send it by email to your customers or suppliers:
115 <field name="web_page" readonly="1" class="oe_tag"/>
123 <record model="ir.actions.act_window" id="action_history">
124 <field name="name">History</field>
125 <field name="res_model">im.message</field>
126 <field name="view_mode">list</field>
127 <field name="domain">["|", ('to_id.user', '=', None), ('from_id.user', '=', None)]</field>
129 <menuitem name="History" parent="im_livechat" id="history" action="action_history" groups="group_im_livechat_manager"/>
131 <record id="im_message_form" model="ir.ui.view">
132 <field name="name">im.message.tree</field>
133 <field name="model">im.message</field>
134 <field name="arch" type="xml">
135 <tree string="History">
137 <field name="support_member_id"/>
138 <field name="customer_id"/>
139 <field name="direction"/>
140 <field name="message"/>