<template>
  <div>
    <div class="normal-margin">
      <el-descriptions :column="3" :labelStyle="{width:'120px',flex:'1 0 auto',}" :contentStyle="{width:'250px',flex:'1 0 auto'}" border>
        <div slot="title" class="my-label__title">基本信息</div>
        <el-descriptions-item  label="商品编码">{{ basic.itemno}}</el-descriptions-item>
        <el-descriptions-item  label="商品名称">{{ basic.itemname}}</el-descriptions-item>
        <el-descriptions-item  label="状态"><span :style="basic.status == '审核' ? 'color:#52C41A' : 'color:#000000'">{{ basic.status}}</span></el-descriptions-item>
        <el-descriptions-item  label="品号">{{ basic.erpitemno}}</el-descriptions-item>
        <el-descriptions-item  label="品名">{{ basic.erpitemname}}</el-descriptions-item>
        <el-descriptions-item  label="外形尺寸">长:{{ basic.length}};宽:{{basic.width}};高:{{basic.height}}</el-descriptions-item>
        <el-descriptions-item  label="上/下架"><span :style="basic.isonsale ? 'color:#3874f6' : 'color:#333333'">{{ basic.isonsale ? '上架' : '下架'}}</span></el-descriptions-item>
        <el-descriptions-item  label="型号">{{ basic.model}}</el-descriptions-item>
        <el-descriptions-item  label="规格尺寸">{{ basic.spec}}</el-descriptions-item>
        <el-descriptions-item  label="计量单位组">{{ basic.unitname}}</el-descriptions-item>
        <el-descriptions-item  label="营销类别"><span v-for="item in basic.itemclass" :key="item.index">{{ item.itemclassname}},</span></el-descriptions-item>
        <el-descriptions-item  label="领域"><span v-for="item in basic.tradefield" :key="item.index">{{ item.tradefield}},</span></el-descriptions-item>
        <el-descriptions-item  label="品牌">{{ basic.brand && basic.brand[0]?basic.brand[0].brandname:''}}</el-descriptions-item>
        
        <el-descriptions-item  label="材质">{{ basic.material}}</el-descriptions-item>
        <el-descriptions-item  label="装置">{{ basic.device}}</el-descriptions-item>
        <el-descriptions-item  label="产线">{{ basic.prodline}}</el-descriptions-item>
        <el-descriptions-item  label="特殊说明">{{ basic.specalnote}}</el-descriptions-item>
        <el-descriptions-item  label="产品标准">{{ basic.standards}}</el-descriptions-item>
        <el-descriptions-item  label="重量">毛重:{{ basic.grossweight}};净重:{{basic.weight}}</el-descriptions-item>
        <el-descriptions-item  label="条形码">{{ basic.barcode}}</el-descriptions-item>
        <el-descriptions-item  label="序列号管理">{{ basic.isonsale + '11'}}</el-descriptions-item>
        <el-descriptions-item  label="是否批次管理">{{ basic.batchcontrol ? '是' : '否'}}</el-descriptions-item>
        <el-descriptions-item  label="建议零售价">{{ basic.price}}</el-descriptions-item>
        <el-descriptions-item  label="压力等级">{{ basic.pressure}}</el-descriptions-item>
        <el-descriptions-item  label="蝶板驱动">{{ basic.butterflyplatedrive}}</el-descriptions-item>
        <el-descriptions-item  label="连接形式">{{ basic.connection}}</el-descriptions-item>
        <el-descriptions-item  label="阀板材质">{{ basic.valveplatematerial}}</el-descriptions-item>
        <el-descriptions-item  label="阀体材质">{{ basic.bodymaterial}}</el-descriptions-item>
        <el-descriptions-item  label="执行器类型">{{ basic.actuatortype}}</el-descriptions-item>
        <el-descriptions-item  label="执行器品牌">{{ basic.actuatorbrand}}</el-descriptions-item>

        <el-descriptions-item  label="是否营销物料">{{ basic.iswuliao ? '是':'否'}}</el-descriptions-item>
        <el-descriptions-item  label="是否工具">{{ basic.istool ? '是':'否'}}</el-descriptions-item>
        <el-descriptions-item  label="是否服务物料">{{ basic.isservice ? '是':'否'}}</el-descriptions-item>
        <el-descriptions-item  label="是否中线蝶阀">{{ basic.isbutterfly ? '是':'否'}}</el-descriptions-item>

        
      </el-descriptions>
    </div>

    <div>
      <el-descriptions :column="2" labelClassName="my-label" contentClassName="my-content" border>
        <div slot="title" class="my-label__title">系统信息</div>
        <el-descriptions-item label="创建人">{{ basic.createby?basic.createby:"--" }}</el-descriptions-item>
        <el-descriptions-item label="创建时间">{{ basic.createdate?basic.createdate:"--" }}</el-descriptions-item>
        <el-descriptions-item label="最近编辑人">{{ basic.changeby?basic.changeby:"--" }}</el-descriptions-item>
        <el-descriptions-item label="最近编辑时间">{{ basic.changedate?basic.changedate:"--" }}</el-descriptions-item>
        <el-descriptions-item label="审核人">{{ basic.checkby?basic.checkby:"--" }}</el-descriptions-item>
        <el-descriptions-item label="审核时间">{{ basic.checkdate?basic.checkdate:"--" }}</el-descriptions-item>
      </el-descriptions>
    </div>
  </div>
</template>

<script>
export default {
  name: "detailedData",
  props:["basic"],
  data(){
    return {
    }
  },
  watch:{
    "basic"(newData,oldData){
      console.log(newData,'新的数据')
    }
  },
  mounted() {

  },
}
</script>

<style scoped>

</style>