From 90f68df4d0657a900565593bc2c4e0e3ef8cabe0 Mon Sep 17 00:00:00 2001
From: 曹睿 <360930172@qq.com>
Date: 星期四, 10 七月 2025 10:08:02 +0800
Subject: [PATCH] Merge branch 'dev' of http://114.132.189.42:9002/r/product-inventory-management into dev

---
 src/views/basicData/supplierManage/index.vue                               |   20 +
 src/views/inventoryManagement/issueManagement/index.vue                    |   36 +
 src/views/collaborativeApproval/approvalProcess/index.vue                  |  227 +++++++++++++
 src/api/inventoryManagement/stockIn.js                                     |   15 
 src/views/salesManagement/salesLedger/index.vue                            |    2 
 src/views/collaborativeApproval/approvalProcess/components/infoFormDia.vue |  263 +++++++++++++++
 src/api/inventoryManagement/stockManage.js                                 |    6 
 src/views/collaborativeApproval/approvalProcess/components/approvalDia.vue |  106 ++++++
 src/api/collaborativeApproval/approvalProcess.js                           |   48 ++
 src/views/basicData/customerFile/index.vue                                 |   62 ++
 src/api/inventoryManagement/stockOut.js                                    |    8 
 src/views/inventoryManagement/receiptManagement/index.vue                  |   51 ++
 src/views/inventoryManagement/stockManagement/index.vue                    |  107 +++--
 vite.config.js                                                             |    2 
 src/views/inventoryManagement/dispatchLog/index.vue                        |   20 
 15 files changed, 866 insertions(+), 107 deletions(-)

diff --git a/src/api/collaborativeApproval/approvalProcess.js b/src/api/collaborativeApproval/approvalProcess.js
new file mode 100644
index 0000000..4f8ca33
--- /dev/null
+++ b/src/api/collaborativeApproval/approvalProcess.js
@@ -0,0 +1,48 @@
+// 鍗忓悓瀹℃壒
+import request from "@/utils/request";
+
+export function approveProcessListPage(query) {
+    return request({
+        url: '/approveProcess/list',
+        method: 'get',
+        params: query,
+    })
+}
+export function getDept(query) {
+    return request({
+        url: '/approveProcess/getDept',
+        method: 'get',
+        params: query,
+    })
+}
+export function approveProcessGetInfo(query) {
+    return request({
+        url: '/approveProcess/get',
+        method: 'get',
+        params: query,
+    })
+}
+// 鏂板瀹℃壒娴佺▼
+export function approveProcessAdd(query) {
+    return request({
+        url: '/approveProcess/add',
+        method: 'post',
+        data: query,
+    })
+}
+// 淇敼瀹℃壒娴佺▼
+export function approveProcessUpdate(query) {
+    return request({
+        url: '/approveProcess/update',
+        method: 'post',
+        data: query,
+    })
+}
+// 鍒犻櫎瀹℃壒娴佺▼
+export function approveProcessDelete(query) {
+    return request({
+        url: '/approveProcess/deleteIds',
+        method: 'delete',
+        data: query,
+    })
+}
\ No newline at end of file
diff --git a/src/api/inventoryManagement/stockIn.js b/src/api/inventoryManagement/stockIn.js
index b03b60b..5e104f7 100644
--- a/src/api/inventoryManagement/stockIn.js
+++ b/src/api/inventoryManagement/stockIn.js
@@ -9,11 +9,20 @@
     });
 };
 
-// 淇敼搴撳瓨淇℃伅
+// 淇敼鍏ュ簱瀛樹俊鎭�
 export const updateStockIn = (data) => {
     return request({
         url: "/stockin/update",
-        method: "put",
+        method: "post",
+        data,
+    });
+};
+
+// 淇敼搴撳瓨淇℃伅
+export const updateManagement = (data) => {
+    return request({
+        url: "/stockin/updateManagement",
+        method: "post",
         data,
     });
 };
@@ -31,7 +40,7 @@
 export function delStockIn(ids) {
     return request({
         url: '/stockin/del',
-        method: 'delete',
+        method: 'post',
         data: ids
     })
 }
