From 18c5a5565809e6a1761beb251d47e1c490b4fa85 Mon Sep 17 00:00:00 2001
From: weipengfei <2187978347@qq.com>
Date: Sat, 11 May 2024 16:09:33 +0800
Subject: [PATCH] 1
---
.../opurchaseclass/component/goodsOffer.vue | 89 ++++++++++++++++---
src/views/opurchase/opurchaseclass/detail.vue | 1 +
2 files changed, 80 insertions(+), 10 deletions(-)
diff --git a/src/views/opurchase/opurchaseclass/component/goodsOffer.vue b/src/views/opurchase/opurchaseclass/component/goodsOffer.vue
index 5f890ee..38a715c 100644
--- a/src/views/opurchase/opurchaseclass/component/goodsOffer.vue
+++ b/src/views/opurchase/opurchaseclass/component/goodsOffer.vue
@@ -13,7 +13,7 @@
-
+
采纳
- 商品已采纳
+ 已入库
+ 入库
+ 等待供应商报价
+
+
+
+ {{ updateInfo.supplier_name }}
+
+
+ {{ updateInfo.goods_name }}
+
+
+ ¥ {{ updateInfo.price }} / {{ updateInfo.unit_name }}
+
+
+ {{ updateInfo.q_nums }}
+
+
+
+
+
+
+
+
+
+
+
+
@@ -104,12 +146,39 @@ const changeType = (e: any) => {
getLists();
};
-const offerGood = (row: any) => {
- apiOpurchaseclassGoodsOfferUpdate({
- id: row.id,
- }).then((res) => {
- getLists();
- });
+const dialogVisible = ref(false);
+const updateInfo = ref({
+ id: "",
+ type: 0,
+ notes: "", //备注
+ nums: 0,//实际数量
+ q_nums: 0, //应到数量
+});
+const offerGood = (row: any, type: number) => {
+ //type:0 采纳,1 入库
+ updateInfo.value = Object.assign(
+ {
+ id: "",
+ type: type,
+ notes: "", //备注
+ nums: 0,
+ },
+ row
+ );
+ if(type==0) return goodsOfferUpdate(); // 采纳时直接成功, 入库弹窗显示数量
+ updateInfo.value.q_nums = row.nums;
+ dialogVisible.value = true;
};
+const goodsOfferUpdate = () => {
+ apiOpurchaseclassGoodsOfferUpdate({
+ id: updateInfo.value.id,
+ type: updateInfo.value.type,
+ notes: updateInfo.value.notes, //备注
+ nums: updateInfo.value.nums,
+ }).then((res) => {
+ getLists();
+ dialogVisible.value = false;
+ });
+};
diff --git a/src/views/opurchase/opurchaseclass/detail.vue b/src/views/opurchase/opurchaseclass/detail.vue
index 4fb27b9..b9bb1ea 100644
--- a/src/views/opurchase/opurchaseclass/detail.vue
+++ b/src/views/opurchase/opurchaseclass/detail.vue
@@ -37,6 +37,7 @@
+