<template>
  <div class="details">
    <el-page-header content="详情页面" @back="goBack" />
    <el-tabs v-model="activeName" type="card" class="el-tabs-box" @tab-click="handleClick">
      <el-tab-pane label="商品信息" name="first">
        <el-table
          :data="detailsList"
          border
          style="width: 100%"
        >
          <el-table-column
            prop="date"
            label="规格名称"
            width="180"
          />
          <el-table-column
            prop="name"
            label="规格数量"
            width="180"
          />
          <el-table-column
            prop="address"
            label="单价"
          />
        </el-table>
      </el-tab-pane>
      <el-tab-pane label="价格库存" name="second">
        <el-table
          :data="detailsList"
          border
          style="width: 100%"
        >
          <el-table-column
            prop="date"
            label="规格名称"
            width="180"
          />
          <el-table-column
            prop="name"
            label="规格数量"
            width="180"
          />
          <el-table-column
            prop="address"
            label="单价"
          />
          <el-table-column
            prop="address"
            label="操作记录"
          />
        </el-table>

      </el-tab-pane>
    </el-tabs>
  </div>
</template>
<script>
import { mapGetters } from 'vuex'
export default {
  data() {
    return {
      activeName: 'first'
    }
  },
  computed: {
    ...mapGetters([
      'detailsList'
    ])
  },
  created() {
  },
  methods: {
    goBack() {
      this.$emit('goBack', true)
    },
    handleClick(tab, event) {
    }
  }
}
</script>
<style lang="scss" scoped>
.el-tabs-box{
  margin-top: 20px;
  .list{
    line-height: 50px;
  }
}

</style>
