<template>
  <div class="main-contain">
    <div class="position">
      <bread-crumb :crumbs="crumbs"></bread-crumb>
    </div>
    <div class="app-container">
        <el-tabs v-model="activeName" @tab-click="handleClick">
            <!-- <el-tab-pane label="耗材盘点(模式一)" name="first">
                <inventory></inventory>
            </el-tab-pane> -->
            <el-tab-pane label="耗材盘点(模式一)" name="first">
                <history-inventory ref="childFive"></history-inventory>
            </el-tab-pane>
            <el-tab-pane label="耗材盘点(模式二)" name="four">
                <new-inventory ref="childFour"></new-inventory>
            </el-tab-pane>
          
            <el-tab-pane label="盘点列表" name="second">
                <inventory-details ref="child"></inventory-details>
            </el-tab-pane>
            <el-tab-pane label="报损列表" name="three">
                <stockDamaged ref="childOne"></stockDamaged>
            </el-tab-pane>

            <!-- <el-tab-pane label="盘点日志表" name="seven">
                <inventory-record ref="childSeven"></inventory-record>
            </el-tab-pane> -->
        </el-tabs>
        
    </div>
    
  
  </div>
</template>

<script>
import BreadCrumb from "../components/bread-crumb";
import inventory from './inventory.vue'
import newInventory from './newInventory.vue'
import historyInventory from './historyInventory.vue'
import inventoryDetails from './inventoryDetails.vue'
import stockDamaged from "./stockDamaged.vue"
import inventoryRecord from "./inventoryRecord.vue"
export default {
    name: "stockModifyPrice",
    components:{
        BreadCrumb,
        inventory,
        inventoryDetails,
        stockDamaged,
        newInventory,
        historyInventory,
        inventoryRecord
    },
    data() {
        return{
            crumbs: [
                { path: false, name: "库存管理" },
                { path: false, name: "耗材管理" },
                { path: false, name: "耗材盘点" }
            ],
            activeName:'first'
        }
    },
    methods:{
      handleClick(){
      if(this.activeName == "first"){
        this.$refs.childFive.getGoodInventoryList()
      }
       if(this.activeName == "four"){
         this.$refs.childFour.open()
        }
        if(this.activeName == "second"){
         this.$refs.child.getlist()
        }
        if(this.activeName =="three"){
          this.$refs.childOne.getlist()
        }

        if(this.activeName == "seven"){
          this.$refs.childSeven.getlist()
        }

       
      }
    },
    created(){
    },
    mounted() {
    },
};
</script>

<style rel="stylesheet/scss" lang="scss">
.app-container {
  // margin: 20px;
  font-size: 15px;
}
.modifyDialog{
    display: flex;
    flex-wrap: wrap;
    margin-bottom: 10px;
    .el-form-item{
        width: 33%;
    }
}
.el-table td,
.el-table th.is-leaf,
.el-table--border,
.el-table--group {
  border-color: #d0d3da;
}
.el-table--border::after,
.el-table--group::after,
.el-table::before {
  background-color: #d0d3da;
}
::-webkit-scrollbar{
    height: 20px !important;
}
</style>
