boutiqueMixin.js
916 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
/*
* @Description:
* @Author: huyue
* @Date: 2023-07-07 11:23:06
* @LastEditors: huyue
* @LastEditTime: 2023-07-31 10:09:08
*/
export default {
data() {
return {
isFlag: false
}
},
watch: {
watchBoutiqueYear: {
immediate: true,
handler(newval) {
this.isFlag = true
this && this.init && this.init(newval)
}
},
watchBoutiqueChannel: {
immediate: true,
handler(newval) {
if (!this.isFlag) return
this && this.init && this.init(newval)
}
}
},
computed: {
watchBoutiqueYear() {
return this.$store.state.app.boutique.year
},
watchBoutiqueChannel() {
return this.$store.state.app.boutique.channel.value
}
},
method: {
openMessage(msg) {
this.$message({
message: msg,
type: 'warning'
})
}
}
}