작업현황목록수정

This commit is contained in:
Moon
2026-01-05 17:51:23 +09:00
parent af87a452a3
commit 0ae9a55c91
6 changed files with 70 additions and 5 deletions

View File

@@ -131,9 +131,14 @@ public class LabelWorkerApiController {
@Parameter(description = "페이지 크기", example = "20") @RequestParam(defaultValue = "20")
int size) {
// 대상추출(최근)
UUID lstUuid = labelWorkService.findLastLabelWorkState();
String uuid = lstUuid.toString();
LabelWorkDto.WorkerStateSearchReq searchReq = new WorkerStateSearchReq();
searchReq.setUserRole(userRole);
searchReq.setSearchVal(searchVal);
searchReq.setUuid(uuid);
searchReq.setPage(page);
searchReq.setSize(size);
return ApiResponseDto.ok(labelWorkService.findlabelWorkStateList(searchReq));

View File

@@ -158,13 +158,13 @@ public class LabelWorkDto {
@Schema(description = "Skip개수")
private Long skipCnt;
@Schema(description = "Skip개수")
@Schema(description = "3일전처리개수")
private Long day3AgoDoneCnt;
@Schema(description = "Skip개수")
@Schema(description = "2일전처리개수")
private Long day2AgoDoneCnt;
@Schema(description = "Skip개수")
@Schema(description = "1일전처리개수")
private Long day1AgoDoneCnt;
public Long getremindCnt() {
@@ -172,10 +172,12 @@ public class LabelWorkDto {
}
public double getDoneRate() {
if (this.doneCnt == null || this.assignedCnt == 0) {
Long dayDoneCnt = this.day3AgoDoneCnt + this.day2AgoDoneCnt + this.day1AgoDoneCnt;
if (dayDoneCnt == null || dayDoneCnt == 0) {
return 0.0;
}
return (double) this.doneCnt / this.assignedCnt * 100.0;
return (double) dayDoneCnt / 3;
}
public String getUserRoleName() {

View File

@@ -55,4 +55,8 @@ public class LabelWorkService {
return labelWorkCoreService.findlabelWorkStateList(searchReq);
}
public UUID findLastLabelWorkState() {
return labelWorkCoreService.findLastLabelWorkState();
}
}