From 7f3a8d99287c835ee3ec703627c8ef906732c897 Mon Sep 17 00:00:00 2001 From: Nisha patel Date: Thu, 9 Jul 2020 13:26:52 +0000 Subject: [PATCH] [FIX] hr: Hide employee chat button in modals Currently, the "Chat" button appears in the form view when it is displayed as a modal and on click sends to the app switcher because js_class is not loaded on the dialog when employee form view is opened through the one2many(dialog). For ex: in online appointment when on click on 'available emloyee' it will open the employee form view in dialog and there is a chat icon but it does not work. So in this commit, we fix this issue by hiding the "chat" button when the view is displayed as a modal. make a button visible based on action context and when form view is oped through the click of one2many then do not display the chat icon on modal dialog. closes odoo/odoo#55345 Taskid: 2291340 Closes: #54381 X-original-commit: e2bac64411f80a3fcf2c5d5d60ad3eccf6517e56 Signed-off-by: Yannick Tivisse (yti) --- addons/hr/views/hr_employee_public_views.xml | 2 +- addons/hr/views/hr_employee_views.xml | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/addons/hr/views/hr_employee_public_views.xml b/addons/hr/views/hr_employee_public_views.xml index 108ff2c685d..d2001a8fc17 100644 --- a/addons/hr/views/hr_employee_public_views.xml +++ b/addons/hr/views/hr_employee_public_views.xml @@ -45,7 +45,7 @@