<template>
  <reportPage
    :columnList="columnDefs" 
    :searchConfig="searchConfig"
    :searchForm="searchForm"
    :BottomFixedItem="BottomFixedItem"
    :reportName="'缴库汇总差异报表'"
    :procName="'Proc_缴库汇总差异报表'"
  ></reportPage>
</template>
  
<script>
import reportPage from "@/components/reportPage/index"
import util from '@/utils/util'

export default {
  name: "depositSummaryReport",
  components: {
    reportPage
  },
  data () {
    return {
      columnDefs: [
        { field: '零件号',  cellClass:"centerAlign", filter: 'agTextColumnFilter', suppressMenu: true, floatingFilterComponentParams: { suppressFilterButton: true } },
        { field: '库位',  cellClass:"centerAlign", filter: 'agTextColumnFilter', suppressMenu: true, floatingFilterComponentParams: { suppressFilterButton: true } },
        { field: 'mes最后一条时间', filter: 'agTextColumnFilter', suppressMenu: true, floatingFilterComponentParams: { suppressFilterButton: true } },
        { field: 'wms最后一条时间', filter: 'agTextColumnFilter', suppressMenu: true, floatingFilterComponentParams: { suppressFilterButton: true } },
        { field: 'tyrp最后一条时间', filter: 'agTextColumnFilter', suppressMenu: true, floatingFilterComponentParams: { suppressFilterButton: true } },
        { field: 'mes数量', type:"kiloNumber", cellClass:"rightAlign", valueFormatter: ((data)=>{return util.numberFixedFormatter(data.value,true)}), filter: 'agTextColumnFilter', suppressMenu: true, floatingFilterComponentParams: { suppressFilterButton: true } },
        { field: 'wms数量', type:"kiloNumber", cellClass:"rightAlign", valueFormatter: ((data)=>{return util.numberFixedFormatter(data.value,true)}), filter: 'agTextColumnFilter', suppressMenu: true, floatingFilterComponentParams: { suppressFilterButton: true } },
        { field: 'tyrp数量', type:"kiloNumber", cellClass:"rightAlign", valueFormatter: ((data)=>{return util.numberFixedFormatter(data.value,true)}), filter: 'agTextColumnFilter', suppressMenu: true, floatingFilterComponentParams: { suppressFilterButton: true } },
        { field: 'mes和wms差', type:"kiloNumber", cellClass:"rightAlign", valueFormatter: ((data)=>{return util.numberFixedFormatter(data.value,true)}), filter: 'agTextColumnFilter', suppressMenu: true, floatingFilterComponentParams: { suppressFilterButton: true } },
        { field: 'wms和tyrp差', filter: 'agTextColumnFilter', suppressMenu: true, floatingFilterComponentParams: { suppressFilterButton: true } },
        { field: 'mes和tyrp差', filter: 'agTextColumnFilter', suppressMenu: true, floatingFilterComponentParams: { suppressFilterButton: true } },
      ],
      searchConfig:[
        {type:'date',prop:'beginDate',label:'起始'},
        {type:'date',prop:'endDate',label:'截止'},
      ],
      searchForm:{
        beginDate:"",
        endDate:'',
      },
      BottomFixedItem:['mes数量','mes和wms差','tyrp数量','wms数量'],
    };
  }
};
</script>