From 0b3bf0ed85036eaa578fe5f1c18bbb5bb799a882 Mon Sep 17 00:00:00 2001 From: amazuecos Date: Sat, 26 Oct 2024 08:56:18 +0200 Subject: [PATCH] refactor : in message notification send client to presupuestocliente and admin or beta to presupuesto admin --- httpdocs/assets/js/safekat/components/chat.js | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/httpdocs/assets/js/safekat/components/chat.js b/httpdocs/assets/js/safekat/components/chat.js index c5f38afa..4499d628 100644 --- a/httpdocs/assets/js/safekat/components/chat.js +++ b/httpdocs/assets/js/safekat/components/chat.js @@ -482,6 +482,9 @@ export const showNotificationMessages = (dom) => { if(data.totalMessages > 0){ $("#chat-notification-number").removeClass("d-none") $("#chat-notification-number").text(data.totalMessages ?? 0) + }else{ + $("#chat-notification-number").addClass("d-none") + $("#chat-notification-number").text(0) } data?.internals?.map((e) => { let numberOfMessages = e.unreadMessages @@ -509,7 +512,7 @@ export const showNotificationMessages = (dom) => { dom.append( `
  • - +
    ${e.presupuestoId}
    @@ -529,7 +532,7 @@ export const showNotificationMessages = (dom) => { dom.append( `
  • - +
    ${e.facturaId}
    @@ -549,7 +552,7 @@ export const showNotificationMessages = (dom) => { dom.append( `
  • - +
    ${e.pedidoId}