lxw
2020-06-27 8aee9dfec05e1a9333abf03f1bd35dd7cfa9d352
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
//退出
function quitClick() {
    if (loginInfo.identifier) {
        //sdk登出
        webim.logout(
            function (resp) {
                loginInfo.identifier = null;
                loginInfo.userSig = null;
                document.getElementById("webim_demo").style.display = "none";
                var indexUrl = window.location.href;
                var pos = indexUrl.indexOf('?');
                if (pos >= 0) {
                    indexUrl = indexUrl.substring(0, pos);
                }
                window.location.href = indexUrl;
            }
        );
    } else {
        alert('未登录');
    }
}
 
//被新实例踢下线的回调处理
function onKickedEventCall(){
    webim.Log.error("其他地方登录,被T了");
    document.getElementById("webim_demo").style.display = "none";
}
 
 
 
//多终端登录被T
function onMultipleDeviceKickedOut() {
    webim.Log.error("多终端登录,被T了");
    document.getElementById("webim_demo").style.display = "none";
}