diff --git a/src/views/firstOrder/components/outDialog.vue b/src/views/firstOrder/components/outDialog.vue index 924ccf1..60cf3ca 100644 --- a/src/views/firstOrder/components/outDialog.vue +++ b/src/views/firstOrder/components/outDialog.vue @@ -1,60 +1,32 @@ - + - + 基本信息 - + - + - + - + @@ -62,25 +34,17 @@ - - 批量选择 + + 批量选择 单项选择 - + 易耗品 耐用品 @@ -91,100 +55,62 @@ + + + 暂存 + 待二级库入库 + 已出库 + + {{ outDate }} 出库信息: - 新增 - + 新增 + - - + " value-key="id"> + {{ scope.row.materialName }} - + - + - - + + {{ scope.row.departmentName || "无" }} - + {{ scope.row.applicationQuantity || 0 }} - + {{ scope.row.num }} - + {{ scope.row.outboundQuantity || 0 }} @@ -192,18 +118,11 @@ - + "> {{ scope.row.theOutboundQuantity }} {{ scope.row.theOutboundQuantity }} @@ -215,23 +134,14 @@ scope.row.type === "NY" ? "耐用品" : scope.row.type === "YH" - ? "易耗品" - : "" + ? "易耗品" + : "" }} - + - + 删除 @@ -240,12 +150,7 @@ 出库账目表格: - + @@ -258,8 +163,8 @@ scope.row.type === "NY" ? "耐用品" : scope.row.type === "YH" - ? "易耗品" - : "" + ? "易耗品" + : "" }} @@ -269,8 +174,8 @@ scope.row.type === "NY" ? "出库单" : scope.row.type === "YH" - ? "发放单" - : "" + ? "发放单" + : "" }} @@ -288,8 +193,7 @@ - {{ scope.row.totalQuantity<0?0: scope.row.totalQuantity}} - + {{ scope.row.totalQuantity < 0 ? 0 : scope.row.totalQuantity }} @@ -311,55 +215,24 @@ - - 取 消 - 暂存 - 提交 + + 取 消 + 暂存 + 提交 - - + + - - + + @@ -367,29 +240,17 @@ - - + + - + 易耗品 耐用品 @@ -405,25 +266,13 @@ - + - + @@ -469,6 +318,10 @@ export default { type: Number, default: 0, }, + rowItem: { + type: Object, + default: () => { } + } }, data() { return { @@ -532,7 +385,7 @@ export default { } else { this.inInit(); } - + this.sizeForm.userInfoVO = this.userInfo; // this.getMaterialList() }, @@ -541,7 +394,7 @@ export default { if (this.sizeForm.options == 1 && this.inBatchForm.optionType == "NY") { if ( columnIndex === 0 || - columnIndex === 1 + columnIndex === 1 ) { const key = `${row.materialCode}-${row.materialName}`; const rows = this.sizeForm.inTableData.filter( @@ -571,7 +424,7 @@ export default { }, getStatistics() { let arr = JSON.parse(JSON.stringify(this.sizeForm.inTableData)); - + arr.forEach((row) => { row.id = row.oneFormId; }); @@ -592,13 +445,13 @@ export default { item.materialCode === stat.materialCode && item.materialName === stat.materialName ); - console.log(8989898989,detailList) + console.log(8989898989, detailList) detail.theOutboundQuantity = detailList.reduce( (acc, cur) => acc + cur.theOutboundQuantity, 0 ); } - + return { ...stat, theOutboundQuantity: detail.theOutboundQuantity, //本次出库数量 @@ -796,10 +649,10 @@ export default { const appQty = Number(item.applicationQuantity || 0); const outQty = Number(item.outboundQuantity || 0); const defaultQty = appQty - outQty; - if (this.inBatchForm.optionType === "YH"){ + if (this.inBatchForm.optionType === "YH") { item.department = selectedDept.departmentId item.departmentName = selectedDept.department - } + } return { ...item, IdDemandEndld: this.inBatchForm.batchType, @@ -840,8 +693,7 @@ export default { } } catch (error) { this.$message.error( - `获取${ - this.inBatchForm.optionType === "YH" ? "易耗品" : "耐用品" + `获取${this.inBatchForm.optionType === "YH" ? "易耗品" : "耐用品" }数据失败:${error.message}` ); } @@ -850,8 +702,11 @@ export default { async getDetailedItems() { this.loading = true; try { - const res = await getDetailedItems(); - this.list = res.data.result; + // const res = await ; + // this.list = res.data.result; + getDetailedItems().then(res=>{ + this.list = res.data.result; + }) } catch (error) { this.$message.error("获取数据来源失败,请重试"); } finally { @@ -1090,6 +945,7 @@ export default { overflow-y: auto; padding-right: 10px; } + ::v-deep.el-table th.el-table__cell { background: #f5f7fa; font-weight: 500; diff --git a/src/views/firstOrder/outbound.vue b/src/views/firstOrder/outbound.vue index 576b37b..285e85b 100644 --- a/src/views/firstOrder/outbound.vue +++ b/src/views/firstOrder/outbound.vue @@ -65,6 +65,7 @@ type="一级库" @submitSuccess="handleSubmitSuccess" :id="id" + :rowItem = "rowItem" > @@ -91,6 +92,7 @@ export default { }, data() { return { + rowItem:{}, form: { outDate: [] }, selectionList: [], query: {}, @@ -264,6 +266,7 @@ export default { // 详情 handleDetails(row) { console.log(row, "row详情"); + this.rowItem = row this.outDialogVisible = true; this.outDialogType = "details"; this.outDialogTiltle = "详情"; diff --git a/src/views/secondOrder/components/inDialog.vue b/src/views/secondOrder/components/inDialog.vue index 1826313..83740f6 100644 --- a/src/views/secondOrder/components/inDialog.vue +++ b/src/views/secondOrder/components/inDialog.vue @@ -80,7 +80,7 @@ 取 消 - 确 定 + 确 定 diff --git a/src/views/secondOrder/inbound.vue b/src/views/secondOrder/inbound.vue index 6f2e314..1dfd324 100644 --- a/src/views/secondOrder/inbound.vue +++ b/src/views/secondOrder/inbound.vue @@ -1,59 +1,28 @@ - + - 入库 + 详情 + 入库 - {{ scope.row.caigoudanmingcheng }} + {{ + scope.row.caigoudanmingcheng }} 无 - + - + @@ -160,7 +129,7 @@ export default { label: "部门", prop: "demandDepartmentName", search: true, - hide:true, + hide: true, headerAlign: "center", align: "center", }, @@ -206,6 +175,11 @@ export default { this.inDialogVisible = false; this.onLoad(this.page); }, + detailsFn(row){ + this.inDialogVisible = true; + this.inDialogTiltle = "详情"; + this.inDialogData = row; + }, // 入库 行点击事件 rowSelect(row) { this.inDialogVisible = true;