|
|
|
@ -386,6 +386,7 @@ const alertNotification = (uniqueid, type = 'add') => {
|
|
|
|
|
$('#' + uniqueid.replace('.', `\\.`) + " .chat-right-bottom-right").empty() |
|
|
|
|
if(type != 'remove'){ |
|
|
|
|
listaMensagem(uniqueid).then(mensagens => { |
|
|
|
|
console.log(mensagens) |
|
|
|
|
const countMsg = mensagens.data.filter(e => { |
|
|
|
|
if(e.event.mensagem.status != 'read'){ |
|
|
|
|
return true |
|
|
|
@ -460,17 +461,6 @@ const notifications = (obj = {}) => {
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
notification.data.sort((a, b) => b.status - a.status) |
|
|
|
|
|
|
|
|
|
console.log({
|
|
|
|
|
uniqueid: e.uniqueid,
|
|
|
|
|
number: e.cliente_id,
|
|
|
|
|
media: e.media,
|
|
|
|
|
name: e.profile_name,
|
|
|
|
|
datetime: e.data_reg,
|
|
|
|
|
status: e.status, |
|
|
|
|
protocolo: e.protocolo
|
|
|
|
|
}) |
|
|
|
|
|
|
|
|
|
notification.data.forEach(e => { |
|
|
|
|
chatList += buildNotification({
|
|
|
|
|
uniqueid: e.uniqueid,
|
|
|
|
|