st: feat: 로그 조회, 입력-하수관로 조회, 입력-하수도보급률 예외 제출
This commit is contained in:
@@ -0,0 +1,94 @@
|
||||
import { ENDPOINT } from "@/shared/config";
|
||||
import { stClient } from "@/shared/api/client";
|
||||
import type {
|
||||
SeweragePipeFacilityAdminAreaListRequest,
|
||||
SeweragePipeFacilityAdminAreaListResponse,
|
||||
SeweragePipeFacilitiesListRequest,
|
||||
SeweragePipeFacilitiesListResponse,
|
||||
SeweragePipeInputConnectionStatusResponse,
|
||||
SeweragePipeInputFactInstallResponse,
|
||||
SeweragePipeInputManholeResponse,
|
||||
SeweragePipeInputPipeDiameterResponse,
|
||||
SeweragePipeInputPipeTypeResponse,
|
||||
SeweragePipeInputRegionalFactStatusSaveRequest,
|
||||
SeweragePipeInputRegionalFactStatusSaveApiResponse,
|
||||
SeweragePipeInputRegionalResponse,
|
||||
SeweragePipeRequestParams,
|
||||
StatisticsInputSewPipeService,
|
||||
} from "../../model/input/statistics-sewage-pipe-input-interface";
|
||||
|
||||
export class StatisticsInputSewPipeApiService implements StatisticsInputSewPipeService {
|
||||
public async getRegionalFactStatus(param: SeweragePipeRequestParams): Promise<SeweragePipeInputRegionalResponse> {
|
||||
const response = await stClient.get<SeweragePipeInputRegionalResponse> (
|
||||
`${ENDPOINT.ST_SERVICE.INPUT}/sewage-pipe/regional-facility-status`,
|
||||
{ params: param },
|
||||
);
|
||||
return response.data;
|
||||
}
|
||||
|
||||
public async getFactInstallStatus(param: SeweragePipeRequestParams): Promise<SeweragePipeInputFactInstallResponse> {
|
||||
const response = await stClient.get<SeweragePipeInputFactInstallResponse> (
|
||||
`${ENDPOINT.ST_SERVICE.INPUT}/sewage-pipe/facility-install-status`,
|
||||
{ params: param },
|
||||
);
|
||||
return response.data;
|
||||
}
|
||||
|
||||
public async getPipeTypeStatus(param: SeweragePipeRequestParams): Promise<SeweragePipeInputPipeTypeResponse> {
|
||||
const response = await stClient.get<SeweragePipeInputPipeTypeResponse> (
|
||||
`${ENDPOINT.ST_SERVICE.INPUT}/sewage-pipe/pipe-type-status`,
|
||||
{ params: param },
|
||||
);
|
||||
return response.data;
|
||||
}
|
||||
|
||||
public async getPipeDiameterStatus(param: SeweragePipeRequestParams): Promise<SeweragePipeInputPipeDiameterResponse> {
|
||||
const response = await stClient.get<SeweragePipeInputPipeDiameterResponse>(
|
||||
`${ENDPOINT.ST_SERVICE.INPUT}/sewage-pipe/pipe-diameter-status`,
|
||||
{ params: param },
|
||||
);
|
||||
return response.data;
|
||||
}
|
||||
|
||||
public async getManholeStatus(param: SeweragePipeRequestParams): Promise<SeweragePipeInputManholeResponse> {
|
||||
const response = await stClient.get<SeweragePipeInputManholeResponse>(
|
||||
`${ENDPOINT.ST_SERVICE.INPUT}/sewage-pipe/manhole-status`,
|
||||
{ params: param },
|
||||
);
|
||||
return response.data;
|
||||
}
|
||||
|
||||
public async getConnectionStatus(param: SeweragePipeRequestParams): Promise<SeweragePipeInputConnectionStatusResponse> {
|
||||
const response = await stClient.get<SeweragePipeInputConnectionStatusResponse>(
|
||||
`${ENDPOINT.ST_SERVICE.INPUT}/sewage-pipe/facility-connection-status`,
|
||||
{ params: param },
|
||||
);
|
||||
return response.data;
|
||||
}
|
||||
|
||||
public async getFacilitiesList(param: SeweragePipeFacilitiesListRequest): Promise<SeweragePipeFacilitiesListResponse> {
|
||||
const response = await stClient.get<SeweragePipeFacilitiesListResponse>(
|
||||
`${ENDPOINT.ST_SERVICE.INPUT}/sewage-pipe/facility-connection-status/popup/facilities`,
|
||||
{ params: param },
|
||||
);
|
||||
return response.data;
|
||||
}
|
||||
|
||||
public async getFacilityAdminAreaList(param: SeweragePipeFacilityAdminAreaListRequest): Promise<SeweragePipeFacilityAdminAreaListResponse> {
|
||||
const response = await stClient.get<SeweragePipeFacilityAdminAreaListResponse>(
|
||||
`${ENDPOINT.ST_SERVICE.INPUT}/sewage-pipe/facility-connection-status/popup/areas`,
|
||||
{ params: param },
|
||||
);
|
||||
return response.data;
|
||||
}
|
||||
|
||||
public async saveRegionalFactStatus(param: SeweragePipeInputRegionalFactStatusSaveRequest): Promise<SeweragePipeInputRegionalFactStatusSaveApiResponse> {
|
||||
const response = await stClient.post<SeweragePipeInputRegionalFactStatusSaveApiResponse>(
|
||||
`${ENDPOINT.ST_SERVICE.INPUT}/sewage-pipe/regional-facility-status/save`,
|
||||
param,
|
||||
);
|
||||
return response.data;
|
||||
}
|
||||
};
|
||||
|
||||
export const statisticsInputSewPipeApiService = new StatisticsInputSewPipeApiService();
|
||||
Reference in New Issue
Block a user