|
@@ -160,7 +160,7 @@ export const useWebSocketStore = defineStore("webSocketStore", {
|
|
|
}
|
|
|
|
|
|
console.log("WebSocket 连接成功");
|
|
|
- showNotify({ type: 'success', message: '服务器连接成功' });
|
|
|
+ // showNotify({ type: 'success', message: '服务器连接成功' });
|
|
|
this.flushMessageQueue(); // 连接成功后立即发送队列中的消息
|
|
|
};
|
|
|
|
|
@@ -171,7 +171,7 @@ export const useWebSocketStore = defineStore("webSocketStore", {
|
|
|
|
|
|
this.socket.onclose = () => {
|
|
|
this.connectionState = "disconnected";
|
|
|
- showNotify({ type: 'warning', message: '服务器连接断开' });
|
|
|
+ // showNotify({ type: 'warning', message: '服务器连接断开' });
|
|
|
this.cleanupTimers();
|
|
|
|
|
|
if (
|
|
@@ -185,7 +185,7 @@ export const useWebSocketStore = defineStore("webSocketStore", {
|
|
|
this.socket.onerror = (error) => {
|
|
|
this.connectionState = "error";
|
|
|
console.error("WebSocket 错误并 重新连接:", error);
|
|
|
- showNotify({ type: 'warning', message: '服务器连接断开' });
|
|
|
+ // showNotify({ type: 'warning', message: '服务器连接断开' });
|
|
|
this.cleanupTimers();
|
|
|
this.scheduleReconnect();
|
|
|
};
|
|
@@ -827,7 +827,7 @@ export const useWebSocketStore = defineStore("webSocketStore", {
|
|
|
...this.toUserInfo,
|
|
|
// 群公告
|
|
|
notice: msg && msg.notice?msg.notice: this.toUserInfo.notice,
|
|
|
- nickname: msg && msg.name?msg.name:this.toUserInfo.nickname,
|
|
|
+ // nickname: msg && msg.name?msg.name:this.toUserInfo.nickname,
|
|
|
// 群名称
|
|
|
sessionName: msg && msg.name?msg.name:this.toUserInfo.sessionName,
|
|
|
}
|