| | |
| | | :data="tableDataB" |
| | | style="width: 100%" |
| | | v-loading="detailLoading"> |
| | | <el-table-column prop="productName" label="产品名称" min-width="120" align="center"></el-table-column> |
| | | <el-table-column prop="quantity" label="数量" min-width="80" align="center"></el-table-column> |
| | | <el-table-column prop="price" label="单价" min-width="100" align="center" :formatter="formatCurrency"></el-table-column> |
| | | <el-table-column prop="totalPrice" label="金额" min-width="100" align="center" :formatter="formatCurrency"></el-table-column> |
| | | <el-table-column prop="matnr" label="规格" min-width="120" align="center"></el-table-column> |
| | | <el-table-column prop="batch" label="箱号" min-width="80" align="center"></el-table-column> |
| | | <el-table-column prop="model" label="卷号" min-width="100" align="center" ></el-table-column> |
| | | <!-- <el-table-column prop="totalPrice" label="金额" min-width="100" align="center" :formatter="formatCurrency"></el-table-column>--> |
| | | <el-table-column prop="origin" label="位置" min-width="100" align="center"></el-table-column> |
| | | <el-table-column prop="danger" label="待判" min-width="100" align="center"></el-table-column> |
| | | <el-table-column prop="memo" label="备注" min-width="100" align="center"></el-table-column> |
| | | <!-- 可根据实际需求添加更多子表列 --> |
| | | </el-table> |
| | | |
| | |
| | | }, |
| | | |
| | | // 获取子表B数据(根据实际业务调整) |
| | | getTableDataB(uuid) { |
| | | getTableDataB(orderNo) { |
| | | let that = this; |
| | | that.detailLoading = true; |
| | | |
| | | // 构建请求参数 |
| | | let params = { |
| | | order_no: orderNo, |
| | | curr: that.detailCurrentPage, |
| | | limit: that.detailPageSize |
| | | }; |
| | | |
| | | // 模拟API调用 - 根据实际业务调整API地址 |
| | | $.ajax({ |
| | | url: baseUrl + "/api/order/detail/list", |
| | | // url: baseUrl + "/order/pakout/orderDetl/cargo/grouping/auth", |
| | | url: baseUrl + "/orderDetl/list/auth", |
| | | headers: { |
| | | 'token': localStorage.getItem('token') |
| | | }, |
| | | data: { |
| | | uuid: uuid, |
| | | page: that.detailCurrentPage, |
| | | size: that.detailPageSize |
| | | }, |
| | | data: params, |
| | | dataType: 'json', |
| | | contentType: 'application/json;charset=UTF-8', |
| | | method: 'post', |
| | | method: 'get', |
| | | success: function (res) { |
| | | that.tableDataB = res.data || []; |
| | | that.detailTotal = res.total || 0; |
| | | if (res.code === 200 || res.success) { |
| | | that.tableDataB = res.data.records || []; |
| | | that.detailTotal = res.total || 0; |
| | | } else { |
| | | that.$message.error(res.message || '获取数据失败'); |
| | | that.tableDataB = []; |
| | | that.detailTotal = 0; |
| | | } |
| | | that.detailLoading = false; |
| | | }, |
| | | error: function() { |
| | |
| | | this.currentRow = row; |
| | | this.detailDialogVisible = true; |
| | | this.detailCurrentPage = 1; |
| | | this.getTableDataB(row.uuid); |
| | | this.getTableDataB(row.orderNo); |
| | | }, |
| | | |
| | | // 关闭详情弹窗 |
| | |
| | | this.detailPageSize = val; |
| | | this.detailCurrentPage = 1; |
| | | if (this.currentRow) { |
| | | this.getTableDataB(this.currentRow.uuid); |
| | | this.getTableDataB(this.currentRow.orderNo); |
| | | } |
| | | }, |
| | | |
| | |
| | | handleDetailCurrentChange(val) { |
| | | this.detailCurrentPage = val; |
| | | if (this.currentRow) { |
| | | this.getTableDataB(this.currentRow.uuid); |
| | | this.getTableDataB(this.currentRow.orderNo); |
| | | } |
| | | }, |
| | | |