From 2d3530a7c11557a40807ad7c0b9e302ce6ce3a9f Mon Sep 17 00:00:00 2001
From: hsy <1029150275@qq.com>
Date: 星期五, 28 八月 2026 10:16:32 +0800
Subject: [PATCH] feat: 综合业务模块页面重构与交互完善
---
src/api/viewIndex.js | 21 +++++++++++++++++----
1 files changed, 17 insertions(+), 4 deletions(-)
diff --git a/src/api/viewIndex.js b/src/api/viewIndex.js
index 89f43b8..0087d66 100644
--- a/src/api/viewIndex.js
+++ b/src/api/viewIndex.js
@@ -347,22 +347,35 @@
});
};
-export const productionOrderProgress = (params) => {
+export const productionOrderProgress = (params = {}) => {
+ const safePageNum = Math.max(1, Number(params.pageNum || 1));
+ const safeTab = ["all", "inProgress", "completed", "end"].includes(params.tab)
+ ? params.tab
+ : "all";
return request({
url: "/home/productionOrderProgress",
method: "get",
- params,
+ params: {
+ ...params,
+ tab: safeTab,
+ pageNum: safePageNum,
+ pageSize: params.pageSize,
+ },
headers: {
handleAuthError: false,
},
});
};
-export const todayProductionPlan = (params) => {
+export const todayProductionPlan = (params = {}) => {
+ const safeLimit = Math.min(20, Math.max(1, Number(params.limit || 4)));
return request({
url: "/home/todayProductionPlan",
method: "get",
- params,
+ params: {
+ ...params,
+ limit: safeLimit,
+ },
headers: {
handleAuthError: false,
},
--
Gitblit v1.9.3