1.1.28 upd msg counter and news
This commit is contained in:
@@ -3317,6 +3317,10 @@ details[open] summary ~ *{
|
||||
.self_news_text>ol>li{
|
||||
margin: 10px 0;
|
||||
}
|
||||
.self_news_text>ol>li>ul{
|
||||
list-style: disc;
|
||||
margin-left: 20px;
|
||||
}
|
||||
.advertisement_block_news {
|
||||
display: none;
|
||||
}
|
||||
|
||||
@@ -7,14 +7,16 @@ function update_count_unread_messages (data) {
|
||||
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()
|
||||
} else {
|
||||
let current_count = parseInt(list_unrd[i].innerHTML);
|
||||
list_unrd[i].innerHTML = (current_count + 1).toString();
|
||||
}
|
||||
|
||||
if(data.unread_msgs_count){
|
||||
list_unrd[i].innerHTML = (current_count + 1).toString();
|
||||
}
|
||||
|
||||
if(current_count === 0){
|
||||
list_unrd_parent[i].classList.toggle("showed")
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -579,6 +579,7 @@ function selectedUserMessenger (ticket_id=null,user_id=null,el){
|
||||
if (loader){
|
||||
loader.classList.toggle("show")
|
||||
}
|
||||
update_count_unread_messages()
|
||||
// let left_curtain = document.querySelector('.curtain.left')
|
||||
document.querySelector(".info_profile").innerHTML = data.html;
|
||||
document.querySelector(".enter-message-inp").focus()
|
||||
|
||||
Reference in New Issue
Block a user