From dc5ad9f5e1c190f8c8380696793fdf182922b385 Mon Sep 17 00:00:00 2001 From: Timer <@> Date: Sat, 7 Mar 2026 21:22:59 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B5=8B=E9=87=8F=E7=82=B9=E4=BD=8D=E5=9C=BA?= =?UTF-8?q?=E5=86=85=E5=A4=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../controller/equipment/EquipmentCardController.java | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/src/main/java/com/sipai/controller/equipment/EquipmentCardController.java b/src/main/java/com/sipai/controller/equipment/EquipmentCardController.java index 4160c44c..dad93502 100644 --- a/src/main/java/com/sipai/controller/equipment/EquipmentCardController.java +++ b/src/main/java/com/sipai/controller/equipment/EquipmentCardController.java @@ -1894,7 +1894,12 @@ public class EquipmentCardController { //一些地方请求传参不一样 有pSectionId和processSectionId if (request.getParameter("pSectionId") != null && !request.getParameter("pSectionId").isEmpty()) { - List list = processSectionService.selectListByWhere("where code = '" + request.getParameter("pSectionId") + "' and unit_id = '" + request.getParameter("unitId") + "'"); + // 优先使用unitId,如果没有则使用companyId作为fallback + String unitIdParam = request.getParameter("unitId"); + if (unitIdParam == null || unitIdParam.isEmpty()) { + unitIdParam = request.getParameter("companyId"); + } + List list = processSectionService.selectListByWhere("where code = '" + request.getParameter("pSectionId") + "' and unit_id = '" + unitIdParam + "'"); if (list != null && list.size() > 0) { wherestr += " and processSectionId = '" + list.get(0).getId() + "' "; }