From efc0c3a697969503634138d7881543f4099b81ca Mon Sep 17 00:00:00 2001
From: yyb <995253665@qq.com>
Date: 星期三, 20 五月 2026 13:32:09 +0800
Subject: [PATCH] 审批模板导入只能从已有模板导入

---
 src/views/officeProcessAutomation/ReimburseManage/travel-reimburse/useTravelReimburse.js |   88 +------------------------------------------
 1 files changed, 3 insertions(+), 85 deletions(-)

diff --git a/src/views/officeProcessAutomation/ReimburseManage/travel-reimburse/useTravelReimburse.js b/src/views/officeProcessAutomation/ReimburseManage/travel-reimburse/useTravelReimburse.js
index 9125d64..847e54f 100644
--- a/src/views/officeProcessAutomation/ReimburseManage/travel-reimburse/useTravelReimburse.js
+++ b/src/views/officeProcessAutomation/ReimburseManage/travel-reimburse/useTravelReimburse.js
@@ -32,92 +32,10 @@
   return String(u.status) === "0";
 }
 
-function demoFlowNodes(names = ["閮ㄩ棬涓荤", "璐㈠姟瀹℃牳"]) {
-  return names.map((name, i) => ({
-    approverId: `mock_${i + 1}`,
-    approverName: name,
-    sortOrder: i + 1,
-    nodeOrder: i + 1,
-    nodeStatus: i === 0 ? "process" : "wait",
-    approveOpinion: "",
-    approveTime: "",
-  }));
-}
-
 export function useTravelReimburse() {
   const { proxy } = getCurrentInstance();
 
-  const allRows = ref([
-    {
-      id: "1",
-      reimburseNo: "TR202605090001",
-      applicantId: "mock_1",
-      employeeNo: "zhangsan",
-      employeeName: "寮犱笁",
-      applicantNo: "zhangsan",
-      applicantName: "寮犱笁",
-      reimburseReason: "璧翠笂娴峰弬鍔犺涓氬睍浼氬強瀹㈡埛鎷滆銆�",
-      travelStartTime: "2026-05-10 08:00:00",
-      travelEndTime: "2026-05-13 18:00:00",
-      travelDays: 4,
-      departurePlace: "鏉窞",
-      destination: "涓婃捣",
-      hotelStandard: 600,
-      hotelDays: 3,
-      livingSubsidy: 400,
-      applyAmount: 4580,
-      payee: "寮犱笁",
-      expenseDetails: [
-        { id: "d1", invoiceDate: "2026-05-10", expenseSubject: "transport", amount: 553, description: "楂橀搧寰�杩�" },
-        { id: "d2", invoiceDate: "2026-05-11", expenseSubject: "hotel", amount: 1680, description: "閰掑簵浣忓" },
-      ],
-      attachmentList: [{ name: "楂橀搧绁�.pdf", url: "/mock/invoice1.pdf" }],
-      invoiceAttachments: [{ name: "楂橀搧绁�.pdf", url: "/mock/invoice1.pdf" }],
-      approvalFlowNodes: demoFlowNodes(),
-      currentNodeIndex: 0,
-      approvalResult: "pending",
-      rejectReason: "",
-      approvalRecords: [],
-      needSpecialApproval: false,
-      deptId: "101",
-      deptName: "閿�鍞儴",
-      travelTier: "tier1",
-      createTime: "2026-05-09 10:20:00",
-    },
-    {
-      id: "2",
-      reimburseNo: "TR202605080002",
-      applicantId: "mock_2",
-      employeeNo: "lisi",
-      employeeName: "鏉庡洓",
-      applicantNo: "lisi",
-      applicantName: "鏉庡洓",
-      reimburseReason: "鎴愰兘鍒嗗叕鍙告妧鏈敮鎸併��",
-      travelStartTime: "2026-05-05 09:00:00",
-      travelEndTime: "2026-05-07 17:00:00",
-      travelDays: 3,
-      departurePlace: "姝︽眽",
-      destination: "鎴愰兘",
-      hotelStandard: 450,
-      hotelDays: 2,
-      livingSubsidy: 240,
-      applyAmount: 2100,
-      payee: "鏉庡洓",
-      expenseDetails: [{ id: "d3", invoiceDate: "2026-05-06", expenseSubject: "meal", amount: 180, description: "宸ヤ綔椁�" }],
-      attachmentList: [],
-      invoiceAttachments: [],
-      approvalFlowNodes: demoFlowNodes().map((n, i) => ({ ...n, nodeStatus: "finish", approveOpinion: "鍚屾剰", approveTime: "2026-05-08 11:00:00" })),
-      currentNodeIndex: 1,
-      approvalResult: "approved",
-      rejectReason: "",
-      approvalRecords: [{ operatorName: "閮ㄩ棬涓荤", result: "approved", opinion: "鍚屾剰", time: "2026-05-08 10:00:00" }],
-      needSpecialApproval: false,
-      deptId: "102",
-      deptName: "鎶�鏈儴",
-      travelTier: "tier2",
-      createTime: "2026-05-07 16:00:00",
-    },
-  ]);
+  const allRows = ref([]);
 
   const searchForm = reactive({ applicantKeyword: "", travelStartFrom: "", travelEndTo: "" });
   const tableLoading = ref(false);
@@ -534,7 +452,7 @@
         approvalRecords: [],
         createTime: dayjs().format("YYYY-MM-DD HH:mm:ss"),
       });
-      proxy?.$modal?.msgSuccess?.("鎻愪氦鎴愬姛锛屽凡杩涘叆瀹℃壒锛堟湰鍦版ā鎷燂級");
+      proxy?.$modal?.msgSuccess?.("鎻愪氦鎴愬姛");
     } else {
       const idx = allRows.value.findIndex((r) => r.id === form.id);
       if (idx !== -1) {
@@ -549,7 +467,7 @@
           createTime: prev.createTime,
         };
       }
-      proxy?.$modal?.msgSuccess?.("淇濆瓨鎴愬姛锛堟湰鍦版ā鎷燂級");
+      proxy?.$modal?.msgSuccess?.("淇濆瓨鎴愬姛");
     }
     formDialog.visible = false;
     handleQuery();

--
Gitblit v1.9.3