mirror of
https://github.com/pierre42100/ComunicWeb
synced 2024-11-22 20:19:21 +00:00
Determine whether user is signed in or not on sidebar
This commit is contained in:
parent
18f7fbc304
commit
30743601a9
@ -226,8 +226,14 @@ ComunicWeb.components.sideBar.main = {
|
|||||||
onclick: (e) => e.stopImmediatePropagation()
|
onclick: (e) => e.stopImmediatePropagation()
|
||||||
});
|
});
|
||||||
|
|
||||||
if(friend.accepted == 1)
|
// Check if friendship request has been accepted or not
|
||||||
subInfoEl.innerHTML = timeDiffToStr(friend.time_last_activity);
|
if(friend.accepted == 1) {
|
||||||
|
if(ComunicWeb.common.date.time() - friend.time_last_activity < 30)
|
||||||
|
subInfoEl.innerHTML = "<span style='color: green;'>Online</span>";
|
||||||
|
else
|
||||||
|
subInfoEl.innerHTML = timeDiffToStr(friend.time_last_activity);
|
||||||
|
}
|
||||||
|
|
||||||
else {
|
else {
|
||||||
|
|
||||||
const respondRequest = function(accept) {
|
const respondRequest = function(accept) {
|
||||||
|
Loading…
Reference in New Issue
Block a user