<style>
  .app-attr .box {
    line-height: 64px;
    border-top: 1px solid #E8EAEE;
    border-left: 1px solid #E8EAEE;
    border-right: 1px solid #E8EAEE;
    padding: 0 16px;
  }

  .app-attr .box .batch {
    margin-left: -10px;
    margin-right: 20px;
  }

  .app-attr .el-select .el-input {
    width: 130px;
  }

  .app-attr .input-with-select .el-input-group__prepend {
    background-color: #fff;
  }

  .app-attr .header-require:before {
    content: '*';
    color: #F56C6C;
    margin-right: 2px;
  }

  .app-attr .priceComTable {
    width: 100%;
    border-collapse: collapse;
  }

  .app-attr .priceComTable tr th {
    height: 48px;
    font-size: 14px;
    color: #909399;
    border: 1px solid #EBEEF5;
    font-weight: bold;
  }

  .app-attr .priceComTable tr {
    background: #fff;
    text-align: center;
    height: 50px;
  }

  .app-attr .priceComTable tr td {
    font-size: 14px;
    border: 1px solid #EBEEF5;
  }

  .app-attr .fx_inner:hover td {
    background-color: #F5F7FA;
  }

  .app-attr .priceComTable td {
    transition: background-color .25s ease;
  }

</style>
<template>
  <div class="app-attr">
    <div class="box">
      <el-form label-width="180px">
        <el-checkbox v-model="attrBatch" @change="selectClick" :disabled="!cData || cData.length == 0"
          style="position:absolute">全选
        </el-checkbox>
        <el-form-item label="批量设置" size="small" style="margin-bottom:0;padding:18px 0;display:inline-block;">
          <el-input @keyup.enter.native="batchAttr(selectData)" size="small"
            :type="selectData == 'no' ? 'text' : 'number'" v-model="batch">
            <el-select v-model="selectData" slot="prepend">
              <el-option v-for="(item, index) in cList" :value="index" :key="item" v-if="index!='pic_url'"
                :label="item">
                {{item}}
              </el-option>
            </el-select>
            <template slot="append">
              <el-button @click="batchAttr(selectData)">
                确定
              </el-button>
            </template>
          </el-input>
        </el-form-item>
      </el-form>
    </div>

    <table class="priceComTable">
      <thead>
        <tr>
          <td style="width:55px;">
            <el-checkbox></el-checkbox>
          </td>
          <template v-for="headerItem in attrGroups">
            <td>{{headerItem.Name}}</td>
          </template>
          <td>
            <div class="header-require">拼团价</div>
          </td>
          <td>
            <div class="header-require">拼团库存</div>
          </td>
        </tr>
      </thead>
      <tbody>
        <tr v-for="item in pinTuanPriceList">
          <td>
            <el-checkbox></el-checkbox>
          </td>
       
          <template v-for="(attrItem, attrIndex) in attrGroups">
            <td v-if="attrIndex == index2" v-for="(item2, index2) in item.AttrList" :key="index2+'6'">
              {{ item.AttrList[index2].SVName }}
            </td>
          </template>
        <td>
           <el-input v-model="item.PintuanPrice" />
          </td>
          <td>
   <el-input v-model="item.PintuanStock" />
          </td>
        </tr>
      </tbody>
    </table>
  </div>
</template>
<script>
  export default {
    props: ["pinTuanPriceList", "attrGroups"],
    data() {
      return {

      };
    },
    created() {

    },
    watch: {

    },
    methods: {
      getItemName()
      {

      }
    },
    mounted() {

    },
    computed: {

    },
  };

</script>
