mirror of
https://github.com/PanJiaChen/vue-element-admin.git
synced 2025-08-13 23:20:12 +08:00
fix: Error with this.unsubscribe is not a function
(#499)
This commit is contained in:
parent
603532a09f
commit
d24666370f
@ -40,6 +40,7 @@ export default {
|
|||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
documents: [],
|
documents: [],
|
||||||
|
unsubscribe: () => {},
|
||||||
search: ''
|
search: ''
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@ -89,7 +90,7 @@ export default {
|
|||||||
})
|
})
|
||||||
},
|
},
|
||||||
subscribeChanges() {
|
subscribeChanges() {
|
||||||
this.$store.subscribe((mutation, state) => {
|
return this.$store.subscribe((mutation, state) => {
|
||||||
if (mutation.type === 'notifyDashboardRefresh') {
|
if (mutation.type === 'notifyDashboardRefresh') {
|
||||||
this.getPendingDocuments()
|
this.getPendingDocuments()
|
||||||
}
|
}
|
||||||
|
@ -49,6 +49,7 @@ export default {
|
|||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
recentItems: [],
|
recentItems: [],
|
||||||
|
unsubscribe: () => {},
|
||||||
isLoaded: true,
|
isLoaded: true,
|
||||||
search: '',
|
search: '',
|
||||||
accentRegexp: /[\u0300-\u036f]/g
|
accentRegexp: /[\u0300-\u036f]/g
|
||||||
@ -144,7 +145,7 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
subscribeChanges() {
|
subscribeChanges() {
|
||||||
this.$store.subscribe((mutation, state) => {
|
return this.$store.subscribe((mutation, state) => {
|
||||||
if (mutation.type === 'notifyDashboardRefresh') {
|
if (mutation.type === 'notifyDashboardRefresh') {
|
||||||
this.getRecentItems()
|
this.getRecentItems()
|
||||||
}
|
}
|
||||||
|
@ -54,6 +54,7 @@ export default {
|
|||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
favorites: [],
|
favorites: [],
|
||||||
|
unsubscribe: () => {},
|
||||||
isLoaded: true,
|
isLoaded: true,
|
||||||
search: '',
|
search: '',
|
||||||
accentRegexp: /[\u0300-\u036f]/g
|
accentRegexp: /[\u0300-\u036f]/g
|
||||||
@ -108,7 +109,7 @@ export default {
|
|||||||
})
|
})
|
||||||
},
|
},
|
||||||
subscribeChanges() {
|
subscribeChanges() {
|
||||||
this.$store.subscribe((mutation, state) => {
|
return this.$store.subscribe((mutation, state) => {
|
||||||
if (mutation.type === 'notifyDashboardRefresh') {
|
if (mutation.type === 'notifyDashboardRefresh') {
|
||||||
this.getFavoritesList()
|
this.getFavoritesList()
|
||||||
}
|
}
|
||||||
|
@ -37,7 +37,8 @@ export default {
|
|||||||
mixins: [formMixin],
|
mixins: [formMixin],
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
fieldsList
|
fieldsList,
|
||||||
|
unsubscribe: () => {}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
|
@ -96,7 +96,8 @@ export default {
|
|||||||
},
|
},
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
fieldsList
|
fieldsList,
|
||||||
|
unsubscribe: () => {}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user