修复数据分析页面用户需求排名的积分统计错误
This commit is contained in:
parent
7781b0acd0
commit
1c3497692d
@ -132,8 +132,10 @@ public class AnalyticsService {
|
||||
.filter(t -> Arrays.asList("pending", "in_progress", "submitted").contains(t.getStatus()))
|
||||
.count();
|
||||
|
||||
// 计算消耗积分(使用Task::getScore,不是ScoreReward)
|
||||
BigDecimal totalScore = userTasks.stream()
|
||||
.map(Task::getScoreReward)
|
||||
.filter(t -> !"draft".equals(t.getStatus()) && !"rejected_by_demand".equals(t.getApprovalStatus()))
|
||||
.map(Task::getScore)
|
||||
.filter(Objects::nonNull)
|
||||
.reduce(BigDecimal.ZERO, BigDecimal::add);
|
||||
|
||||
|
||||
Binary file not shown.
Loading…
x
Reference in New Issue
Block a user