From 681e1dcc9afbd567fff332a55774bd712001c27e Mon Sep 17 00:00:00 2001 From: Your Name Date: Wed, 7 Jan 2026 19:37:09 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E5=A4=8D=E7=BC=96=E8=AF=91?= =?UTF-8?q?=E9=94=99=E8=AF=AF=20-=20=E6=B7=BB=E5=8A=A0UserMapper=E6=B3=A8?= =?UTF-8?q?=E5=85=A5=EF=BC=8C=E4=BF=AE=E5=A4=8D=E5=AD=97=E6=AE=B5=E5=90=8D?= =?UTF-8?q?getTotalScore?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../main/java/com/designhub/service/TaskItemService.java | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) diff --git a/backend/src/main/java/com/designhub/service/TaskItemService.java b/backend/src/main/java/com/designhub/service/TaskItemService.java index 117e30f..58771f5 100644 --- a/backend/src/main/java/com/designhub/service/TaskItemService.java +++ b/backend/src/main/java/com/designhub/service/TaskItemService.java @@ -41,6 +41,7 @@ public class TaskItemService { private final ExternalAssetService externalAssetService; private final SystemConfigService systemConfigService; private final DemandTypeMapper demandTypeMapper; + private final com.designhub.mapper.UserMapper userMapper; /** * 获取可接单的子任务列表 @@ -1107,7 +1108,7 @@ public class TaskItemService { } // 计算子任务组总积分 - groupInfo.put("totalScore", item.getScore() != null ? item.getScore() : 0); + groupInfo.put("totalScore", item.getTotalScore() != null ? item.getTotalScore() : 0); // 获取前置子任务的素材下载链接(流水线继承) if (item.getGroupNo() != null && item.getGroupNo() > 1) { @@ -1136,7 +1137,7 @@ public class TaskItemService { itemInfo.put("id", item.getId()); itemInfo.put("itemNo", item.getItemNo()); itemInfo.put("taskTypeId", item.getTaskTypeId()); - itemInfo.put("score", item.getScore()); + itemInfo.put("score", item.getTotalScore()); itemsList.add(itemInfo); groupInfo.put("items", itemsList); @@ -1146,7 +1147,7 @@ public class TaskItemService { groupInfo.put("itemCount", (Integer) groupInfo.get("itemCount") + 1); // 累加积分 Integer currentScore = (Integer) groupInfo.get("totalScore"); - Integer itemScore = item.getScore() != null ? item.getScore() : 0; + Integer itemScore = item.getTotalScore() != null ? item.getTotalScore() : 0; groupInfo.put("totalScore", currentScore + itemScore); // 添加到子任务列表 @@ -1156,7 +1157,7 @@ public class TaskItemService { itemInfo.put("id", item.getId()); itemInfo.put("itemNo", item.getItemNo()); itemInfo.put("taskTypeId", item.getTaskTypeId()); - itemInfo.put("score", item.getScore()); + itemInfo.put("score", item.getTotalScore()); itemsList.add(itemInfo); } }