🐛fix 控制台警告
This commit is contained in:
parent
563c757741
commit
09b6a8fb81
@ -1,14 +1,15 @@
|
|||||||
const state = {
|
const state = {
|
||||||
onlineNum: 0,
|
onlineNum: 0,
|
||||||
noticeList: []
|
noticeList: [],
|
||||||
}
|
}
|
||||||
const mutations = {
|
const mutations = {
|
||||||
SET_ONLINEUSER_NUM: (state, num) => {
|
SET_ONLINEUSER_NUM: (state, data) => {
|
||||||
|
const { onlineClients, num } = data
|
||||||
state.onlineNum = num
|
state.onlineNum = num
|
||||||
},
|
},
|
||||||
SET_NOTICE_list: (state, data) => {
|
SET_NOTICE_list: (state, data) => {
|
||||||
state.noticeList = data;
|
state.noticeList = data
|
||||||
}
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
const actions = {
|
const actions = {
|
||||||
@ -19,12 +20,12 @@ const actions = {
|
|||||||
// 更新系统通知
|
// 更新系统通知
|
||||||
getNoticeList({ commit }, data) {
|
getNoticeList({ commit }, data) {
|
||||||
commit('SET_NOTICE_list', data)
|
commit('SET_NOTICE_list', data)
|
||||||
}
|
},
|
||||||
}
|
}
|
||||||
|
|
||||||
export default {
|
export default {
|
||||||
namespaced: true,
|
namespaced: true,
|
||||||
state,
|
state,
|
||||||
mutations,
|
mutations,
|
||||||
actions
|
actions,
|
||||||
}
|
}
|
||||||
@ -82,5 +82,7 @@ export default {
|
|||||||
store.dispatch('socket/getNoticeList', data.data)
|
store.dispatch('socket/getNoticeList', data.data)
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
connection.on('onlineInfo', () => {})
|
||||||
|
connection.on('connId', () => {})
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user