From 6000fb5c86ba2f17bc3f26087b51ff097668c700 Mon Sep 17 00:00:00 2001 From: bb_pan Date: Fri, 26 Sep 2025 17:09:22 +0800 Subject: [PATCH 1/2] =?UTF-8?q?=E7=9B=B4=E8=BD=AC=E5=B0=8F=E6=95=B0?= =?UTF-8?q?=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/business/businessHandling/directApply.vue | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/src/views/business/businessHandling/directApply.vue b/src/views/business/businessHandling/directApply.vue index f8262994..0ec32864 100644 --- a/src/views/business/businessHandling/directApply.vue +++ b/src/views/business/businessHandling/directApply.vue @@ -295,10 +295,10 @@ v-model="scope.row.directNum" :value="scope.row.directNum || ''" controls-position="right" - :precision="0" + :precision="scope.row.unitValue == 1 ? 3 : 0" style="width: 100%" :disabled="isDetail || !scope.row.isActive" - :min="1" + :min="scope.row.unitValue == 1 ? 0.001 : 1" @change="directNumChange(scope.row)" > @@ -915,6 +915,11 @@ export default { // 数量变更 directNumChange(row) { + if (row.unitValue == 1) { + row.directNum = Number(String(row.directNum).replace(/[^\d.]/g, '')) + } else { + row.directNum = Number(String(row.directNum).replace(/[^\d]/g, '')) + } if (row.directNum > row.useNum) { this.$message.error('直转数量不能大于领料数量') this.$nextTick(() => { From d2ac7b3511f476e681f79bd2f4d9413b8dcea22f Mon Sep 17 00:00:00 2001 From: hayu <1604366271@qq.com> Date: Fri, 26 Sep 2025 18:03:10 +0800 Subject: [PATCH 2/2] =?UTF-8?q?=E6=9D=90=E6=96=99=E7=AB=99=E9=A2=86?= =?UTF-8?q?=E6=96=99=E5=8D=95=E5=8F=B7=E4=B8=80=E9=94=AE=E5=87=BA=E5=BA=93?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/materialsStation/index.js | 9 + .../outBound/component/OutCodeDlg.vue | 15 +- .../outBound/component/addToolsApply.vue | 287 +++++++++++++----- 3 files changed, 235 insertions(+), 76 deletions(-) diff --git a/src/api/materialsStation/index.js b/src/api/materialsStation/index.js index 99f89698..ce77bef1 100644 --- a/src/api/materialsStation/index.js +++ b/src/api/materialsStation/index.js @@ -837,3 +837,12 @@ export function getSubUnitList(query) { }) } +// 获取领料单 +export function getLeaseDataByCode(data) { + return request({ + url: '/material/material_lease_apply_info/getLeaseDataByCode', + method: 'get', + params: data + }) +} + diff --git a/src/views/materialsStation/toolsLease/outBound/component/OutCodeDlg.vue b/src/views/materialsStation/toolsLease/outBound/component/OutCodeDlg.vue index b7aa1e31..e3163111 100644 --- a/src/views/materialsStation/toolsLease/outBound/component/OutCodeDlg.vue +++ b/src/views/materialsStation/toolsLease/outBound/component/OutCodeDlg.vue @@ -105,10 +105,19 @@ export default { } }) }, + // saveCodeOut() { + // console.log('Selected codes:', this.outCodeList) + // this.$emit('selectOutCode', this.selectedCodeList) + // this.openCode = false + // } saveCodeOut() { - console.log('Selected codes:', this.outCodeList) - this.$emit('selectOutCode', this.selectedCodeList) - this.openCode = false + // 直接从 el-table 的引用中获取当前选中的行 + const selectedRows = this.$refs.multipleTable.selection; + console.log('Selected codes:', selectedRows); + + // 发送选中的行列表 + this.$emit('selectOutCode', selectedRows); + this.openCode = false; } } } diff --git a/src/views/materialsStation/toolsLease/outBound/component/addToolsApply.vue b/src/views/materialsStation/toolsLease/outBound/component/addToolsApply.vue index a222311a..335f3ab5 100644 --- a/src/views/materialsStation/toolsLease/outBound/component/addToolsApply.vue +++ b/src/views/materialsStation/toolsLease/outBound/component/addToolsApply.vue @@ -1,5 +1,4 @@