From 47bae1f938f915206e3934ea960aff975e5738c9 Mon Sep 17 00:00:00 2001
From: 云 <2163098428@qq.com>
Date: 星期五, 12 六月 2026 16:09:49 +0800
Subject: [PATCH] feat(teachingDemo): 新增工艺路线与BOM教学演示模块
---
src/views/officeProcessAutomation/ReimburseManage/cost-reimburse/useCostReimburse.js | 28 +++++++++++++++++++++-------
1 files changed, 21 insertions(+), 7 deletions(-)
diff --git a/src/views/officeProcessAutomation/ReimburseManage/cost-reimburse/useCostReimburse.js b/src/views/officeProcessAutomation/ReimburseManage/cost-reimburse/useCostReimburse.js
index 04b26ff..3b90a3b 100644
--- a/src/views/officeProcessAutomation/ReimburseManage/cost-reimburse/useCostReimburse.js
+++ b/src/views/officeProcessAutomation/ReimburseManage/cost-reimburse/useCostReimburse.js
@@ -12,8 +12,11 @@
import {
buildCostReimbursementSaveDto,
buildFinReimbursementListParams,
+ filterReimbursementRowsBySearch,
+ hasActiveReimbursementSearch,
canDeleteReimbursementRow,
canEditReimbursementRow,
+ enrichReimbursementListRowsWithApprovalFlow,
filterRowsByReimbursementType,
FIN_REIMBURSEMENT_TYPE,
mapCostReimbursementRow,
@@ -69,8 +72,6 @@
const searchForm = reactive({
applicantKeyword: "",
- applyTimeFrom: "",
- applyTimeTo: "",
});
const tableLoading = ref(false);
const page = reactive({ current: 1, size: 10, total: 0 });
@@ -106,11 +107,26 @@
})
);
const { records, total } = unwrapFinReimbursementPage(res);
- allRows.value = filterRowsByReimbursementType(
+ const filtered = filterRowsByReimbursementType(
records,
FIN_REIMBURSEMENT_TYPE.COST
- ).map(mapCostReimbursementRow);
- page.total = total;
+ );
+ let mapped = filtered.map(mapCostReimbursementRow);
+ mapped = await enrichReimbursementListRowsWithApprovalFlow(
+ mapped,
+ FIN_REIMBURSEMENT_TYPE.COST
+ );
+ if (hasActiveReimbursementSearch(searchForm)) {
+ mapped = filterReimbursementRowsBySearch(mapped, searchForm);
+ }
+ allRows.value = mapped;
+ const dropped = records.length - filtered.length;
+ let nextTotal =
+ dropped > 0 ? Math.max(0, Number(total) - dropped) : Number(total);
+ if (hasActiveReimbursementSearch(searchForm)) {
+ nextTotal = mapped.length;
+ }
+ page.total = nextTotal;
} catch {
allRows.value = [];
page.total = 0;
@@ -318,8 +334,6 @@
function resetSearch() {
searchForm.applicantKeyword = "";
- searchForm.applyTimeFrom = "";
- searchForm.applyTimeTo = "";
handleQuery();
}
--
Gitblit v1.9.3