From a24c34af0c00a59c94e1a6ebc2cbbc0814215f21 Mon Sep 17 00:00:00 2001
From: spring <2396852758@qq.com>
Date: 星期二, 17 三月 2026 14:39:27 +0800
Subject: [PATCH] fix: 新增库存(半成品)时,没有库存数量输入框

---
 src/views/collaborativeApproval/approvalProcess/components/approvalDia.vue |   58 +++++++++++++++++++++++++++++++++++++++++++++++++++++-----
 1 files changed, 53 insertions(+), 5 deletions(-)

diff --git a/src/views/collaborativeApproval/approvalProcess/components/approvalDia.vue b/src/views/collaborativeApproval/approvalProcess/components/approvalDia.vue
index c3fb6d1..cb0b2a5 100644
--- a/src/views/collaborativeApproval/approvalProcess/components/approvalDia.vue
+++ b/src/views/collaborativeApproval/approvalProcess/components/approvalDia.vue
@@ -104,7 +104,7 @@
                 <h4>浜у搧鏄庣粏</h4>
                 <el-table :data="currentQuotation.products || []" border style="width: 100%">
                   <el-table-column prop="product" label="浜у搧鍚嶇О" />
-                  <el-table-column prop="specificationModel" label="瑙勬牸鍨嬪彿" />
+                  <el-table-column prop="specification" label="瑙勬牸鍨嬪彿" />
                   <el-table-column prop="unit" label="鍗曚綅" />
                   <el-table-column prop="unitPrice" label="鍗曚环">
                     <template #default="scope">楼{{ Number(scope.row.unitPrice ?? 0).toFixed(2) }}</template>
@@ -168,6 +168,43 @@
         </el-skeleton>
       </div>
 
+      <div v-if="isRawMaterialApproval" style="margin: 10px 0 18px;">
+        <el-divider content-position="left">鍘熸枡璇︽儏</el-divider>
+        <el-skeleton :loading="rawMaterialLoading" animated>
+          <template #template>
+            <el-skeleton-item variant="h3" style="width: 30%" />
+            <el-skeleton-item variant="text" style="width: 100%" />
+            <el-skeleton-item variant="text" style="width: 100%" />
+          </template>
+          <template #default>
+            <el-empty v-if="!currentRawMaterial" description="鏈煡璇㈠埌瀵瑰簲鍘熸枡璇︽儏" />
+            <template v-else>
+              <el-descriptions :column="2" border>
+                <el-descriptions-item label="浜у搧鍚嶇О">{{ currentRawMaterial.productName }}</el-descriptions-item>
+                <el-descriptions-item label="瑙勬牸">{{ currentRawMaterial.model }}</el-descriptions-item>
+                <el-descriptions-item label="鍗曚綅">{{ currentRawMaterial.unit }}</el-descriptions-item>
+                <el-descriptions-item label="鎵瑰彿">{{ currentRawMaterial.batchNo }}</el-descriptions-item>
+                <el-descriptions-item label="妫�楠岀被鍨�">{{ currentRawMaterial.checkTypeText }}</el-descriptions-item>
+                <el-descriptions-item label="妫�娴嬬粨鏋�">{{ currentRawMaterial.checkResultText }}</el-descriptions-item>
+                <el-descriptions-item label="妫�楠屽憳">{{ currentRawMaterial.checkUserName }}</el-descriptions-item>
+                <el-descriptions-item label="妫�娴嬫棩鏈�">{{ currentRawMaterial.checkTime }}</el-descriptions-item>
+              </el-descriptions>
+
+              <div style="margin-top: 20px;">
+                <h4>妫�娴嬮」鐩槑缁�</h4>
+                <el-table :data="currentRawMaterial.qualityInspectItem || []" border style="width: 100%">
+                  <el-table-column prop="name" label="妫�娴嬮」鐩�" />
+                  <el-table-column prop="unit" label="鍗曚綅" />
+                  <el-table-column prop="standardValue" label="鏍囧噯鍊�" />
+                  <el-table-column prop="internalControl" label="鍐呮帶鍊�" />
+                  <el-table-column prop="testValue" label="鍖栭獙鍊�" />
+                </el-table>
+              </div>
+            </template>
+          </template>
+        </el-skeleton>
+      </div>
+
       <el-form :model="{ activities }" ref="formRef" label-position="top">
         <el-steps :active="getActiveStep()" finish-status="success" process-status="process" align-center direction="vertical">
           <el-step
@@ -196,10 +233,6 @@
               </div>
               <div v-if="!activity.isShen" class="node-reason">
                 <span>瀹℃壒鎰忚锛�</span>{{ activity.approveNodeReason }}
-              </div>
-              <div v-if="!activity.isShen" class="node-reason">
-                <span>绛惧悕锛�</span>
-								<img :src="activity.urlTem" class="signImg" alt="" v-if="activity.urlTem"/>
               </div>
               <div v-else-if="activity.isShen">
                 <el-form-item
@@ -236,6 +269,7 @@
 import { WarningFilled, Edit, Check, MoreFilled } from '@element-plus/icons-vue'
 import { getQuotationList } from "@/api/salesManagement/salesQuotation.js";
 import { getPurchaseByCode } from "@/api/procurementManagement/procurementLedger.js";
+import {findRawMaterialDetail} from "@/api/qualityManagement/rawMaterial.js";
 const emit = defineEmits(['close'])
 const { proxy } = getCurrentInstance()
 
@@ -256,9 +290,12 @@
 const quotationLoading = ref(false)
 const currentQuotation = ref({})
 const purchaseLoading = ref(false)
+const rawMaterialLoading = ref(false)
 const currentPurchase = ref({})
+const currentRawMaterial = ref({})
 const isQuotationApproval = computed(() => Number(props.approveType) === 6)
 const isPurchaseApproval = computed(() => Number(props.approveType) === 5)
+const isRawMaterialApproval = computed(() => Number(props.approveType) === 9)
 
 const data = reactive({
 	form: {
@@ -295,10 +332,12 @@
 
 // 鎵撳紑寮规
 const openDialog = (type, row) => {
+  console.log(type, row);
   operationType.value = type;
   dialogFormVisible.value = true;
   currentQuotation.value = {}
   currentPurchase.value = {}
+  currentRawMaterial.value = {}
 	userListNoPageByTenantId().then((res) => {
 		userList.value = res.data;
 	});
@@ -359,6 +398,15 @@
     }
   }
 
+  if (isRawMaterialApproval.value) {
+    rawMaterialLoading.value = true
+    findRawMaterialDetail(row.approveRecordId).then(res => {
+      currentRawMaterial.value = res.data;
+    }).finally(() => {
+      rawMaterialLoading.value = false
+    })
+  }
+
   approveProcessDetails(row.approveId).then((res) => {
     activities.value = res.data
     // 澧炲姞isApproval瀛楁

--
Gitblit v1.9.3