feat: 添加钢卷ID字段并实现导出功能
- 在WmsActualWarehouseVo中添加coilId字段 - 在WmsActualWarehouseServiceImpl中设置coilId值 - 在WarehouseBird组件中添加导出库内钢卷信息功能 - 在CoilTable组件中添加总卷数和总净重统计显示
This commit is contained in:
@@ -3,14 +3,18 @@
|
||||
<!-- 统计信息卡片 -->
|
||||
<div class="statistics-card">
|
||||
<el-card shadow="hover">
|
||||
<div class="statistics-item">
|
||||
<span class="label">总库位数:</span>
|
||||
<span class="value">{{ statistics.total }}</span>
|
||||
</div>
|
||||
<div class="statistics-item">
|
||||
<span class="label">总列数:</span>
|
||||
<span class="value">{{ statistics.columnCount }}</span>
|
||||
<div style="display: flex; gap: 10px; align-items: center;">
|
||||
<div class="statistics-item">
|
||||
<span class="label">总库位数:</span>
|
||||
<span class="value">{{ statistics.total }}</span>
|
||||
</div>
|
||||
<div class="statistics-item">
|
||||
<span class="label">总列数:</span>
|
||||
<span class="value">{{ statistics.columnCount }}</span>
|
||||
</div>
|
||||
<el-button type="primary" @click="exportData">导出库内钢卷信息</el-button>
|
||||
</div>
|
||||
|
||||
<el-table :data="tableData" border size="medium" style="width: 100%; margin-bottom: 20px;">
|
||||
<!-- 表头配置:合并表头实现层级展示 -->
|
||||
<el-table-column label="列信息" align="center" width="80">
|
||||
@@ -83,6 +87,7 @@
|
||||
|
||||
<script>
|
||||
import WarehouseInterlaced from './WarehouseInterlaced.vue';
|
||||
// import { listCoilWithIds } from "@/api/wms/coil";
|
||||
|
||||
export default {
|
||||
name: "WarehouseBird",
|
||||
@@ -136,6 +141,13 @@ export default {
|
||||
this.$emit('split-warehouse', warehouse);
|
||||
},
|
||||
|
||||
exportData() {
|
||||
// 收集coilIds
|
||||
this.download('wms/materialCoil/export', {
|
||||
coilIds: this.warehouseList.map(item => item.coilId).join(',')
|
||||
}, `库内钢卷信息_${new Date().getTime()}.xlsx`)
|
||||
},
|
||||
|
||||
// 1. 转换layerDetail为表格所需的数组格式
|
||||
formatTableData() {
|
||||
const layerDetail = this.statistics.layerDetail;
|
||||
@@ -347,7 +359,6 @@ export default {
|
||||
margin-bottom: 16px;
|
||||
|
||||
.statistics-item {
|
||||
margin-bottom: 8px;
|
||||
|
||||
&:last-child {
|
||||
margin-bottom: 0;
|
||||
|
||||
Reference in New Issue
Block a user