diff --git a/src/api/inventoryManagement/stockManage.js b/src/api/inventoryManagement/stockManage.js
index e309241..bb2081b 100644
--- a/src/api/inventoryManagement/stockManage.js
+++ b/src/api/inventoryManagement/stockManage.js
@@ -3,7 +3,7 @@
 // 鏌ヨ搴撳瓨淇℃伅鍒楄〃
 export const getStockManagePage = (params) => {
     return request({
-        url: "/stockmanagement/page",
+        url: "/stockin/listPageCopy",
         method: "get",
         params,
     });
@@ -22,8 +22,8 @@
 // 鍒犻櫎搴撳瓨淇℃伅
 export function delStockManage(ids) {
     return request({
-        url: '/stockmanagement/del',
-        method: 'delete',
+        url: '/stockin/del',
+        method: 'post',
         data: ids
     })
 }
diff --git a/src/api/inventoryManagement/stockOut.js b/src/api/inventoryManagement/stockOut.js
index 51ad1a8..5d410d9 100644
--- a/src/api/inventoryManagement/stockOut.js
+++ b/src/api/inventoryManagement/stockOut.js
@@ -3,7 +3,7 @@
 //鏌ヨ鍑哄簱鍒楄〃
 export const getStockOutPage = (params) => {
     return request({
-        url: "/stockout/page",
+        url: "/stockmanagement/listPage",
         method: "get",
         params,
     });
@@ -30,8 +30,8 @@
 //鍒犻櫎鍑哄簱淇℃伅
 export const delStockOut = (ids) => {
     return request({
-        url: '/stockout/del',
-        method: 'delete',
+        url: '/stockmanagement/del',
+        method: 'post',
         data: ids
     })
 }
@@ -39,7 +39,7 @@
 //瀵煎嚭鍑哄簱淇℃伅
 export const exportStockOut = (query) => {
     return request({
-        url: '/stockout/export',
+        url: '/stockmanagement/export',
         method: 'get',
         params: query,
         responseType: 'blob'
diff --git a/src/views/basicData/customerFile/index.vue b/src/views/basicData/customerFile/index.vue
index 89330c6..f0c1186 100644
--- a/src/views/basicData/customerFile/index.vue
+++ b/src/views/basicData/customerFile/index.vue
@@ -92,26 +92,25 @@
             </el-form-item>
           </el-col>
         </el-row>
-        <el-row :gutter="30">
+        <el-row :gutter="30" v-for="(contact, index) in formYYs.contactList" :key="index">
           <el-col :span="12">
             <el-form-item label="鑱旂郴浜猴細" prop="contactPerson">
-              <el-input
-                v-model="form.contactPerson"
-                placeholder="璇疯緭鍏�"
-                clearable
-              />
+              <el-input v-model="contact.contactPerson" placeholder="璇疯緭鍏�" clearable  />
             </el-form-item>
           </el-col>
           <el-col :span="12">
             <el-form-item label="鑱旂郴鐢佃瘽锛�" prop="contactPhone">
-              <el-input
-                v-model="form.contactPhone"
-                placeholder="璇疯緭鍏�"
-                clearable
-              />
+              <div style="display: flex; align-items: center;width: 100%;">
+                <el-input v-model="contact.contactPhone" placeholder="璇疯緭鍏�" clearable />
+                <el-button   @click="removeContact(index)" type="danger" circle style="margin-left: 5px;">
+                  <el-icon><Close /></el-icon>
+                </el-button>
+              </div>
             </el-form-item>
           </el-col>
         </el-row>
+        <el-button @click="addNewContact" style="margin-bottom: 10px;">+ 鏂板鑱旂郴浜�</el-button>
+
         <el-row :gutter="30">
           <el-col :span="12">
             <el-form-item label="閾惰鍩烘湰鎴凤細" prop="basicBankAccount">
@@ -318,6 +317,14 @@
 // 鐢ㄦ埛淇℃伅琛ㄥ崟寮规鏁版嵁
 const operationType = ref("");
 const dialogFormVisible = ref(false);
+const formYYs = ref({    // 鍏朵粬瀛楁...
+  contactList: [
+    {
+      contactPerson: "",
+      contactPhone: ""
+    }
+  ]
+});
 const data = reactive({
   searchForm: {
     customerName: "",
@@ -342,8 +349,8 @@
     ],
     companyAddress: [{ required: true, message: "璇疯緭鍏�", trigger: "blur" }],
     companyPhone: [{ required: true, message: "璇疯緭鍏�", trigger: "blur" }],
-    contactPerson: [{ required: true, message: "璇疯緭鍏�", trigger: "blur" }],
-    contactPhone: [{ required: true, message: "璇疯緭鍏�", trigger: "blur" }],
+    // contactPerson: [{ required: true, message: "璇疯緭鍏�", trigger: "blur" }],
+    // contactPhone: [{ required: true, message: "璇疯緭鍏�", trigger: "blur" }],
     maintainer: [{ required: false, message: "璇烽�夋嫨", trigger: "change" }],
     maintenanceTime: [
       { required: false, message: "璇烽�夋嫨", trigger: "change" },
@@ -366,7 +373,18 @@
   url: import.meta.env.VITE_APP_BASE_API + "/basic/customer/importData",
 });
 const { searchForm, form, rules } = toRefs(data);
+const addNewContact = () => {
+  formYYs.value.contactList.push({
+    contactPerson: "",
+    contactPhone: ""
+  });
+};
 
+const removeContact = (index) => {
+  if (formYYs.value.contactList.length > 1) {
+    formYYs.value.contactList.splice(index, 1);
+  }
+};
 // 鏌ヨ鍒楄〃
 /** 鎼滅储鎸夐挳鎿嶄綔 */
 const handleQuery = () => {
@@ -404,6 +422,12 @@
   operationType.value = type;
   form.value = {};
   form.value.maintainer = userStore.nickName;
+  formYYs.value.contactList = [
+    {
+      contactPerson: "",
+      contactPhone: ""
+    }
+  ];
   form.value.maintenanceTime = getCurrentDate();
   userListNoPage().then((res) => {
     userList.value = res.data;
@@ -411,6 +435,13 @@
   if (type === "edit") {
     getCustomer(row.id).then((res) => {
       form.value = { ...res.data };
+      formYYs.value.contactList = res.data.contactPerson.split(",").map((item, index) => {
+        return {
+          contactPerson: item,
+          contactPhone: res.data.contactPhone.split(",")[index]
+        }
+      });
+
     });
   }
   dialogFormVisible.value = true;
@@ -429,6 +460,11 @@
 };
 // 鎻愪氦鏂板
 const submitAdd = () => {
+  if(formYYs.value.contactList.length < 1){
+    return proxy.$modal.msgWarning("璇疯嚦灏戞坊鍔犱竴涓仈绯讳汉");
+  }
+  form.value.contactPerson = formYYs.value.contactList.map(item => item.contactPerson).join(",");
+  form.value.contactPhone = formYYs.value.contactList.map(item => item.contactPhone).join(",");
   addCustomer(form.value).then((res) => {
     proxy.$modal.msgSuccess("鎻愪氦鎴愬姛");
     closeDia();
diff --git a/src/views/basicData/supplierManage/index.vue b/src/views/basicData/supplierManage/index.vue
index 1412e8e..22216e3 100644
--- a/src/views/basicData/supplierManage/index.vue
+++ b/src/views/basicData/supplierManage/index.vue
@@ -199,13 +199,13 @@
         <template #tip>
           <div class="el-upload__tip text-center">
             <span>浠呭厑璁稿鍏ls銆亁lsx鏍煎紡鏂囦欢銆�</span>
-            <el-link
+            <!-- <el-link
               type="primary"
               :underline="false"
               style="font-size: 12px; vertical-align: baseline"
               @click="importTemplate"
               >涓嬭浇妯℃澘</el-link
-            >
+            > -->
           </div>
         </template>
       </el-upload>
@@ -350,6 +350,7 @@
 };
 /** 鎻愪氦涓婁紶鏂囦欢 */
 function submitFileForm() {
+  console.log(upload.url + '?updateSupport=' + upload.updateSupport)
   proxy.$refs["uploadRef"].submit();
 }
 const getList = () => {
@@ -367,6 +368,8 @@
   title: "",
   // 鏄惁绂佺敤涓婁紶
   isUploading: false,
+  // 鏄惁鏇存柊宸茬粡瀛樺湪鐨勭敤鎴锋暟鎹�
+  updateSupport: 1,
   // 璁剧疆涓婁紶鐨勮姹傚ご閮�
   headers: { Authorization: "Bearer " + getToken() },
   // 涓婁紶鐨勫湴鍧�
@@ -377,6 +380,19 @@
   upload.title = "渚涘簲鍟嗗鍏�";
   upload.open = true;
 }
+
+/**鏂囦欢涓婁紶涓鐞� */
+const handleFileUploadProgress = (event, file, fileList) => {
+  upload.isUploading = true;
+};
+
+/** 鏂囦欢涓婁紶鎴愬姛澶勭悊 */
+const handleFileSuccess = (response, file, fileList) => {
+  upload.open = false;
+  upload.isUploading = false;
+  proxy.$refs["uploadRef"].handleRemove(file);
+  getList();
+};
 // 琛ㄦ牸閫夋嫨鏁版嵁
 const handleSelectionChange = (selection) => {
   selectedRows.value = selection;
diff --git a/src/views/collaborativeApproval/approvalProcess/components/approvalDia.vue b/src/views/collaborativeApproval/approvalProcess/components/approvalDia.vue
new file mode 100644
index 0000000..57b5e38
--- /dev/null
+++ b/src/views/collaborativeApproval/approvalProcess/components/approvalDia.vue
@@ -0,0 +1,106 @@
+<template>
+  <div>
+    <el-dialog
+        v-model="dialogFormVisible"
+        :title="operationType === 'add' ? '鏂板瀹℃壒娴佺▼' : '缂栬緫瀹℃壒娴佺▼'"
+        width="700px"
+        @close="closeDia"
+    >
+      <el-form :model="{ activities }" ref="formRef" label-position="top">
+        <el-timeline style="max-width: 600px">
+          <el-timeline-item
+              v-for="(activity, index) in activities"
+              :key="index"
+              :type="activity.current ? 'primary' : ''"
+              :hollow="activity.current"
+              :timestamp="activity.timestamp"
+          >
+            <el-card>
+              <span style="font-size: 18px;font-weight: 700">{{activity.content}}</span>
+              <div style="margin: 10px 0">
+                <span style="font-size: 16px;font-weight: 600">瀹℃壒浜猴細{{activity.people}}</span>
+              </div>
+              <div>
+                <span style="margin-bottom: 8px;display: inline-block;font-size: 16px;font-weight: 600">瀹℃壒鎰忚锛�</span>
+                <el-form-item
+                  v-if="activity.current"
+                  :prop="'activities.' + index + '.value'"
+                  :rules="[{ required: true, message: '瀹℃壒鎰忚涓嶈兘涓虹┖', trigger: 'blur' }]"
+                >
+                  <el-input v-model="activity.value" clearable type="textarea" :disabled="operationType === 'view'"></el-input>
+                </el-form-item>
+                <el-form-item v-else>
+                  <el-input v-model="activity.value" clearable type="textarea" disabled></el-input>
+                </el-form-item>
+              </div>
+            </el-card>
+          </el-timeline-item>
+        </el-timeline>
+      </el-form>
+      <template #footer v-if="operationType === 'approval'">
+        <div class="dialog-footer">
+          <el-button type="primary" @click="submitForm">纭</el-button>
+          <el-button @click="closeDia">鍙栨秷</el-button>
+        </div>
+      </template>
+    </el-dialog>
+  </div>
+</template>
+
+<script setup>
+import {getCurrentInstance, ref} from "vue";
+const emit = defineEmits(['close'])
+const { proxy } = getCurrentInstance()
+
+const dialogFormVisible = ref(false);
+const operationType = ref('')
+const activities = ref([
+  {
+    content: '鑺傜偣1',
+    timestamp: '',
+    type: 'primary',
+    hollow: true,
+    people: 'admin',
+    value: ''
+  },
+  {
+    content: '鑺傜偣2',
+    timestamp: '',
+    type: '',
+    hollow: false,
+    current: true,
+    people: 'admin',
+    value: ''
+  },
+])
+const formRef = ref(null);
+
+// 鎵撳紑寮规
+const openDialog = (type, row) => {
+  operationType.value = type;
+  dialogFormVisible.value = true;
+}
+// 鎻愪氦瀹℃壒
+const submitForm = () => {
+  formRef.value.validate(valid => {
+    if (valid) {
+      // 鏍¢獙閫氳繃鍚庣殑閫昏緫
+    }
+  })
+}
+// 鍏抽棴寮规
+const closeDia = () => {
+  proxy.resetForm("formRef");
+  dialogFormVisible.value = false;
+  emit('close')
+};
+defineExpose({
+  openDialog,
+});
+</script>
+
+<style scoped>
+.el-timeline {
+  padding-left: 10px;
+}
+</style>
\ No newline at end of file
diff --git a/src/views/collaborativeApproval/approvalProcess/components/infoFormDia.vue b/src/views/collaborativeApproval/approvalProcess/components/infoFormDia.vue
new file mode 100644
index 0000000..585bc43
--- /dev/null
+++ b/src/views/collaborativeApproval/approvalProcess/components/infoFormDia.vue
@@ -0,0 +1,263 @@
+<template>
+  <div>
+    <el-dialog
+        v-model="dialogFormVisible"
+        :title="operationType === 'add' ? '鏂板瀹℃壒娴佺▼' : '缂栬緫瀹℃壒娴佺▼'"
+        width="50%"
+        @close="closeDia"
+    >
+      <el-form :model="form" label-width="140px" label-position="top" :rules="rules" ref="formRef">
+        <el-row>
+          <el-col :span="24">
+            <el-form-item label="娴佺▼缂栧彿锛�" prop="approveId">
+              <el-input v-model="form.approveId" placeholder="鑷姩缂栧彿" clearable disabled/>
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <el-row>
+          <el-col :span="24">
+            <el-form-item label="鐢宠閮ㄩ棬锛�" prop="approveDeptId">
+							<el-select
+								v-model="form.approveDeptId"
+								placeholder="閫夋嫨閮ㄩ棬"
+							>
+								<el-option
+									v-for="user in productOptions"
+									:key="user.deptId"
+									:label="user.deptName"
+									:value="user.deptId"
+								/>
+							</el-select>
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <el-row>
+          <el-col :span="24">
+            <el-form-item label="瀹℃壒浜嬬敱锛�" prop="approveReason">
+              <el-input v-model="form.approveReason" placeholder="璇疯緭鍏�" clearable type="textarea" />
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <!-- 瀹℃壒浜洪�夋嫨锛堝姩鎬佽妭鐐癸級 -->
+        <el-row>
+          <el-col :span="24">
+            <el-form-item>
+              <template #label>
+                <span>瀹℃壒浜洪�夋嫨锛�</span>
+                <el-button type="primary" @click="addApproverNode" style="margin-left: 8px;">鏂板鑺傜偣</el-button>
+              </template>
+              <div style="display: flex; align-items: flex-end; flex-wrap: wrap;">
+                <div
+                  v-for="(node, index) in approverNodes"
+                  :key="node.id"
+                  style="margin-right: 30px; text-align: center; margin-bottom: 10px;"
+                >
+                  <div>鑺傜偣{{ index + 1 }} 鈫�</div>
+                  <el-select
+                    v-model="node.userId"
+                    placeholder="閫夋嫨浜哄憳"
+                    style="width: 120px; margin-bottom: 8px;"
+                  >
+                    <el-option
+                      v-for="user in userList"
+                      :key="user.userId"
+                      :label="user.nickName"
+                      :value="user.userId"
+                    />
+                  </el-select>
+                  <div>
+                    <el-button
+                      type="danger"
+                      size="small"
+                      @click="removeApproverNode(index)"
+                      v-if="approverNodes.length > 1"
+                    >鍒犻櫎</el-button>
+                  </div>
+                </div>
+              </div>
+            </el-form-item>
+          </el-col>
+        </el-row>
+        <el-row :gutter="30">
+          <el-col :span="12">
+            <el-form-item label="鐢宠浜猴細" prop="approveUser">
+              <el-input v-model="form.approveUser" placeholder="璇疯緭鍏�" clearable/>
+            </el-form-item>
+          </el-col>
+          <el-col :span="12">
+            <el-form-item label="鐢宠鏃ユ湡锛�" prop="approveTime">
+              <el-date-picker
+                  v-model="form.approveTime"
+                  type="date"
+                  placeholder="璇烽�夋嫨鏃ユ湡"
+                  value-format="YYYY-MM-DD"
+                  format="YYYY-MM-DD"
+                  clearable
+                  style="width: 100%"
+              />
+            </el-form-item>
+          </el-col>
+        </el-row>
+      </el-form>
+      <template #footer>
+        <div class="dialog-footer">
+          <el-button type="primary" @click="submitForm">纭</el-button>
+          <el-button @click="closeDia">鍙栨秷</el-button>
+        </div>
+      </template>
+    </el-dialog>
+  </div>
+</template>
+
+<script setup>
+import {ref, reactive, toRefs, getCurrentInstance} from "vue";
+import {
+  approveProcessAdd, approveProcessGetInfo,
+  approveProcessUpdate,
+  getDept
+} from "../../../../api/collaborativeApproval/approvalProcess.js";
+import {userListNoPage} from "../../../../api/system/user.js";
+const { proxy } = getCurrentInstance()
+const emit = defineEmits(['close'])
+import useUserStore from "@/store/modules/user";
+const userStore = useUserStore();
+
+const dialogFormVisible = ref(false);
+const operationType = ref('')
+const data = reactive({
+  form: {
+    approveTime: "",
+    approveId: "",
+    approveUser: "",
+		approveDeptId: "",
+    approveReason: "",
+    checkResult: "",
+    approverList: [] // 鏂板瀛楁锛屽瓨鍌ㄦ墍鏈夎妭鐐圭殑瀹℃壒浜篿d
+  },
+  rules: {
+    approveTime: [{ required: false, message: "璇疯緭鍏�", trigger: "change" },],
+    approveId: [{ required: false, message: "璇疯緭鍏�", trigger: "blur" }],
+    approveUser: [{ required: false, message: "璇疯緭鍏�", trigger: "blur" }],
+		approveDeptId: [{ required: true, message: "璇疯緭鍏�", trigger: "blur" }],
+    approveReason: [{ required: true, message: "璇疯緭鍏�", trigger: "blur" }],
+    checkResult: [{ required: false, message: "璇疯緭鍏�", trigger: "blur" }],
+  },
+});
+const { form, rules } = toRefs(data);
+const productOptions = ref([]);
+
+// 瀹℃壒浜鸿妭鐐圭浉鍏�
+const approverNodes = ref([
+  { id: 1, userId: null }
+])
+let nextApproverId = 2
+const userList = ref([])
+function addApproverNode() {
+  approverNodes.value.push({ id: nextApproverId++, userId: null })
+}
+function removeApproverNode(index) {
+  approverNodes.value.splice(index, 1)
+}
+
+// 鎵撳紑寮规
+const openDialog = (type, row) => {
+  operationType.value = type;
+  dialogFormVisible.value = true;
+  userListNoPage().then((res) => {
+    userList.value = res.data;
+  });
+  getProductOptions();
+	form.value = {}
+	approverNodes.value = [
+		{ id: 1, userId: null }
+	]
+  form.value.approveUser = userStore.nickName;
+  form.value.approveTime = getCurrentDate();
+  if (operationType.value === 'edit') {
+    approveProcessGetInfo({id: row.approveId,approveReason: '1'}).then(res => {
+			form.value = {...res.data}
+      // 鍙嶆樉瀹℃壒浜�
+      // if (res.data && res.data.approverIds) {
+      //   const nameArr = res.data.approverIds.split('锛�')
+      //   approverNodes.value = nameArr.map((name, idx) => {
+      //     const user = userList.value.find(u => u.name === name)
+      //     return { id: idx + 1, userId: user ? user.id : null }
+      //   })
+      //   nextApproverId = nameArr.length + 1
+      // } else if (row.approverList && Array.isArray(row.approverList) && row.approverList.length > 0) {
+      //   approverNodes.value = row.approverList.map((userId, idx) => ({ id: idx + 1, userId }))
+      //   nextApproverId = row.approverList.length + 1
+      // } else {
+      //   approverNodes.value = [{ id: 1, userId: null }]
+      //   nextApproverId = 2
+      // }
+    })
+  }
+}
+const getProductOptions = () => {
+  getDept().then((res) => {
+    productOptions.value = res.data;
+  });
+};
+function convertIdToValue(data) {
+  return data.map((item) => {
+    const { id, children, ...rest } = item;
+    const newItem = {
+      ...rest,
+      value: id, // 灏� id 鏀逛负 value
+    };
+    if (children && children.length > 0) {
+      newItem.children = convertIdToValue(children);
+    }
+    
+    return newItem;
+  });
+}
+// 鎻愪氦浜у搧琛ㄥ崟
+const submitForm = () => {
+  // 鏀堕泦鎵�鏈夎妭鐐圭殑瀹℃壒浜篿d
+  form.value.approverIds = approverNodes.value.map(node => node.userId).join(',')
+  // 瀹℃壒浜哄繀濉牎楠�
+  const hasEmptyApprover = approverNodes.value.some(node => !node.userId)
+  if (hasEmptyApprover) {
+    proxy.$modal.msgError("璇蜂负鎵�鏈夊鎵硅妭鐐归�夋嫨瀹℃壒浜猴紒")
+    return
+  }
+  proxy.$refs.formRef.validate(valid => {
+    if (valid) {
+      if (operationType.value === "add") {
+        approveProcessAdd(form.value).then(res => {
+          proxy.$modal.msgSuccess("鎻愪氦鎴愬姛");
+          closeDia();
+        })
+      } else {
+        approveProcessUpdate(form.value).then(res => {
+          proxy.$modal.msgSuccess("鎻愪氦鎴愬姛");
+          closeDia();
+        })
+      }
+    }
+  })
+}
+// 鍏抽棴寮规
+const closeDia = () => {
+  proxy.resetForm("formRef");
+  dialogFormVisible.value = false;
+  emit('close')
+};
+// 鑾峰彇褰撳墠鏃ユ湡骞舵牸寮忓寲涓� YYYY-MM-DD
+function getCurrentDate() {
+  const today = new Date();
+  const year = today.getFullYear();
+  const month = String(today.getMonth() + 1).padStart(2, "0"); // 鏈堜唤浠�0寮�濮�
+  const day = String(today.getDate()).padStart(2, "0");
+  return `${year}-${month}-${day}`;
+}
+defineExpose({
+  openDialog,
+});
+</script>
+
+<style scoped>
+
+</style>
\ No newline at end of file
diff --git a/src/views/collaborativeApproval/approvalProcess/index.vue b/src/views/collaborativeApproval/approvalProcess/index.vue
new file mode 100644
index 0000000..ab98ab8
--- /dev/null
+++ b/src/views/collaborativeApproval/approvalProcess/index.vue
@@ -0,0 +1,227 @@
+<template>
+  <div class="app-container">
+    <div class="search_form">
+      <div>
+        <span class="search_title">渚涘簲鍟嗭細</span>
+        <el-input
+            v-model="searchForm.supplier"
+            style="width: 240px"
+            placeholder="璇疯緭鍏ヤ緵搴斿晢鎼滅储"
+            @change="handleQuery"
+            clearable
+            :prefix-icon="Search"
+        />
+        <el-button type="primary" @click="handleQuery" style="margin-left: 10px"
+        >鎼滅储</el-button
+        >
+      </div>
+      <div>
+        <el-button type="primary" @click="openForm('add')">鏂板</el-button>
+<!--        <el-button @click="handleOut">瀵煎嚭</el-button>-->
+        <el-button type="danger" plain @click="handleDelete">鍒犻櫎</el-button>
+      </div>
+    </div>
+    <div class="table_list">
+      <PIMTable
+          rowKey="id"
+          :column="tableColumn"
+          :tableData="tableData"
+          :page="page"
+          :isSelection="true"
+          @selection-change="handleSelectionChange"
+          :tableLoading="tableLoading"
+          @pagination="pagination"
+          :total="page.total"
+      ></PIMTable>
+    </div>
+    <info-form-dia ref="infoFormDia" @close="handleQuery"></info-form-dia>
+    <approval-dia ref="approvalDia" @close="handleQuery"></approval-dia>
+  </div>
+</template>
+
+<script setup>
+import { Search } from "@element-plus/icons-vue";
+import {onMounted, ref} from "vue";
+import {ElMessageBox} from "element-plus";
+import {qualityInspectDel, qualityInspectListPage} from "@/api/qualityManagement/rawMaterialInspection.js";
+import InfoFormDia from "@/views/collaborativeApproval/approvalProcess/components/infoFormDia.vue";
+import ApprovalDia from "@/views/collaborativeApproval/approvalProcess/components/approvalDia.vue";
+import {approveProcessDelete, approveProcessListPage} from "../../../api/collaborativeApproval/approvalProcess.js";
+
+const data = reactive({
+  searchForm: {
+    supplier: "",
+  },
+});
+const { searchForm } = toRefs(data);
+const tableColumn = ref([
+  {
+    label: "瀹℃壒鐘舵��",
+    prop: "approveStatus",
+    dataType: "tag",
+    formatData: (params) => {
+      if (params == 0) {
+        return "寰呭鏍�";
+      } else if (params == 1) {
+        return "瀹℃牳涓�";
+      } else if (params == 2) {
+        return "瀹℃牳瀹屾垚";
+      } else {
+        return '涓嶉�氳繃';
+      }
+    },
+    formatType: (params) => {
+      if (params == 0) {
+        return "warning";
+      } else if (params == 1) {
+        return "primary";
+      }  else if (params == 2) {
+        return "success";
+      } else {
+        return 'danger';
+      }
+    },
+  },
+  {
+    label: "娴佺▼缂栧彿",
+    prop: "approveId",
+    width: 230
+  },
+  {
+    label: "鐢宠閮ㄩ棬",
+    prop: "approveDeptName",
+  },
+  {
+    label: "瀹℃壒浜嬬敱",
+    prop: "approveReason",
+  },
+  {
+    label: "鐢宠浜�",
+    prop: "approveUser",
+  },
+  {
+    label: "鐢宠鏃ユ湡",
+    prop: "approveTime",
+  },
+  {
+    label: "缁撴潫鏃ユ湡",
+    prop: "approveOverTime",
+    width: 120
+  },
+  {
+    label: "褰撳墠瀹℃壒浜�",
+    prop: "checkCompany",
+    width: 120
+  },
+  {
+    dataType: "action",
+    label: "鎿嶄綔",
+    align: "center",
+    fixed: "right",
+    width: 150,
+    operation: [
+      {
+        name: "缂栬緫",
+        type: "text",
+        clickFun: (row) => {
+          openForm("edit", row);
+        },
+      },
+      {
+        name: "瀹℃牳",
+        type: "text",
+        clickFun: (row) => {
+          openApprovalDia("approval", row);
+        },
+      },
+      {
+        name: "璇︽儏",
+        type: "text",
+        clickFun: (row) => {
+          openApprovalDia('view', row);
+        },
+      },
+    ],
+  },
+]);
+const tableData = ref([]);
+const selectedRows = ref([]);
+const tableLoading = ref(false);
+const page = reactive({
+  current: 1,
+  size: 100,
+  total: 0
+});
+const infoFormDia = ref()
+const approvalDia = ref()
+const { proxy } = getCurrentInstance()
+
+// 鏌ヨ鍒楄〃
+/** 鎼滅储鎸夐挳鎿嶄綔 */
+const handleQuery = () => {
+  page.current = 1;
+  getList();
+};
+const pagination = (obj) => {
+  page.current = obj.page;
+  page.size = obj.limit;
+  getList();
+};
+const getList = () => {
+  tableLoading.value = true;
+  approveProcessListPage({...page, ...searchForm.value,}).then(res => {
+    tableLoading.value = false;
+    tableData.value = res.data.records
+    page.total = res.data.total;
+  }).catch(err => {
+    tableLoading.value = false;
+  })
+};
+// 琛ㄦ牸閫夋嫨鏁版嵁
+const handleSelectionChange = (selection) => {
+  selectedRows.value = selection;
+};
+
+// 鎵撳紑鏂板銆佺紪杈戝脊妗�
+const openForm = (type, row) => {
+  nextTick(() => {
+    infoFormDia.value?.openDialog(type, row)
+  })
+};
+// 鎵撳紑鏂板妫�楠屽脊妗�
+const openApprovalDia = (type, row) => {
+  nextTick(() => {
+    approvalDia.value?.openDialog(type, row)
+  })
+};
+
+// 鍒犻櫎
+const handleDelete = () => {
+  let ids = [];
+  if (selectedRows.value.length > 0) {
+    ids = selectedRows.value.map((item) => item.id);
+  } else {
+    proxy.$modal.msgWarning("璇烽�夋嫨鏁版嵁");
+    return;
+  }
+  ElMessageBox.confirm("閫変腑鐨勫唴瀹瑰皢琚垹闄わ紝鏄惁纭鍒犻櫎锛�", "瀵煎嚭", {
+    confirmButtonText: "纭",
+    cancelButtonText: "鍙栨秷",
+    type: "warning",
+  })
+      .then(() => {
+        approveProcessDelete(ids).then((res) => {
+          proxy.$modal.msgSuccess("鍒犻櫎鎴愬姛");
+          getList();
+        });
+      })
+      .catch(() => {
+        proxy.$modal.msg("宸插彇娑�");
+      });
+};
+onMounted(() => {
+  getList();
+});
+</script>
+
+<style scoped></style>
diff --git a/src/views/inventoryManagement/dispatchLog/index.vue b/src/views/inventoryManagement/dispatchLog/index.vue
index 81eff0b..e523430 100644
--- a/src/views/inventoryManagement/dispatchLog/index.vue
+++ b/src/views/inventoryManagement/dispatchLog/index.vue
@@ -38,14 +38,14 @@
         <el-table-column align="center" label="搴忓彿" type="index" width="60" />
         <el-table-column
           label="鍑哄簱鏃ユ湡"
-          prop="inboundTime"
-          width="100"
+          prop="createTime"
+          min-width="250"
           show-overflow-tooltip
         />
         <el-table-column
           label="渚涘簲鍟嗗悕绉�"
           prop="supplierName"
-          width="160"
+          width="250"
           show-overflow-tooltip
         />
         <el-table-column
@@ -68,37 +68,37 @@
         />
         <el-table-column
           label="鍑哄簱鏁伴噺"
-          prop="inboundQuantity"
+          prop="inboundNum"
           width="100"
           show-overflow-tooltip
         />
         <el-table-column
           label="鍚◣鍗曚环(鍏�)"
-          prop="entryDate"
+          prop="taxInclusiveUnitPrice"
           width="100"
           show-overflow-tooltip
         />
         <el-table-column
           label="鍚◣鎬讳环(鍏�)"
-          prop="executionDate"
+          prop="taxInclusiveTotalPrice"
           width="100"
           show-overflow-tooltip
         />
         <el-table-column
           label="绋庣巼(%)"
-          prop="executionDate"
+          prop="taxRate"
           width="100"
           show-overflow-tooltip
         />
         <el-table-column
           label="涓嶅惈绋庢�讳环(鍏�)"
-          prop="executionDate"
+          prop="taxExclusiveTotalPrice"
           width="180"
           show-overflow-tooltip
         />
         <el-table-column
           label="鍑哄簱浜�"
-          prop="nickname"
+          prop="createBy"
           width="80"
           show-overflow-tooltip
         />
@@ -259,7 +259,7 @@
     type: "warning",
   })
     .then(() => {
-      delStockOut(ids).then((res) => {
+      delStockOut({ids:ids}).then((res) => {
         proxy.$modal.msgSuccess("鍒犻櫎鎴愬姛");
         getList();
       });
diff --git a/src/views/inventoryManagement/issueManagement/index.vue b/src/views/inventoryManagement/issueManagement/index.vue
index 7ed1f68..2c28e35 100644
--- a/src/views/inventoryManagement/issueManagement/index.vue
+++ b/src/views/inventoryManagement/issueManagement/index.vue
@@ -19,18 +19,19 @@
         :summary-method="summarizeMainTable" height="calc(100vh - 18.5em)">
         <el-table-column align="center" type="selection" width="55" />
         <el-table-column align="center" label="搴忓彿" type="index" width="60" />
-        <el-table-column label="鍏ュ簱鏃堕棿" prop="inboundTime" width="100" show-overflow-tooltip />
-        <el-table-column label="鍏ュ簱鎵规" prop="inboundBatch" width="160" show-overflow-tooltip />
+        <el-table-column label="鍏ュ簱鏃堕棿" prop="createTime" width="100" show-overflow-tooltip />
+        <el-table-column label="鍏ュ簱鎵规" prop="inboundBatches" width="160" show-overflow-tooltip />
         <el-table-column label="渚涘簲鍟嗗悕绉�" prop="supplierName" width="160" show-overflow-tooltip />
-        <el-table-column label="浜у搧澶х被" prop="productName" width="100" show-overflow-tooltip />
-        <el-table-column label="瑙勬牸鍨嬪彿" prop="model" width="160" show-overflow-tooltip />
+        <el-table-column label="浜у搧澶х被" prop="productCategory" width="100" show-overflow-tooltip />
+        <el-table-column label="瑙勬牸鍨嬪彿" prop="specificationModel" width="160" show-overflow-tooltip />
         <el-table-column label="鍗曚綅" prop="unit" width="70" show-overflow-tooltip />
-        <el-table-column label="鍏ュ簱鏁伴噺" prop="stockQuantity" width="90" show-overflow-tooltip />
+        <el-table-column label="鍏ュ簱鏁伴噺" prop="inboundNum" width="90" show-overflow-tooltip />
+        <el-table-column label="搴撳瓨鏁伴噺" prop="inboundNum0" width="90" show-overflow-tooltip />
         <el-table-column label="鍚◣鍗曚环" prop="taxInclusiveUnitPrice" width="100" show-overflow-tooltip />
         <el-table-column label="鍚◣鎬讳环" prop="taxInclusiveTotalPrice" width="100" show-overflow-tooltip />
         <el-table-column label="绋庣巼(%)" prop="taxRate" width="80" show-overflow-tooltip />
         <el-table-column label="涓嶅惈绋庢�讳环" prop="taxExclusiveTotalPrice" width="100" show-overflow-tooltip />
-        <el-table-column label="鍏ュ簱浜�" prop="nickName" width="80" show-overflow-tooltip />
+        <el-table-column label="鍏ュ簱浜�" prop="createBy" width="80" show-overflow-tooltip />
         <el-table-column fixed="right" label="鎿嶄綔" min-width="60" align="center">
           <template #default="scope">
             <el-button link type="primary" size="small" @click="openForm(scope.row);">棰嗙敤</el-button>
@@ -71,6 +72,9 @@
 import { ElMessageBox } from "element-plus";
 import useUserStore from '@/store/modules/user'
 import { userListNoPage } from "@/api/system/user.js";
+import {
+  getStockInPage
+} from "@/api/inventoryManagement/stockIn.js";
 import {
   getStockManagePage,
     delStockManage,
@@ -124,7 +128,7 @@
 }
 const getList = () => {
   tableLoading.value = true
-  getStockManagePage({ ...searchForm.value, ...page }).then(res => {
+  getStockInPage({ ...searchForm.value, ...page }).then(res => {
     tableLoading.value = false
     tableData.value = res.data.records
     console.log('res', res.data.records)
@@ -161,10 +165,15 @@
 };
 const currentRowId = ref(null) // 鏂板锛氬瓨鍌ㄥ綋鍓嶆搷浣滅殑琛孖D
 
+const currentRowNum = ref(0)
+const salesLedgerProductId = ref(null);
+
 // 鎵撳紑寮规
 const openForm = async (row) => {
   dialogFormVisible.value = true
   currentRowId.value = row.id
+  currentRowNum.value = row.inboundNum0
+  salesLedgerProductId.value = row.salesLedgerProductId
   form.value = {}
   // 鍒濆鍖栬〃鍗曟暟鎹�
   form.value = {
@@ -185,13 +194,18 @@
 
 // 鎻愪氦琛ㄥ崟
 const submitForm = () => {
+  let num = Number(form.value.inboundQuantity)
+  if(num < 1 || num > currentRowNum.value){
+    return proxy.$modal.msgWarning("璇峰~鍏ユ湁鏁堟暟瀛�")
+  }
   proxy.$refs["formRef"].validate(valid => {
     if (valid && currentRowId.value) {
       const outData = {
         id: currentRowId.value, // 鍘熷璁板綍ID
-        Quantity: form.value.inboundQuantity, // 鍑哄簱鏁伴噺
-        Time: form.value.inboundTime, // 鍑哄簱鏃堕棿
-        userId: form.value.userId // 鎿嶄綔浜�
+        salesLedgerProductId: salesLedgerProductId.value,
+        quantity: form.value.inboundQuantity, // 鍑哄簱鏁伴噺
+        time: form.value.inboundTime, // 鍑哄簱鏃堕棿
+        userId: form.value.nickName // 鎿嶄綔浜�
       }
       console.log(outData)
 
@@ -221,7 +235,7 @@
     type: 'warning',
   }
   ).then(() => {
-    proxy.download("/stockmanagement/export", {}, '鍏ュ簱鍙拌处.xlsx')
+    proxy.download("/stockin/export", {}, '鍏ュ簱鍙拌处.xlsx')
   }).catch(() => {
     proxy.$modal.msg("宸插彇娑�")
   })
diff --git a/src/views/inventoryManagement/receiptManagement/index.vue b/src/views/inventoryManagement/receiptManagement/index.vue
index 734d9e7..6b098b0 100644
--- a/src/views/inventoryManagement/receiptManagement/index.vue
+++ b/src/views/inventoryManagement/receiptManagement/index.vue
@@ -19,18 +19,18 @@
         :summary-method="summarizeMainTable" height="calc(100vh - 18.5em)">
         <el-table-column align="center" type="selection" width="55" />
         <el-table-column align="center" label="搴忓彿" type="index" width="60" />
-        <el-table-column label="鍏ュ簱鏃堕棿" prop="inboundTime" width="100" show-overflow-tooltip />
-        <el-table-column label="鍏ュ簱鎵规" prop="inboundBatch" width="160" show-overflow-tooltip />
+        <el-table-column label="鍏ュ簱鏃堕棿" prop="createTime" width="100" show-overflow-tooltip />
+        <el-table-column label="鍏ュ簱鎵规" prop="inboundBatches" width="160" show-overflow-tooltip />
         <el-table-column label="渚涘簲鍟嗗悕绉�" prop="supplierName" width="160" show-overflow-tooltip />
-        <el-table-column label="浜у搧澶х被" prop="productName" width="100" show-overflow-tooltip />
-        <el-table-column label="瑙勬牸鍨嬪彿" prop="model" width="160" show-overflow-tooltip />
+        <el-table-column label="浜у搧澶х被" prop="productCategory" width="100" show-overflow-tooltip />
+        <el-table-column label="瑙勬牸鍨嬪彿" prop="specificationModel" width="160" show-overflow-tooltip />
         <el-table-column label="鍗曚綅" prop="unit" width="70" show-overflow-tooltip />
-        <el-table-column label="鍏ュ簱鏁伴噺" prop="inboundQuantity" width="90" show-overflow-tooltip />
+        <el-table-column label="鍏ュ簱鏁伴噺" prop="inboundNum" width="90" show-overflow-tooltip />
         <el-table-column label="鍚◣鍗曚环" prop="taxInclusiveUnitPrice" width="100" show-overflow-tooltip />
         <el-table-column label="鍚◣鎬讳环" prop="taxInclusiveTotalPrice" width="100" show-overflow-tooltip />
         <el-table-column label="绋庣巼(%)" prop="taxRate" width="80" show-overflow-tooltip />
         <el-table-column label="涓嶅惈绋庢�讳环" prop="taxExclusiveTotalPrice" width="100" show-overflow-tooltip />
-        <el-table-column label="鍏ュ簱浜�" prop="nickName" width="80" show-overflow-tooltip />
+        <el-table-column label="鍏ュ簱浜�" prop="createBy" width="80" show-overflow-tooltip />
         <el-table-column fixed="right" label="鎿嶄綔" min-width="60" align="center">
           <template #default="scope">
             <el-button link type="primary" size="small" @click="openForm('edit', scope.row);">缂栬緫</el-button>
@@ -240,6 +240,7 @@
   const openForm = async (type, row) => {
     operationType.value = type
     dialogFormVisible.value = true
+    selectedRows.value = []
 
     if (type === 'add') {
       // 鏂板鏃跺垵濮嬪寲琛ㄥ崟
@@ -257,16 +258,22 @@
       }
       productList.value = [] // 娓呯┖浜у搧鍒楄〃
     } else {
+
       form.value = JSON.parse(JSON.stringify(row))
       try {
         loadingProducts.value = true
         // 鏍规嵁鍚堝悓鍙峰姞杞藉搴旂殑浜у搧鍒楄〃锛堝亣璁� getProductByContract 鏄彲鐢ㄦ帴鍙o級
-        const res = await getProductRecordByhetong(form.value.purchaseContractNumber)
+        const res = await selectProductRecordListByPuechaserId({
+          purchaseContractNumber: form.value.purchaseContractNumber,
+          id: row.id
+        });
         productList.value = res.data.map(item => ({
           ...item,
           quantityStock: item.quantityStock || 0 // 濡傛灉宸叉湁鍏ュ簱鏁伴噺鍒欎繚鐣�
         }))
+        selectedRows.value = productList.value
       } catch (error) {
+        console.error('鍔犺浇浜у搧澶辫触:', error)
         proxy.$modal.msgError('鍔犺浇浜у搧澶辫触')
         productList.value = []
       } finally {
@@ -275,18 +282,32 @@
     }
   }
 
+  const updatePro = async () => {
+    // 鍑嗗鎻愪氦鏁版嵁
+    // 鍑嗗鎻愪氦鏁版嵁 - 淇敼涓哄悗绔渶瑕佺殑鏍煎紡
+    const stockInData = {
+      id: selectedRows.value[0].recordId,
+      quantityStock: Number(selectedRows.value[0].quantityStock),// 浣跨敤鏂版牸寮忓寲鍑芥暟
+    };
+    await updateStockIn(stockInData)
+    proxy.$modal.msgSuccess('淇敼鍏ュ簱鎴愬姛')
+    closeDia()
+    getList() // 鍒锋柊鍒楄〃
+  }
 
 // 鎻愪氦琛ㄥ崟
   const submitForm = async () => {
+    // 楠岃瘉鑷冲皯閫夋嫨浜嗕竴涓骇鍝�
+    if (selectedRows.value.length === 0) {
+      proxy.$modal.msgError('璇峰厛鏌ヨ骞堕�夋嫨浜у搧')
+      return
+    }
+    if(operationType.value !== 'add'){
+      await updatePro()
+      return
+    }
     try {
       await proxy.$refs.formRef.validate()
-
-      // 楠岃瘉鑷冲皯閫夋嫨浜嗕竴涓骇鍝�
-      if (selectedRows.value.length === 0) {
-        proxy.$modal.msgError('璇峰厛鏌ヨ骞堕�夋嫨浜у搧')
-        return
-      }
-
       // 楠岃瘉鍏ュ簱鏁伴噺
       const invalidProducts = selectedRows.value.filter(
           product => product.quantityStock <= 0 || product.quantityStock > product.quantity0
@@ -380,7 +401,7 @@
           type: 'warning',
         }
     ).then(() => {
-      delStockIn(ids).then(res => {
+      delStockIn({ids:ids}).then(res => {
         proxy.$modal.msgSuccess("鍒犻櫎鎴愬姛")
         getList()
       })
diff --git a/src/views/inventoryManagement/stockManagement/index.vue b/src/views/inventoryManagement/stockManagement/index.vue
index b5181d2..6356d7a 100644
--- a/src/views/inventoryManagement/stockManagement/index.vue
+++ b/src/views/inventoryManagement/stockManagement/index.vue
@@ -19,18 +19,18 @@
         :summary-method="summarizeMainTable" height="calc(100vh - 18.5em)">
         <el-table-column align="center" type="selection" width="55" />
         <el-table-column align="center" label="搴忓彿" type="index" width="60" />
-        <el-table-column label="搴撳瓨鏃ユ湡" prop="boundTime" width="100" show-overflow-tooltip />
-        <el-table-column label="鍏ュ簱鏃ユ湡" prop="inboundTime" width="100" show-overflow-tooltip />
+        <el-table-column label="搴撳瓨鏃ユ湡" prop="createTime" width="100" show-overflow-tooltip />
+        <el-table-column label="鍏ュ簱鏃ユ湡" prop="createTime" width="100" show-overflow-tooltip />
         <el-table-column label="渚涘簲鍟嗗悕绉�" prop="supplierName" width="160" show-overflow-tooltip />
-        <el-table-column label="浜у搧澶х被" prop="productName" width="100" show-overflow-tooltip />
-        <el-table-column label="瑙勬牸鍨嬪彿" prop="model" width="100" show-overflow-tooltip />
+        <el-table-column label="浜у搧澶х被" prop="productCategory" width="100" show-overflow-tooltip />
+        <el-table-column label="瑙勬牸鍨嬪彿" prop="specificationModel" width="100" show-overflow-tooltip />
         <el-table-column label="鍗曚綅" prop="unit" width="80" show-overflow-tooltip />
-        <el-table-column label="鍑哄簱鏁伴噺" prop="stockQuantity" width="100" show-overflow-tooltip />
+        <el-table-column label="搴撳瓨鏁伴噺" prop="inboundNum0" width="100" show-overflow-tooltip />
         <el-table-column label="鍚◣鍗曚环" prop="taxInclusiveUnitPrice" width="100" show-overflow-tooltip />
         <el-table-column label="鍚◣鎬讳环" prop="taxInclusiveTotalPrice" width="100" show-overflow-tooltip />
         <el-table-column label="绋庣巼(%)" prop="taxRate" width="100" show-overflow-tooltip />
         <el-table-column label="涓嶅惈绋庢�讳环" prop="taxExclusiveTotalPrice" width="100" show-overflow-tooltip />
-        <el-table-column label="鍏ュ簱浜�" prop="nickName" width="80" show-overflow-tooltip />
+        <el-table-column label="鍏ュ簱浜�" prop="createBy" width="80" show-overflow-tooltip />
         <el-table-column fixed="right" label="鎿嶄綔" min-width="60" align="center">
           <template #default="scope">
             <el-button link type="primary" size="small" @click="openForm('edit', scope.row);">缂栬緫</el-button>
@@ -40,20 +40,20 @@
       <pagination v-show="total > 0" :total="total" layout="total, sizes, prev, pager, next, jumper"
         :page="page.current" :limit="page.size" @pagination="paginationChange" />
     </div>
-    <el-dialog v-model="dialogFormVisible" :title="operationType === 'add' ? '鏂板鍑哄簱' : '缂栬緫鍑哄簱'" width="70%"
+    <el-dialog v-model="dialogFormVisible" :title="operationType === 'add' ? '鏂板搴撳瓨' : '缂栬緫搴撳瓨'" width="70%"
       @close="closeDia">
       <el-form :model="form" label-width="140px" label-position="top" :rules="rules" ref="formRef">
         <el-row :gutter="30">
           <el-col :span="12">
             <el-form-item label="渚涘簲鍟嗗悕绉帮細" prop="supplierName">
-              <el-input v-model="form.supplierName" placeholder="璇疯緭鍏�" clearable />
+              <el-input disabled v-model="form.supplierName" placeholder="璇疯緭鍏�" clearable />
             </el-form-item>
           </el-col>
           <el-col :span="12">
             <el-form-item label="浜у搧澶х被锛�" prop="productId">
-              <el-select v-model="form.productId" placeholder="璇烽�夋嫨" clearable filterable @change="handleProductChange">
+              <el-select disabled v-model="form.productCategory" placeholder="璇烽�夋嫨" clearable filterable @change="handleProductChange">
                 <el-option v-for="item in productList" :key="item.id" :label="item.productName"
-                           :value="item.id" />
+                           :value="item.productName" />
               </el-select>
             </el-form-item>
           </el-col>
@@ -61,7 +61,7 @@
         <el-row :gutter="30">
           <el-col :span="12">
             <el-form-item label="瑙勬牸鍨嬪彿锛�" prop="productManageId">
-              <el-select v-model="form.productModelId" placeholder="璇峰厛閫夋嫨浜у搧澶х被" clearable filterable :disabled="!form.productId"
+              <el-select disabled v-model="form.specificationModel" placeholder="璇峰厛閫夋嫨浜у搧澶х被" clearable filterable :disabled="!form.productCategory"
                          @change="handleModelChange">
                 <el-option v-for="item in productModelList" :key="item.id" :label="item.model"
                            :value="item.id" />
@@ -69,21 +69,21 @@
             </el-form-item>
           </el-col>
           <el-col :span="12">
-            <el-form-item label="鍗曚綅锛�" prop="customerId">
-              <el-input v-model="form.unit" placeholder="璇疯緭鍏�" clearable />
+            <el-form-item  label="鍗曚綅锛�" prop="customerId">
+              <el-input disabled v-model="form.unit" placeholder="璇疯緭鍏�" clearable />
             </el-form-item>
           </el-col>
         </el-row>
         <el-row :gutter="30">
           <el-col :span="12">
             <el-form-item label="搴撳瓨鏃堕棿锛�" prop="projectName">
-              <el-date-picker style="width: 100%" v-model="form.boundTime" value-format="YYYY-MM-DD" format="YYYY-MM-DD"
+              <el-date-picker style="width: 100%" v-model="form.updateTime" value-format="YYYY-MM-DD" format="YYYY-MM-DD"
                 type="date" placeholder="璇烽�夋嫨" clearable />
             </el-form-item>
           </el-col>
           <el-col :span="12">
             <el-form-item label="鍏ュ簱鏃堕棿锛�" prop="projectName">
-              <el-date-picker style="width: 100%" v-model="form.inboundTime" value-format="YYYY-MM-DD" format="YYYY-MM-DD"
+              <el-date-picker style="width: 100%" v-model="form.createTime" value-format="YYYY-MM-DD" format="YYYY-MM-DD"
                 type="date" placeholder="璇烽�夋嫨" clearable />
             </el-form-item>
           </el-col>
@@ -91,26 +91,26 @@
         <el-row :gutter="30">
 
           <el-col :span="12">
-            <el-form-item label="鍚◣鍗曚环锛�" prop="customerId">
-              <el-input v-model="form.taxInclusiveUnitPrice" placeholder="璇疯緭鍏�" clearable />
+            <el-form-item  label="鍚◣鍗曚环锛�" prop="customerId">
+              <el-input disabled v-model="form.taxInclusiveUnitPrice" placeholder="璇疯緭鍏�" clearable />
             </el-form-item>
           </el-col>
           <el-col :span="12">
-            <el-form-item label="鍚◣鎬讳环锛�" prop="customerContractNo">
-              <el-input v-model="form.taxInclusiveTotalPrice" placeholder="璇疯緭鍏�" clearable />
+            <el-form-item  label="鍚◣鎬讳环锛�" prop="customerContractNo">
+              <el-input disabled v-model="form.taxInclusiveTotalPrice" placeholder="璇疯緭鍏�" clearable />
             </el-form-item>
           </el-col>
         </el-row>
         <el-row :gutter="30">
 
           <el-col :span="12">
-            <el-form-item label="绋庣巼锛�" prop="customerId">
-              <el-input v-model="form.taxRate" placeholder="璇疯緭鍏�" clearable />
+            <el-form-item  label="绋庣巼锛�" prop="customerId">
+              <el-input disabled v-model="form.taxRate" placeholder="璇疯緭鍏�" clearable />
             </el-form-item>
           </el-col>
           <el-col :span="12">
             <el-form-item label="涓嶅惈绋庢�讳环锛�" prop="entryDate">
-              <el-input v-model="form.taxExclusiveTotalPrice" placeholder="璇疯緭鍏�" clearable />
+              <el-input disabled v-model="form.taxExclusiveTotalPrice" placeholder="璇疯緭鍏�" clearable />
             </el-form-item>
           </el-col>
         </el-row>
@@ -118,7 +118,7 @@
 
           <el-col :span="12">
             <el-form-item label="鍑哄簱浜猴細" prop="entryPerson">
-              <el-select v-model="form.nickName" placeholder="璇烽�夋嫨" clearable>
+              <el-select v-model="form.createUser" placeholder="璇烽�夋嫨" clearable>
                 <el-option v-for="item in userList" :key="item.userId" :label="item.nickName" :value="item.userId" />
               </el-select>
             </el-form-item>
@@ -141,18 +141,24 @@
 import { ElMessageBox } from "element-plus";
 import useUserStore from '@/store/modules/user'
 import { userListNoPage } from "@/api/system/user.js";
+import { productTreeList,modelList } from "@/api/basicData/product.js"
 import {
   getStockManagePage ,
   updateStockManage,
   delStockManage,
   exportStockManage
 } from "@/api/inventoryManagement/stockManage.js";
+import {
+  updateManagement
+} from "@/api/inventoryManagement/stockIn.js";
 const userStore = useUserStore()
 const { proxy } = getCurrentInstance()
 const tableData = ref([])
 const productData = ref([])
 const selectedRows = ref([])
 const userList = ref([])
+const productList = ref([])
+const productModelList = ref([])
 // const customerOption = ref([])
 const tableLoading = ref(false)
 const page = reactive({
@@ -259,13 +265,25 @@
   // console.log('userStore.id', userStore.id)
   // form.value.entryPerson = userStore.id
   if (type === 'edit') {
-    currentId.value = row.id;
-    getSalesLedgerWithProducts({ id: row.id, type: 1 }).then(res => {
-      form.value = { ...res }
-      form.value.entryPerson = Number(res.entryPerson)
-      productData.value = form.value.productData
-      fileList.value = form.value.salesLedgerFiles
+    form.value = { ...row }
+    productTreeList().then(res =>{
+      productList.value = res
+      productList.value.forEach(i =>{
+        if (i.label === row.productCategory) {
+          modelList({ id: i.id }).then((res) => {
+            productModelList.value = res;
+          });
+        }
+      })
     })
+
+
+    // getSalesLedgerWithProducts({ id: row.id, type: 1 }).then(res => {
+
+    //   form.value.entryPerson = Number(res.entryPerson)
+    //   productData.value = form.value.productData
+    //   fileList.value = form.value.salesLedgerFiles
+    // })
   }
   form.value.entryDate = getCurrentDate() // 璁剧疆榛樿褰曞叆鏃ユ湡涓哄綋鍓嶆棩鏈�
   dialogFormVisible.value = true
@@ -273,21 +291,22 @@
 
 // 鎻愪氦琛ㄥ崟
 const submitForm = () => {
+  console.log(form.value)
   proxy.$refs["formRef"].validate(valid => {
     if (valid) {
-      if (productData.value.length > 0) {
-        form.value.productData = proxy.HaveJson(productData.value)
-      } else {
-        proxy.$modal.msgWarning('璇锋坊鍔犱骇鍝佷俊鎭�')
-        return
-      }
-      let tempFileIds = []
-      if (fileList.value.length > 0) {
-        tempFileIds = fileList.value.map(item => item.tempId)
-      }
-      form.value.tempFileIds = tempFileIds
-      form.value.type = 1
-      addOrUpdateSalesLedger(form.value).then(res => {
+      // if (productData.value.length > 0) {
+      //   form.value.productData = proxy.HaveJson(productData.value)
+      // } else {
+      //   proxy.$modal.msgWarning('璇锋坊鍔犱骇鍝佷俊鎭�')
+      //   return
+      // }
+      // let tempFileIds = []
+      // if (fileList.value.length > 0) {
+      //   tempFileIds = fileList.value.map(item => item.tempId)
+      // }
+      // form.value.tempFileIds = tempFileIds
+      // form.value.type = 1
+      updateManagement(form.value).then(res => {
         proxy.$modal.msgSuccess("鎻愪氦鎴愬姛")
         closeDia()
         getList()
@@ -311,7 +330,7 @@
     type: 'warning',
   }
   ).then(() => {
-    proxy.download("/stockmanagement/export", {}, '搴撳瓨淇℃伅.xlsx')
+    proxy.download("/stockin/exportCopy", {}, '搴撳瓨淇℃伅.xlsx')
   }).catch(() => {
     proxy.$modal.msg("宸插彇娑�")
   })
@@ -333,7 +352,7 @@
     type: 'warning',
   }
   ).then(() => {
-    delStockManage(ids).then(res => {
+    delStockManage({ids:ids}).then(res => {
       proxy.$modal.msgSuccess("鍒犻櫎鎴愬姛")
       getList()
     })
diff --git a/src/views/salesManagement/salesLedger/index.vue b/src/views/salesManagement/salesLedger/index.vue
index 893c02b..3ec809b 100644
--- a/src/views/salesManagement/salesLedger/index.vue
+++ b/src/views/salesManagement/salesLedger/index.vue
@@ -3,7 +3,7 @@
     <div class="search_form">
       <el-form :model="searchForm" :inline="true">
         <el-form-item label="瀹㈡埛鍚嶇О锛�">
-          <el-input v-model="searchForm.customerContractNo" placeholder="璇疯緭鍏�" clearable prefix-icon="Search"
+          <el-input v-model="searchForm.customerName" placeholder="璇疯緭鍏�" clearable prefix-icon="Search"
             @change="handleQuery" />
         </el-form-item>
         <el-form-item label="瀹㈡埛鍚堝悓鍙凤細">
diff --git a/vite.config.js b/vite.config.js
index 2f9c048..8d2eccb 100644
--- a/vite.config.js
+++ b/vite.config.js
@@ -8,7 +8,7 @@
   const { VITE_APP_ENV } = env;
   const baseUrl =
     VITE_APP_ENV == "development"
-      ? "http://127.0.0.1:7005" // 寮�鍙戠幆澧冨悗绔帴鍙�
+      ? "http://127.0.0.1:7003" // 寮�鍙戠幆澧冨悗绔帴鍙�
       : "http://114.132.189.42:7003"; // 鐢熶骇鐜鍚庣鎺ュ彛
 
   return {

--
Gitblit v1.9.3