mirror of
https://github.com/VueFileManager/vuefilemanager.git
synced 2026-04-18 08:12:15 +00:00
backend notifications implementation
This commit is contained in:
11
resources/js/store/modules/broadcasting.js
vendored
11
resources/js/store/modules/broadcasting.js
vendored
@@ -3,14 +3,15 @@ const defaultState = {
|
||||
}
|
||||
|
||||
const actions = {
|
||||
runConnection: ({ commit, getters }) => {
|
||||
runConnection: ({ commit, getters, dispatch }) => {
|
||||
|
||||
commit('SET_RUNNING_COMMUNICATION')
|
||||
|
||||
Echo.private(`test.${getters.user.data.id}`)
|
||||
.listen('.Domain\\Notifications\\Events\\TestUpdate', (e) => {
|
||||
console.log(e);
|
||||
});
|
||||
Echo.private(`App.Users.Models.User.${getters.user.data.id}`)
|
||||
.notification(() => {
|
||||
// TODO: call sound
|
||||
dispatch('getAppData')
|
||||
});
|
||||
},
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user