添加关闭客户端时通知服务端
This commit is contained in:
parent
828b5c6a6d
commit
f91d4b9de7
|
@ -54,7 +54,9 @@
|
||||||
computed: {
|
computed: {
|
||||||
},
|
},
|
||||||
destroyed: function () { // 离开页面生命周期函数
|
destroyed: function () { // 离开页面生命周期函数
|
||||||
this.websocketclose();
|
var userId = store.getters.userInfo.id;
|
||||||
|
this.websock.send("close_"+userId);
|
||||||
|
this.websocketclose();
|
||||||
},
|
},
|
||||||
created () {
|
created () {
|
||||||
|
|
||||||
|
|
|
@ -54,7 +54,9 @@
|
||||||
computed: {
|
computed: {
|
||||||
},
|
},
|
||||||
destroyed: function () { // 离开页面生命周期函数
|
destroyed: function () { // 离开页面生命周期函数
|
||||||
this.websocketclose();
|
var userId = store.getters.userInfo.id;
|
||||||
|
this.websock.send("close_"+userId);
|
||||||
|
this.websocketclose();
|
||||||
},
|
},
|
||||||
created () {
|
created () {
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user