0.0.178
This commit is contained in:
@@ -484,6 +484,18 @@
|
||||
padding-top: 9%;
|
||||
}
|
||||
|
||||
.icon_unread_messages{
|
||||
display: none;
|
||||
}
|
||||
|
||||
.icon_unread_messages.showed{
|
||||
width: 12%;
|
||||
height: 100%;
|
||||
float: right;
|
||||
padding-top: 9%;
|
||||
display: block;
|
||||
}
|
||||
|
||||
|
||||
.cost-messages-in-user-tab-messenger{
|
||||
width: 25px;
|
||||
|
||||
@@ -1,8 +1,12 @@
|
||||
|
||||
function update_count_unread_messages (data) {
|
||||
let list_unrd = document.querySelectorAll(".qs")
|
||||
let list_unrd = document.querySelectorAll(".unredmessages_value_text")
|
||||
let list_unrd_parent = document.querySelectorAll(".icon_unread_messages")
|
||||
let i = 0
|
||||
for (i;i < list_unrd.length;i++){
|
||||
if (!list_unrd_parent[i].classList.contains("showed")){
|
||||
list_unrd_parent[i].classList.toggle("showed")
|
||||
}
|
||||
list_unrd[i].innerHTML = data.unread_msgs_count.toString()
|
||||
}
|
||||
}
|
||||
|
||||
@@ -62,27 +62,27 @@ function wsReceiveData (e) {
|
||||
// не найден user id
|
||||
}
|
||||
} else {
|
||||
let error_ticket_manager = "ticket_manager is not defined"
|
||||
let error_ticket_manager = "Error ticket_manager is not defined"
|
||||
console.log(error_ticket_manager)
|
||||
}
|
||||
|
||||
|
||||
} else {
|
||||
if (data.chat_html){
|
||||
if (msg_cont){
|
||||
if (msg_cont.dataset['curReceiver'] === data['sender'].toString() || msg_cont.dataset['curReceiver'] === data['receiver'].toString()) {
|
||||
msg_cont.innerHTML = data.chat_html
|
||||
}
|
||||
} else {
|
||||
let error_msg_cont = "msg_cont is not defined"
|
||||
console.log(error_msg_cont)
|
||||
}
|
||||
} else if (data.support_chat_html){
|
||||
// if (data.chat_html){
|
||||
// if (msg_cont){
|
||||
// if (msg_cont.dataset['curReceiver'] === data['sender'].toString() || msg_cont.dataset['curReceiver'] === data['receiver'].toString()) {
|
||||
// msg_cont.innerHTML = data.chat_html
|
||||
// }
|
||||
// } else {
|
||||
// let error_msg_cont = "Error msg_cont is not defined"
|
||||
// console.log(error_msg_cont)
|
||||
// }
|
||||
if (data.support_chat_html){
|
||||
let cont_mes_ins = document.querySelector(".info_profile")
|
||||
if (cont_mes_ins){
|
||||
cont_mes_ins.innerHTML = data.support_chat_html
|
||||
} else {
|
||||
let error_cont_mes_ins = "cont_mes_ins is not defined"
|
||||
let error_cont_mes_ins = "Error cont_mes_ins is not defined"
|
||||
console.log(error_cont_mes_ins)
|
||||
// не найден info profile
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user