Erweiterungen
This commit is contained in:
@@ -5,6 +5,7 @@ import de.assecutor.votianlt.model.JobStatus;
|
||||
import de.assecutor.votianlt.repository.JobRepository;
|
||||
import de.assecutor.votianlt.repository.TaskRepository;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
@@ -133,7 +134,7 @@ public class JobStatisticsService {
|
||||
for (Job job : yearJobs) {
|
||||
if (job.getCreatedAt() != null) {
|
||||
Month month = job.getCreatedAt().getMonth();
|
||||
monthlyCounts.merge(month, 1L, Long::sum);
|
||||
monthlyCounts.computeIfPresent(month, (k, v) -> v + 1L);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user