
import { mapGetters } from 'vuex'

export const roleMixin = {
  data() {
    return {
      isRoleDisabled: false
    }
  },
  computed: {
    ...mapGetters([
      'userInfo'
    ])
  },
  mounted() {
    console.log(this.userInfo)
    if (this.userInfo.roleId === 3) {
      this.searchForm.area = this.userInfo.roleId
      this.isRoleDisabled = true
    }
  }
}
