From 52f36f5c14ee3deb2d2d8175cda6202b2cf0169e Mon Sep 17 00:00:00 2001 From: Florian Damhaut Date: Wed, 13 Dec 2023 16:54:02 +0100 Subject: [PATCH] [FIX] portal: remove no document message Remove `No documents to display` as there will always be aa least the addresses and security/connection cards. closes odoo/odoo#146197 Task-id: 3629038 Signed-off-by: Arnaud Joset (arj) --- addons/portal/static/src/js/portal.js | 5 ----- addons/portal/views/portal_templates.xml | 1 - 2 files changed, 6 deletions(-) diff --git a/addons/portal/static/src/js/portal.js b/addons/portal/static/src/js/portal.js index e02e03a7b37..888903b0543 100644 --- a/addons/portal/static/src/js/portal.js +++ b/addons/portal/static/src/js/portal.js @@ -105,12 +105,7 @@ export const PortalHomeCounters = publicWidget.Widget.extend({ return documentsCountersData; }); return Promise.all(proms).then((results) => { - const counters = results.reduce((prev, current) => Object.assign({...prev, ...current}), {}); this.el.querySelector('.o_portal_doc_spinner').remove(); - // Display a message when there are no documents available if there are no counters > 0 and no counters always shown - if (!countersAlwaysDisplayed.length && !Object.values(counters).filter((val) => val > 0).length) { - this.el.querySelector('.o_portal_no_doc_message').classList.remove('d-none'); - } }); }, }); diff --git a/addons/portal/views/portal_templates.xml b/addons/portal/views/portal_templates.xml index 991a15af382..0056ceea760 100644 --- a/addons/portal/views/portal_templates.xml +++ b/addons/portal/views/portal_templates.xml @@ -222,7 +222,6 @@
-

No Documents to display