<template>
  <el-tag class="ticket-status-tag" :class="{ 'float-left': floatLeft }" :type="TicketStatus[value]&&TicketStatus[value].type">
    {{ TicketStatus[value]&&TicketStatus[value].label || value }}
  </el-tag>
</template>

<script>
import { TicketStatus } from '@/assets/staticData'
export default {
  data () {
    return {
      TicketStatus
    }
  },
  props: {
    value: {
      type: String,
      default: ''
    },
     floatLeft: {  // 新增prop控制是否浮动
      type: Boolean,
      default: false
    }
  }
}
</script>

<style lang="scss" scoped>
.ticket-status-tag.float-left {
  float: left !important;
}
</style>
