03.하수관로 유지관리 tab1. 개보수 표준화 데이터 조회
This commit is contained in:
@@ -13,6 +13,8 @@ import { SewagePipeMaintainColumnInfoList } from "@/components/util/column/revie
|
||||
import type { ColumnInfoList, ColumnConfig } from "@/components/type/DataGrid.type";
|
||||
import type { SearchFormValues } from "@/components/type/SearchForm.type";
|
||||
import { toGridRows } from "@/components/util/grid/gridFunction";
|
||||
import type { SewerPipeMtcRequestParams } from "@/entities/statistics/model/statistics-sewage-pipe-mtc-review-interface";
|
||||
|
||||
|
||||
// 하수도 통계 검토 03. 하수관로 유지 관리
|
||||
const SewagePipeMaintainRvw = () => {
|
||||
@@ -21,7 +23,7 @@ const SewagePipeMaintainRvw = () => {
|
||||
const [isLoading, setIsLoading] = useState<boolean>(false);
|
||||
const [activeTab, setActiveTab] = useState<string>('ST00030001');
|
||||
|
||||
const searchParamRef = useRef<SearchFormValues | null>(null);
|
||||
const searchParamRef = useRef<SewerPipeMtcRequestParams | null>(null);
|
||||
|
||||
const columnInfo = useMemo(() => {
|
||||
return SewagePipeMaintainColumnInfoList.map((tab: ColumnInfoList) => ({
|
||||
@@ -52,12 +54,12 @@ const SewagePipeMaintainRvw = () => {
|
||||
try {
|
||||
setIsLoading(true);
|
||||
|
||||
const searchParam = {
|
||||
sido: values.sido,
|
||||
gugun: values.gugun === 'ALL' ? '' : values.gugun,
|
||||
bsnmCd: values.bsnmCd,
|
||||
yr: values.year,
|
||||
};
|
||||
const searchParam: SewerPipeMtcRequestParams = {
|
||||
statsYr: values.year,
|
||||
sewerBzmnCd: values.bsnmCd,
|
||||
ctpvNm: values.sido,
|
||||
sggNm: values.gugun === 'ALL' ? '' : values.gugun
|
||||
};
|
||||
|
||||
searchParamRef.current = searchParam;
|
||||
const response = await statisticsManagementApi.getSewerPipeMtcList(searchParam);
|
||||
@@ -99,7 +101,7 @@ const SewagePipeMaintainRvw = () => {
|
||||
if (tabKey === 'ST00030001') {
|
||||
response = await statisticsManagementApi.getSewerPipeMtcList(searchParamRef.current);
|
||||
}else if (tabKey === 'ST00030002') {
|
||||
response = await statisticsManagementApi.getSewerPipeDrdgList(searchParamRef.current);
|
||||
// response = await statisticsManagementApi.getSewerPipeDrdgList(searchParamRef.current);
|
||||
}
|
||||
|
||||
if (response?.status === 'success' && response.data) {
|
||||
|
||||
Reference in New Issue
Block a user