功能变化:

修改系统配置后,进行WS通知
pull/93/head
猿小天 2023-04-08 22:24:01 +08:00
parent d13533a203
commit 0228a0b927
1 changed files with 6 additions and 1 deletions

View File

@ -29,10 +29,15 @@ function webSocketOnError (e) {
*/
function webSocketOnMessage (e) {
const data = JSON.parse(e.data)
const { refresh_unread } = data
const { refresh_unread, systemConfig } = data
if (refresh_unread) {
// 更新消息通知条数
store.dispatch('d2admin/messagecenter/setUnread')
}
if (systemConfig) {
// 更新系统配置
this.$store.dispatch('d2admin/settings/load')
}
if (data.contentType === 'SYSTEM') {
ElementUI.Notification({
title: '系统消息',