From 30a896274a4940a85011ce2dfdccea7cf191f0ff Mon Sep 17 00:00:00 2001 From: xiaofajia <1665375861@qq.com> Date: Thu, 21 Nov 2024 11:10:35 +0800 Subject: [PATCH] =?UTF-8?q?=E5=8E=BB=E6=8E=89=E9=87=87=E8=B4=AD=E5=8D=95?= =?UTF-8?q?=E5=A4=84=E7=9A=84=E9=80=89=E6=8B=A9=E6=8C=89=E9=92=AE=E3=80=81?= =?UTF-8?q?=E8=A1=A5=E6=AD=A3=E7=AC=AC=E4=B8=80=E6=AC=A1=E8=BF=9B=E5=85=A5?= =?UTF-8?q?=E9=87=87=E8=B4=AD=E6=97=B6=E4=B8=8D=E6=98=BE=E7=A4=BA=E9=97=AE?= =?UTF-8?q?=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages-warehouse/inOutWarehouse/part.vue | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/pages-warehouse/inOutWarehouse/part.vue b/pages-warehouse/inOutWarehouse/part.vue index 01835d8..f3103fa 100644 --- a/pages-warehouse/inOutWarehouse/part.vue +++ b/pages-warehouse/inOutWarehouse/part.vue @@ -39,7 +39,7 @@ @@ -192,10 +192,17 @@ export default { this.getSoiId() }, getUnitName(id) { - const index = this.unitList.findIndex(item => item.value === id) - if (index !== -1) { - return this.unitList[index].label + if (this.unitList && this.unitList.length > 0) { + console.log("我第一次就拿到了") + const index = this.unitList.findIndex(item => item.value === id) + if (index !== -1) { + return this.unitList[index].label + }else { + return "请选择" + } } + console.log("我是重新去拿的") + this.listUnit() return "请选择" }, bindUnitChange(e, row) {