Browse Source

20250415

master
qiezi 9 months ago
parent
commit
e3ff980ba3
  1. 40
      src/views/modules/board/partInventory.vue

40
src/views/modules/board/partInventory.vue

@ -130,7 +130,7 @@ export default {
columnProp: "locationId",
headerAlign: "center",
align: "left",
columnLabel: "库",
columnLabel: "库",
columnHidden: false,
columnImage: false,
columnSortable: true,
@ -145,7 +145,7 @@ export default {
serialNumber: '153Table1',
tableId: "153Table1",
tableName: "物料库存信息表",
columnProp: "batch",
columnProp: "batchNo",
headerAlign: "center",
align: "left",
columnLabel: "批号",
@ -220,7 +220,7 @@ export default {
columnProp: "freezeFlag",
headerAlign: "center",
align: "left",
columnLabel: "入库日期",
columnLabel: "冻结",
columnHidden: false,
columnImage: false,
columnSortable: true,
@ -443,7 +443,7 @@ export default {
sortLv: 0,
status: true,
fixed: '',
columnWidth: 100
columnWidth: 140
},
{
userId: this.$store.state.user.name,
@ -461,7 +461,7 @@ export default {
sortLv: 0,
status: true,
fixed: '',
columnWidth: 100
columnWidth: 140
},
],
}
@ -494,11 +494,36 @@ export default {
},
fields(){
let json = "{"
this.columnList.forEach((item, index) => {
if (index === this.columnList.length - 1) {
json += "\"" + item.columnLabel + "\"" + ":" + "\"" + item.columnProp + "\""
} else {
json += "\"" + item.columnLabel + "\"" + ":" + "\"" + item.columnProp + "\"" + ","
}
})
json += "}"
let s = eval("(" + json + ")")
return s
},
},
created() {
},
computed:{
columnList(){
if (this.queryParams.summaryType === 2){
return this.columns.filter(item=> item.columnProp !== 'batchNo')
}
if (this.queryParams.summaryType === 1){
return this.columns.filter(item=> item.columnProp !== 'batchNo' && item.columnProp !== 'locationId');
}
if (this.queryParams.summaryType === 0){
return this.columns.filter(item=> item.columnProp !== 'batchNo' && item.columnProp !== 'locationId' && item.columnProp !== 'warehouseId');
}
return this.columns
}
},
watch:{
queryLoading(newVal,oldVal){
@ -507,7 +532,7 @@ export default {
this.queryLoading = false;
},30000)
}
}
},
}
}
</script>
@ -651,8 +676,7 @@ export default {
<div style="height: calc(100% - 130px)">
<el-table :data="dataList" v-loading="queryLoading" height="100%" border>
<el-table-column
v-for="(item,index) in columns" :key="index"
v-if="(item.columnProp !== 'warehouseId' && item.columnProp !== 'locationId' && item.columnProp !== 'batchNo')"
v-for="(item,index) in columnList" :key="index"
:header-align="item.headerAlign"
:align="item.align"
:min-width="item.columnWidth"

Loading…
Cancel
Save