Merge remote-tracking branch 'origin/feat/dev_251201' into feat/dev_251201
This commit is contained in:
@@ -151,18 +151,25 @@ public class LabelAllocateApiController {
|
||||
}
|
||||
|
||||
@Operation(
|
||||
summary = "작업현황 관리 > 라벨러 상세 정보, 작업이관 팝업 내 라벨러 상세 정보 동일",
|
||||
description = "작업현황 관리 > 라벨러 상세 정보, 작업이관 팝업 내 라벨러 상세 정보 동일")
|
||||
@GetMapping("/labeler-detail")
|
||||
public ApiResponseDto<LabelerDetail> findLabelerDetail(
|
||||
@RequestParam(defaultValue = "01022223333", required = true) String userId,
|
||||
@Parameter(
|
||||
description = "회차 마스터 key",
|
||||
required = true,
|
||||
example = "8584e8d4-53b3-4582-bde2-28a81495a626")
|
||||
@RequestParam
|
||||
String uuid) {
|
||||
return ApiResponseDto.ok(labelAllocateService.findLabelerDetail(userId, uuid));
|
||||
summary = "작업현황 관리 > 라벨러/검수자 상세 정보, 작업이관 팝업 내 라벨러 상세 정보 동일",
|
||||
description = "작업현황 관리 > 라벨러/검수자 상세 정보, 작업이관 팝업 내 라벨러 상세 정보 동일")
|
||||
@GetMapping("/user-detail")
|
||||
public ApiResponseDto<LabelerDetail> findUserDetail(
|
||||
@RequestParam(defaultValue = "01022223333", required = true) String userId,
|
||||
@Parameter(
|
||||
description = "회차 마스터 key",
|
||||
required = true,
|
||||
example = "8584e8d4-53b3-4582-bde2-28a81495a626")
|
||||
@RequestParam
|
||||
String uuid,
|
||||
@Schema(
|
||||
allowableValues = {"LABELER", "REVIEWER"},
|
||||
defaultValue = "LABELER")
|
||||
@Parameter(
|
||||
description = "라벨러/검수자(LABELER/REVIEWER)",
|
||||
required = true) @RequestParam String type
|
||||
) {
|
||||
return ApiResponseDto.ok(labelAllocateService.findUserDetail(userId, uuid, type));
|
||||
}
|
||||
|
||||
@Operation(summary = "작업현황 관리 > 상세 > 작업 이관", description = "작업현황 관리 > 상세 > 작업 이관")
|
||||
@@ -199,4 +206,33 @@ public class LabelAllocateApiController {
|
||||
dto.getCompareYyyy(),
|
||||
dto.getTargetYyyy()));
|
||||
}
|
||||
|
||||
@Operation(
|
||||
summary = "라벨링작업 관리 > 상세 > 라벨러/검수자 일별 작업량 목록",
|
||||
description = "라벨링작업 관리 > 상세 > 라벨러/검수자 일별 작업량 목록")
|
||||
@GetMapping("/daily-list")
|
||||
public ApiResponseDto<Page<LabelingStatDto>> findDaliyList(
|
||||
@RequestParam(defaultValue = "0", required = true) int page,
|
||||
@RequestParam(defaultValue = "20", required = true) int size,
|
||||
@Parameter(
|
||||
description = "회차 마스터 key",
|
||||
required = true,
|
||||
example = "8584e8d4-53b3-4582-bde2-28a81495a626")
|
||||
@RequestParam
|
||||
String uuid,
|
||||
@Parameter(
|
||||
description = "사번",
|
||||
required = true,
|
||||
example = "123456")
|
||||
@RequestParam String userId,
|
||||
@Schema(
|
||||
allowableValues = {"LABELER", "REVIEWER"},
|
||||
defaultValue = "LABELER")
|
||||
@Parameter(
|
||||
description = "라벨러/검수자(LABELER/REVIEWER)",
|
||||
required = true) @RequestParam String type
|
||||
) {
|
||||
LabelAllocateDto.searchReq searchReq = new LabelAllocateDto.searchReq(page, size, "");
|
||||
return ApiResponseDto.ok(labelAllocateService.findDaliyList(searchReq, uuid, userId, type));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -8,7 +8,11 @@ import java.util.List;
|
||||
import java.util.UUID;
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Getter;
|
||||
import lombok.NoArgsConstructor;
|
||||
import lombok.Setter;
|
||||
import org.springframework.data.domain.PageRequest;
|
||||
import org.springframework.data.domain.Pageable;
|
||||
import org.springframework.data.domain.Sort;
|
||||
|
||||
public class LabelAllocateDto {
|
||||
|
||||
@@ -97,9 +101,9 @@ public class LabelAllocateDto {
|
||||
private Integer stage;
|
||||
|
||||
@Schema(
|
||||
description = "라벨러 할당 목록",
|
||||
example =
|
||||
"""
|
||||
description = "라벨러 할당 목록",
|
||||
example =
|
||||
"""
|
||||
[
|
||||
{
|
||||
"userId": "123456",
|
||||
@@ -118,9 +122,9 @@ public class LabelAllocateDto {
|
||||
private List<TargetUser> labelers;
|
||||
|
||||
@Schema(
|
||||
description = "검수자 할당 목록",
|
||||
example =
|
||||
"""
|
||||
description = "검수자 할당 목록",
|
||||
example =
|
||||
"""
|
||||
["K20251216001",
|
||||
"01022225555",
|
||||
"K20251212001"
|
||||
@@ -171,6 +175,9 @@ public class LabelAllocateDto {
|
||||
private Long analUid;
|
||||
private ZonedDateTime createdDttm;
|
||||
private ZonedDateTime updatedDttm;
|
||||
private String inspectState;
|
||||
private ZonedDateTime workStatDttm;
|
||||
private ZonedDateTime inspectStatDttm;
|
||||
}
|
||||
|
||||
@Getter
|
||||
@@ -210,7 +217,7 @@ public class LabelAllocateDto {
|
||||
private Double percent;
|
||||
private Integer ranking;
|
||||
private ZonedDateTime createdDttm;
|
||||
private String inspectorName;
|
||||
private String ownerName;
|
||||
}
|
||||
|
||||
@Getter
|
||||
@@ -225,9 +232,9 @@ public class LabelAllocateDto {
|
||||
private Integer stage;
|
||||
|
||||
@Schema(
|
||||
description = "라벨러 할당 목록",
|
||||
example =
|
||||
"""
|
||||
description = "라벨러 할당 목록",
|
||||
example =
|
||||
"""
|
||||
[
|
||||
{
|
||||
"userId": "123456",
|
||||
@@ -256,4 +263,43 @@ public class LabelAllocateDto {
|
||||
private Long geoUid;
|
||||
private Long mapSheetNum;
|
||||
}
|
||||
|
||||
@Getter
|
||||
@Setter
|
||||
@AllArgsConstructor
|
||||
public static class LabelingStatDto {
|
||||
|
||||
private String workDate;
|
||||
private Long dailyTotalCnt;
|
||||
private Long totalCnt;
|
||||
private Long assignedCnt;
|
||||
private Long skipCnt;
|
||||
private Long completeCnt;
|
||||
private Long remainCnt;
|
||||
}
|
||||
|
||||
@Schema(name = "searchReq", description = "일자별 작업 목록 요청")
|
||||
@Getter
|
||||
@Setter
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
public static class searchReq {
|
||||
|
||||
// 페이징 파라미터
|
||||
private int page = 0;
|
||||
private int size = 20;
|
||||
private String sort;
|
||||
|
||||
public Pageable toPageable() {
|
||||
if (sort != null && !sort.isEmpty()) {
|
||||
String[] sortParams = sort.split(",");
|
||||
String property = sortParams[0];
|
||||
Sort.Direction direction =
|
||||
sortParams.length > 1 ? Sort.Direction.fromString(sortParams[1]) : Sort.Direction.ASC;
|
||||
return PageRequest.of(page, size, Sort.by(direction, property));
|
||||
}
|
||||
return PageRequest.of(page, size);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -6,6 +6,7 @@ import com.kamco.cd.kamcoback.label.dto.LabelAllocateDto;
|
||||
import com.kamco.cd.kamcoback.label.dto.LabelAllocateDto.AllocateInfoDto;
|
||||
import com.kamco.cd.kamcoback.label.dto.LabelAllocateDto.InferenceDetail;
|
||||
import com.kamco.cd.kamcoback.label.dto.LabelAllocateDto.LabelerDetail;
|
||||
import com.kamco.cd.kamcoback.label.dto.LabelAllocateDto.LabelingStatDto;
|
||||
import com.kamco.cd.kamcoback.label.dto.LabelAllocateDto.TargetUser;
|
||||
import com.kamco.cd.kamcoback.label.dto.LabelAllocateDto.UserList;
|
||||
import com.kamco.cd.kamcoback.label.dto.WorkerStatsDto.DailyHistory;
|
||||
@@ -16,6 +17,7 @@ import java.time.LocalDate;
|
||||
import java.util.List;
|
||||
import java.util.Objects;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.data.domain.Page;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
@@ -218,7 +220,19 @@ public class LabelAllocateService {
|
||||
return new ApiResponseDto.ResponseObj(ApiResponseCode.OK, "이관을 완료하였습니다.");
|
||||
}
|
||||
|
||||
public LabelerDetail findLabelerDetail(String userId, String uuid) {
|
||||
return labelAllocateCoreService.findLabelerDetail(userId, uuid);
|
||||
public LabelerDetail findUserDetail(String userId, String uuid, String type) {
|
||||
if (type.equals("LABELER")) {
|
||||
return labelAllocateCoreService.findLabelerDetail(userId, uuid);
|
||||
} else {
|
||||
return labelAllocateCoreService.findInspectorDetail(userId, uuid);
|
||||
}
|
||||
}
|
||||
|
||||
public Page<LabelingStatDto> findDaliyList(LabelAllocateDto.searchReq searchReq, String uuid, String userId, String type) {
|
||||
if (type.equals("LABELER")) {
|
||||
return labelAllocateCoreService.findLabelerDailyStat(searchReq, uuid, userId);
|
||||
} else {
|
||||
return labelAllocateCoreService.findInspectorDailyStat(searchReq, uuid, userId);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user