[st] feat: 통계 검증 리포트 목록 조회 API 수정
This commit is contained in:
@@ -2,6 +2,8 @@ import { stClient } from "@/shared/api";
|
||||
import { ENDPOINT } from "@/shared/config";
|
||||
|
||||
import type {
|
||||
ReportSearchRequestDto,
|
||||
ReportStatusListApiResponse,
|
||||
StatisticsInputStatusService,
|
||||
StatsInputStatusListApiResponse,
|
||||
StatsInputStatusListRequestParams,
|
||||
@@ -17,6 +19,16 @@ export class StatisticsInputStatusApiService implements StatisticsInputStatusSer
|
||||
);
|
||||
return response.data;
|
||||
}
|
||||
|
||||
public async getStatsValidationReport(
|
||||
request: ReportSearchRequestDto,
|
||||
): Promise<ReportStatusListApiResponse> {
|
||||
const response = await stClient.get<ReportStatusListApiResponse>(
|
||||
`${ENDPOINT.ST_SERVICE.INPUT}/stats-input-status/validation-report`,
|
||||
{ params: request },
|
||||
);
|
||||
return response.data;
|
||||
}
|
||||
}
|
||||
|
||||
export const StatisticsInputStatusApi = new StatisticsInputStatusApiService();
|
||||
|
||||
@@ -122,18 +122,24 @@ export const useStatsVrfcRptData = (
|
||||
return useQuery({
|
||||
queryKey: [
|
||||
ENDPOINT.ST_SERVICE.INPUT,
|
||||
"statistics-input-status",
|
||||
"validation-report",
|
||||
submittedMainFilters?.statsYr ?? "",
|
||||
submittedMainFilters?.ctpvNm ?? "",
|
||||
submittedMainFilters?.sggNm ?? "",
|
||||
submittedMainFilters?.sewerBzmnCd ?? "",
|
||||
submittedMainFilters?.statsCd ?? "",
|
||||
submittedMainFilters?.pbcpSbmsnSttsCd ?? "",
|
||||
],
|
||||
queryFn: async () => {
|
||||
if (!submittedMainFilters) return [];
|
||||
const {
|
||||
ctpvSewerBzmnCd: _ctpvSewerBzmnCd,
|
||||
sggSewerBzmnCd: _sggSewerBzmnCd,
|
||||
...request
|
||||
} = submittedMainFilters;
|
||||
const response =
|
||||
await StatisticsInputStatusApi.getStatisticsInputStatusList(
|
||||
submittedMainFilters,
|
||||
await StatisticsInputStatusApi.getStatsValidationReport(
|
||||
request,
|
||||
);
|
||||
if (response.status !== "success")
|
||||
throw new Error(response.message);
|
||||
|
||||
@@ -76,7 +76,11 @@ export {
|
||||
type ImrLogResponse,
|
||||
} from "./model/imr/imr-interface";
|
||||
export { imrVerificationHistoryColumns } from "./model/imr/imr-verification-history-columns";
|
||||
export { type StatsInputStatusList } from "./model/input/statistics-input-status-interface";
|
||||
export {
|
||||
type ReportSearchRequestDto,
|
||||
type ReportStatusResponseDto,
|
||||
type StatsInputStatusList,
|
||||
} from "./model/input/statistics-input-status-interface";
|
||||
export { userListColumns } from "./model/notice-talk/notice-talk-sending-columns";
|
||||
export {
|
||||
type BusinessSendRequest,
|
||||
|
||||
@@ -33,8 +33,63 @@ export type StatsInputStatusListApiResponse = ApiResponse<
|
||||
message: string;
|
||||
};
|
||||
|
||||
/** 통계 검증 리포트 RequestDto */
|
||||
export interface ReportSearchRequestDto {
|
||||
sewerBzmnCd?: string | null;
|
||||
ctpvNm?: string | null;
|
||||
sggNm?: string | null;
|
||||
statsYr: string;
|
||||
statsCd?: string | null;
|
||||
/** 공단 상태 코드 (0:미작성, 1:작성중, 2:제출, 3:승인, 4:반려, 5:검토중) */
|
||||
pbcpSbmsnSttsCd?: string | null;
|
||||
}
|
||||
|
||||
/** 통계 검증 리포트 현황 조회 ResponseDto */
|
||||
export interface ReportStatusResponseDto {
|
||||
ctpvNm?: string;
|
||||
sggNm?: string;
|
||||
sewerBzmnCd?: string;
|
||||
statsCd?: string;
|
||||
menuTabName?: string;
|
||||
laeSbmsnSttsCd?: string;
|
||||
laeSbmsnSttsNm?: string;
|
||||
laeSbmsnYmd?: string;
|
||||
statPicSbmsnSttsCd?: string;
|
||||
statPicSbmsnSttsNm?: string;
|
||||
ctpvSbmsnYmd?: string;
|
||||
pbcpSbmsnSttsCd?: string;
|
||||
pbcpSbmsnSttsNm?: string;
|
||||
pbcpCfmtnYmd?: string;
|
||||
laePicNm?: string;
|
||||
laePicTelNo?: string;
|
||||
laeKbrdrDeptNm?: string;
|
||||
laeKbrdrJbgdNm?: string;
|
||||
laeIdfrNm?: string;
|
||||
laeIdfrTelNo?: string;
|
||||
laeIdfrDeptNm?: string;
|
||||
laeIdfrJbgdNm?: string;
|
||||
mctpvIdfrNm?: string;
|
||||
mctpvIdfrTelNo?: string;
|
||||
mctpvIdfrDeptNm?: string;
|
||||
mctpvIdfrJbgdNm?: string;
|
||||
lastCfmtnPicNm?: string;
|
||||
lastCfmtnPicTelNo?: string;
|
||||
lastCfmtnPicDeptNm?: string;
|
||||
lastCfmtnPicJbgdNm?: string;
|
||||
rjctOpnnCn?: string;
|
||||
}
|
||||
|
||||
export type ReportStatusListApiResponse = ApiResponse<
|
||||
ReportStatusResponseDto[]
|
||||
> & {
|
||||
message: string;
|
||||
};
|
||||
|
||||
export interface StatisticsInputStatusService {
|
||||
getStatisticsInputStatusList(
|
||||
param: StatsInputStatusListRequestParams,
|
||||
): Promise<StatsInputStatusListApiResponse>;
|
||||
getStatsValidationReport(
|
||||
request: ReportSearchRequestDto,
|
||||
): Promise<ReportStatusListApiResponse>;
|
||||
}
|
||||
|
||||
+27
-3
@@ -29,14 +29,14 @@ export const statisticsVerificationReportColumnInfo: ColumnInfo = {
|
||||
{
|
||||
name: "laePicNm",
|
||||
fieldName: "laePicNm",
|
||||
header: { text: "작성자" },
|
||||
header: { text: "지자체작성자" },
|
||||
styleName: READ_ONLY_STYLE,
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "laePicTelNo",
|
||||
fieldName: "laePicTelNo",
|
||||
header: { text: "작성자연락처" },
|
||||
header: { text: "연락처" },
|
||||
width: 130,
|
||||
styleName: READ_ONLY_STYLE,
|
||||
editable: false,
|
||||
@@ -58,7 +58,7 @@ export const statisticsVerificationReportColumnInfo: ColumnInfo = {
|
||||
{
|
||||
name: "laeIdfrNm",
|
||||
fieldName: "laeIdfrNm",
|
||||
header: { text: "승인자" },
|
||||
header: { text: "지자체승인자" },
|
||||
styleName: READ_ONLY_STYLE,
|
||||
editable: false,
|
||||
},
|
||||
@@ -76,6 +76,27 @@ export const statisticsVerificationReportColumnInfo: ColumnInfo = {
|
||||
styleName: READ_ONLY_STYLE,
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "lastCfmtnPicNm",
|
||||
fieldName: "lastCfmtnPicNm",
|
||||
header: { text: "공단확인자" },
|
||||
styleName: READ_ONLY_STYLE,
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "lastCfmtnPicDeptNm",
|
||||
fieldName: "lastCfmtnPicDeptNm",
|
||||
header: { text: "부서" },
|
||||
styleName: READ_ONLY_STYLE,
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "lastCfmtnPicJbgdNm",
|
||||
fieldName: "lastCfmtnPicJbgdNm",
|
||||
header: { text: "직급" },
|
||||
styleName: READ_ONLY_STYLE,
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "rjctOpnnCn",
|
||||
fieldName: "rjctOpnnCn",
|
||||
@@ -108,6 +129,9 @@ export const statisticsVerificationReportColumnInfo: ColumnInfo = {
|
||||
"laeIdfrNm",
|
||||
"laeIdfrDeptNm",
|
||||
"laeIdfrJbgdNm",
|
||||
"lastCfmtnPicNm",
|
||||
"lastCfmtnPicDeptNm",
|
||||
"lastCfmtnPicJbgdNm",
|
||||
"rjctOpnnCn",
|
||||
"sewerBzmnCd",
|
||||
"statsCd",
|
||||
|
||||
+6
-7
@@ -1,12 +1,11 @@
|
||||
import type { VerifyResultSearchRequest } from "../general-verification-interface";
|
||||
import type { StatsInputStatusListRequestParams } from "../input/statistics-input-status-interface";
|
||||
import type { ReportSearchRequestDto } from "../input/statistics-input-status-interface";
|
||||
|
||||
export type StatisticsVerificationFilterState =
|
||||
StatsInputStatusListRequestParams & {
|
||||
// 셀렉트 표시용 시도, 시군구 코드
|
||||
ctpvSewerBzmnCd?: string | null;
|
||||
sggSewerBzmnCd?: string | null;
|
||||
};
|
||||
export type StatisticsVerificationFilterState = ReportSearchRequestDto & {
|
||||
// 셀렉트 표시용 시도, 시군구 코드
|
||||
ctpvSewerBzmnCd?: string | null;
|
||||
sggSewerBzmnCd?: string | null;
|
||||
};
|
||||
|
||||
export type StatisticsVerificationSubFilterState = VerifyResultSearchRequest;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user