boutiqueMixin.js 916 Bytes
/*
 * @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'
      })
    }
  }
}