diff --git a/pages/procurement/components/addall.vue b/pages/procurement/components/addall.vue index 75ca969..8c10c55 100644 --- a/pages/procurement/components/addall.vue +++ b/pages/procurement/components/addall.vue @@ -5,7 +5,7 @@ - 确认将所有未添加状态的库存预警物料添加至购物车中,并且物料的采购数量为物料的库存上限-库存数量吗? + 确认将所有未添加状态的库存预警物料添加至购物车中,并且物料的采购数量为物料的库存上限减去库存数量吗? 取消 确定 diff --git a/pages/procurement/components/calculator.vue b/pages/procurement/components/calculator.vue index 6f1f9b3..6736705 100644 --- a/pages/procurement/components/calculator.vue +++ b/pages/procurement/components/calculator.vue @@ -147,9 +147,17 @@ num:1 } ]; - type.value = a.find(item=> - item.multiUnitType == props.caigouobj.multiUnitType - ); + if(props.caigouobj.wlUnits){ + type.value = a.find(item=> + item.unit == props.caigouobj.wlUnits + ); + console.log(props.caigouobj.wlUnits,type.value) + }else{ + type.value = a.find(item=> + item.multiUnitType == props.caigouobj.multiUnitType + ); + } + cgdwarr.value = a; let n = []; @@ -159,6 +167,9 @@ id = props.caigouobj.suppliers.split(/[, ]+/); n.forEach((item,i)=>{ gysarr.value.push({'name':item,'id':id[i]}) + if(item==props.caigouobj.suppliersName){ + gysid(i) + } }) if(props.caigouobj.purchaseQuantity){ props.caigouobj.upperLimit=props.caigouobj.wlUpperLimit diff --git a/pages/procurement/components/carditem.vue b/pages/procurement/components/carditem.vue index aad3732..17ad4ce 100644 --- a/pages/procurement/components/carditem.vue +++ b/pages/procurement/components/carditem.vue @@ -92,7 +92,7 @@ }) const caigouobj = ref({}) const addcar = (v : any,i:number) => { - if(v.kcsl>=v.upperLimit){ + if(Number(v.kcsl)>=Number(v.upperLimit)){ uni.showToast({ title:'库存数量已满,不可添加购物车!', icon:'none' diff --git a/pages/procurement/components/carlist.vue b/pages/procurement/components/carlist.vue index 6002a1d..1b85d55 100644 --- a/pages/procurement/components/carlist.vue +++ b/pages/procurement/components/carlist.vue @@ -33,7 +33,7 @@ 采购单位: {{v.wlUnits}} - 供应商: {{v.suppliersName}}{{v.suppliersName}} + 供应商: {{v.suppliersName}} diff --git a/pages/procurement/components/classification.vue b/pages/procurement/components/classification.vue index 4681e0d..513aa00 100644 --- a/pages/procurement/components/classification.vue +++ b/pages/procurement/components/classification.vue @@ -55,7 +55,7 @@ - 重置 + 重置 确定 ({{num>99?'99+':num}}件物料) @@ -116,10 +116,12 @@ medicationId: scroll.act3 > -1 ? TreeData.value[scroll.act1].children[scroll.act2].children[scroll.act3].key : '', suppliers: gysidnum.value > -1 ? gysarr.value[gysidnum.value].suppliers : '' } + console.log(obj) switch (props.typenum) { case 0: // 采购单 getTreeDataWlnum(obj).then(res => { + console.log(res) num.value = res.result.totalSize; }) break; @@ -138,13 +140,13 @@ default: break; } - } const getMaterial = () => { switch (props.typenum) { case 0: // 采购单 getMaterialTreeData({ 'nuId': uni.getStorageSync('nuId') }).then(res => { + console.log(res, uni.getStorageSync('nuId')) TreeData.value = res.result; getTreelnum() }) diff --git a/pages/procurement/purchaseorder.vue b/pages/procurement/purchaseorder.vue index c670d0b..08cb05b 100644 --- a/pages/procurement/purchaseorder.vue +++ b/pages/procurement/purchaseorder.vue @@ -445,13 +445,7 @@ form.cgdId = plsbuy.value[index].id form.pageNo = 1 form.canpull = true; - queryCgdInfoList(form).then(res => { - InvoicingList.value = [] - InvoicingList.value.push(...res.result.records); - if (form.pageNo) { - clickmiddle(0); - } - }) + queryInvo(); } const showvalue = ref({ materialImg: "" @@ -461,7 +455,7 @@ uni.navigateBack() } const form = reactive({ - nuId: '', + nuId: uni.getStorageSync('nuId'), pageNo: 1, pageSize: 9, categoryId: '', @@ -474,7 +468,7 @@ canpull: true, }) const mobanform = { - nuId: '', + nuId: uni.getStorageSync('nuId'), pageNo: 1, pageSize: 9, categoryId: '', @@ -493,8 +487,9 @@ const InvoicingList = ref([]) const queryInvo = () => { queryCgdInfoList(form).then(res => { + console.log(res.result.records) InvoicingList.value.push(...res.result.records); - clickmiddle(0); + clickmiddle(middletarget.value); }) } @@ -503,9 +498,22 @@ form.pageNo = 1; InvoicingList.value = []; middletarget.value = 0; - form.wlParamInfo = searchValue.value; - form.cgdId = plsbuy.value[lefttarget.value].id - queryInvo(); + // form.wlParamInfo = searchValue.value; + // form.cgdId = plsbuy.value[lefttarget.value].id + // queryInvo(); + + plzinfo.pageNo = 1; + plsbuy.value = []; + queryCgdList(plzinfo).then((res : any) => { + plsbuy.value.push(...res.result.records) + if (res.result.records.length) { + form.cgdId = plsbuy.value[0].id + queryInvo(); + } + if (res.result.records.length < plzinfo.pageSize) { + plzinfo.canpull = false; + } + }) } const moreindex = ref(-1); const zuofeiindex = ref(-1); diff --git a/unpackage/dist/dev/.nvue/pages/camera.js b/unpackage/dist/dev/.nvue/pages/camera.js index 12310ff..04100f2 100644 --- a/unpackage/dist/dev/.nvue/pages/camera.js +++ b/unpackage/dist/dev/.nvue/pages/camera.js @@ -574,7 +574,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) { ) ]); } -const camera = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["styles", [_style_0]], ["__file", "D:/hldy_app_mini/pages/camera.nvue"]]); +const camera = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["styles", [_style_0]], ["__file", "D:/项目/hldy_app_mini/pages/camera.nvue"]]); export { camera as default }; diff --git a/unpackage/dist/dev/.nvue/pages/fullcamera.js b/unpackage/dist/dev/.nvue/pages/fullcamera.js index dd59bdc..c959abe 100644 --- a/unpackage/dist/dev/.nvue/pages/fullcamera.js +++ b/unpackage/dist/dev/.nvue/pages/fullcamera.js @@ -577,7 +577,7 @@ function _sfc_render(_ctx, _cache, $props, $setup, $data, $options) { ) ]); } -const fullcamera = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["styles", [_style_0]], ["__file", "D:/hldy_app_mini/pages/fullcamera.nvue"]]); +const fullcamera = /* @__PURE__ */ _export_sfc(_sfc_main, [["render", _sfc_render], ["styles", [_style_0]], ["__file", "D:/项目/hldy_app_mini/pages/fullcamera.nvue"]]); export { fullcamera as default };