summaryrefslogtreecommitdiff
path: root/addons/website_livechat/views
diff options
context:
space:
mode:
authorDavid Beguin <dbe@odoo.com>2019-09-19 14:28:12 +0000
committerDavid Beguin <dbe@odoo.com>2019-09-20 09:40:26 +0000
commit7f485c8d10637e7525ef21b9ecd058b4f14a6372 (patch)
tree0128a86fe74144bbb1fb9546d65eaebea0c15eb1 /addons/website_livechat/views
parent368c4be99b65f8e48c30f6534da816fd6fe5fe53 (diff)
[IMP] website, website_* : improve visitor kanban view
This commit review the design of the visitor kanban view. There is now two style for kanban card. Ungrouped : the card takes all the width of the screen. It's simulate a nice tree view. Grouped : Same design as before. ('normal' kanban card) Apply visitor kanban views redesign also in : - website_livechat - website_crm - website_sms Task ID: 2073714 PR #37081 Signed-off-by: Thibault Delavallee (tde) <tde@openerp.com>
Diffstat (limited to 'addons/website_livechat/views')
-rw-r--r--addons/website_livechat/views/website_visitor_views.xml30
1 files changed, 23 insertions, 7 deletions
diff --git a/addons/website_livechat/views/website_visitor_views.xml b/addons/website_livechat/views/website_visitor_views.xml
index 96386ac5d5e..2626b8f2c27 100644
--- a/addons/website_livechat/views/website_visitor_views.xml
+++ b/addons/website_livechat/views/website_visitor_views.xml
@@ -31,7 +31,7 @@
<field name="page_ids" position="after">
<field name="livechat_operator_id"/>
</field>
- <xpath expr="//div[@id='w_visitor_kanban_actions']" position="before">
+ <xpath expr="//div[hasclass('w_visitor_kanban_actions')]" position="before">
<div t-if="record.livechat_operator_id.raw_value">
<span class="fa fa-comments mr-2"/>Speaking With <span class="font-weight-bold"><field name="livechat_operator_name"/></span>
</div>
@@ -39,12 +39,28 @@
<br attrs="{'invisible': ['|', ('livechat_operator_id', '!=', False), ('is_connected', '=', False)]}"/>
</t>
</xpath>
- <xpath expr="//div[@id='w_visitor_kanban_actions']" position="inside">
- <button name="action_send_chat_request" type="object"
- class="btn btn-primary"
- attrs="{'invisible': ['|', ('livechat_operator_id', '!=', False), ('is_connected', '=', False)]}">
- <i class="fa fa-comments"/> Chat
- </button>
+ <xpath expr="//div[hasclass('w_visitor_kanban_actions_ungrouped')]" position="before">
+ <div class="col" >
+ <b>
+ <field name="livechat_operator_name" t-if="record.livechat_operator_id.raw_value"/>
+ <span t-else="">-</span>
+ </b>
+ <div>Speaking With</div>
+ </div>
+ </xpath>
+ <xpath expr="//div[hasclass('w_visitor_kanban_actions')]" position="inside">
+ <button name="action_send_chat_request" type="object"
+ class="btn btn-secondary"
+ attrs="{'invisible': ['|', ('livechat_operator_id', '!=', False), ('is_connected', '=', False)]}">
+ Chat
+ </button>
+ </xpath>
+ <xpath expr="//div[hasclass('w_visitor_kanban_actions_ungrouped')]" position="inside">
+ <button name="action_send_chat_request" type="object"
+ class="btn btn-secondary border"
+ attrs="{'invisible': ['|', ('livechat_operator_id', '!=', False), ('is_connected', '=', False)]}">
+ Chat
+ </button>
</xpath>
</field>
</record>