<template>
  <el-tag type="success" v-if="value == 'Authorized'" size="mini">已授权</el-tag>
  <el-tag type="danger" v-else-if="value == 'Unauthorized'" size="mini">未授权</el-tag>
  <el-tag type="info" v-else-if="value == 'Expired'" size="mini">已过期</el-tag>
</template>

<script lang="ts">
import { Component, Prop, Vue, Watch } from "vue-property-decorator";
@Component
export default class ShopTag extends Vue {
  value:any=null;

  @Prop()
  propConfig: any

  @Prop()
  propValue?:any

  @Prop()
  parentValue:any

  @Watch('propValue')
  propValueChange(v:any){
    this.setValue(v);
  }

  mounted(){
    if(this.propValue){
      this.setValue(this.propValue)
    }
  }

  setValue(v:any){
    this.value = v;
  }
}
</script>

<style lang="scss" scoped>

</style>