st: fix: 로그 조회, Grid cell style 수정, 입력,검토,집계표 작업중
This commit is contained in:
@@ -44,6 +44,21 @@
|
||||
.rg-grid .rg-body .rg-table .rg-data-row .rg-data-cell.rg-cell-rowtype-other {
|
||||
@apply !bg-[#fff7bf];
|
||||
}
|
||||
/* fixedColumns 영역은 rg-table/rg-data-row 구조가 다를 수 있어 별도 커버 */
|
||||
.rg-grid .rg-body .rg-data-cell.rg-cell-rowtype-biz-sum {
|
||||
@apply !bg-[#ffe9cf];
|
||||
}
|
||||
.rg-grid .rg-body .rg-data-cell.rg-cell-rowtype-other {
|
||||
@apply !bg-[#fff7bf];
|
||||
}
|
||||
.rg-grid .rg-fixed-body .rg-table .rg-data-row td.rg-cell-rowtype-biz-sum,
|
||||
.rg-grid .rg-fixed-body .rg-data-row .rg-data-cell.rg-cell-rowtype-biz-sum {
|
||||
@apply !bg-[#ffe9cf];
|
||||
}
|
||||
.rg-grid .rg-fixed-body .rg-table .rg-data-row td.rg-cell-rowtype-other,
|
||||
.rg-grid .rg-fixed-body .rg-data-row .rg-data-cell.rg-cell-rowtype-other {
|
||||
@apply !bg-[#fff7bf];
|
||||
}
|
||||
|
||||
/* 진행상황: 소프트 인라인 요약 (툴바와 자연스럽게 blend) */
|
||||
.data-grid-status-bubble {
|
||||
@@ -108,4 +123,19 @@
|
||||
|
||||
.tabs-content {
|
||||
margin-top: 0.6rem !important;
|
||||
}
|
||||
|
||||
/*
|
||||
* RealGrid 기본 스타일(.rg-alternate-row { background: #fafafa })은 @layer 밖이라
|
||||
* @layer components 규칙만으로는 tr 배경이 남을 수 있음.
|
||||
* 스크롤 바디(.rg-body)만 흰색으로 통일 — 고정 영역(.rg-fixed-body)은 건드리지 않음.
|
||||
*/
|
||||
.rg-grid .rg-body .rg-table tr.rg-alternate-row {
|
||||
background: #ffffff !important;
|
||||
background-color: #ffffff !important;
|
||||
}
|
||||
|
||||
.rg-grid .rg-body .rg-table tr.rg-alternate-row td,
|
||||
.rg-grid .rg-body .rg-table tr.rg-alternate-row .rg-data-cell {
|
||||
background-color: #ffffff !important;
|
||||
}
|
||||
@@ -1,19 +1,22 @@
|
||||
import { useRef, useEffect, useState } from "react"
|
||||
import { ValueType } from "realgrid"
|
||||
import { useCallback,useEffect, useLayoutEffect, useRef, useState } from "react"
|
||||
|
||||
import JSZip from "jszip"
|
||||
import { ValueType } from "realgrid"
|
||||
import RealGrid, { GridFitStyle } from "realgrid"
|
||||
import { RealGridReact, RGDataColumn } from "realgrid-react"
|
||||
import type { TabDataGridProps, ColumnInfo, RealGridColumnInfo, GridViewWithSetColumns, FooterItemWithCallback, ColumnLayoutItem } from "../type/DataGrid.type"
|
||||
import { getComputedValueCallback } from "@/components/util/grid/computedFieldCallbacks"
|
||||
import JSZip from "jszip"
|
||||
import * as XLSX from "xlsx"
|
||||
import { useAlertStore } from "@/shared/lib";
|
||||
import { useTabStore } from "@/store/tab-store"
|
||||
|
||||
import { Tabs, TabsList, TabsTrigger, TabsContent } from "@common/components";
|
||||
import { useAlertStore } from "@/shared/lib";
|
||||
import { Tabs, TabsContent,TabsList, TabsTrigger } from "@common/components";
|
||||
import { Button } from "@common/components";
|
||||
import SplitDataGrid from "./SplitDataGrid";
|
||||
|
||||
import type { CellStyleCallback,ColumnConfig, ColumnInfo, ColumnLayoutItem, FooterItemWithCallback, GridViewWithSetColumns, RealGridColumnInfo, TabDataGridProps } from "../type/DataGrid.type"
|
||||
|
||||
import GridTopActionButton from "./GridTopActionButton";
|
||||
import SplitDataGrid from "./SplitDataGrid";
|
||||
|
||||
import { getComputedValueCallback } from "@/components/util/grid/computedFieldCallbacks"
|
||||
import { useTabStore } from "@/store/tab-store"
|
||||
|
||||
// RealGrid 타입 확장
|
||||
declare module "realgrid" {
|
||||
@@ -50,6 +53,30 @@ if (typeof window !== "undefined") {
|
||||
|
||||
RealGrid.setLicenseKey(process.env.NEXT_PUBLIC_ST_REALGRID_KEY || '');
|
||||
|
||||
/** RealGrid 내부 해제(_view 등) 타이밍에서 refresh가 터질 수 있어 try/catch */
|
||||
function safeGridViewRefresh(gv: { refresh?: () => void } | null | undefined) {
|
||||
if (!gv?.refresh) return;
|
||||
try {
|
||||
gv.refresh();
|
||||
} catch {
|
||||
/* noop */
|
||||
}
|
||||
}
|
||||
|
||||
/** columnByName은 그리드 _view 준비 전에 호출되면 "Cannot read ... '_view'"로 터짐 */
|
||||
function safeColumnByName(
|
||||
gv: { columnByName?: (name: string) => unknown } | null | undefined,
|
||||
name: string,
|
||||
): { styleCallback?: (g: unknown, dataCell: Record<string, unknown>) => string } | null {
|
||||
if (!gv?.columnByName) return null;
|
||||
try {
|
||||
const col = gv.columnByName(name) as { styleCallback?: (g: unknown, dataCell: Record<string, unknown>) => string } | null;
|
||||
return col ?? null;
|
||||
} catch {
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
/** 정렬 필드 값을 숫자로 파싱 (쉼표 제거) */
|
||||
function toNum(v: unknown): number {
|
||||
if (v == null) return NaN;
|
||||
@@ -228,6 +255,7 @@ const TabDataGrid = ({
|
||||
getGridDataRef,
|
||||
enableSort = false,
|
||||
facilitySearchStatsYr,
|
||||
cellStyleCallback,
|
||||
}: TabDataGridProps) => {
|
||||
// 각 탭별로 그리드 ref와 데이터를 관리
|
||||
const gridRefs = useRef<Map<string, RealGridReact>>(new Map());
|
||||
@@ -240,6 +268,69 @@ const TabDataGrid = ({
|
||||
const activeTabId = useTabStore((state) => state.activeTabId);
|
||||
const menuList = useTabStore((state) => state.menuList);
|
||||
|
||||
const rowDataMapRef = useRef(rowDataMap);
|
||||
rowDataMapRef.current = rowDataMap;
|
||||
const cellStyleCallbackRef = useRef<CellStyleCallback | undefined>(undefined);
|
||||
cellStyleCallbackRef.current = cellStyleCallback;
|
||||
|
||||
const attachCellStyleCallbacksForTab = useCallback((tabKey: string, columns: ColumnConfig[], attempt = 0) => {
|
||||
if (!cellStyleCallbackRef.current) return;
|
||||
const el = gridRefs.current.get(tabKey);
|
||||
const gv = el?.gridView;
|
||||
if (!gv) return;
|
||||
|
||||
let attachedCount = 0;
|
||||
for (const column of columns) {
|
||||
const gridCol = safeColumnByName(gv, column.name);
|
||||
if (!gridCol) continue;
|
||||
const baseStyleName = column.styleName;
|
||||
gridCol.styleCallback = (_g, dataCell) => {
|
||||
const dc = dataCell as {
|
||||
itemIndex?: number;
|
||||
index?: { itemIndex?: number };
|
||||
dataField?: string;
|
||||
fieldName?: string;
|
||||
};
|
||||
const itemIndex = dc?.index?.itemIndex ?? dc?.itemIndex ?? -1;
|
||||
const fieldName = dc?.dataField ?? dc?.fieldName ?? column.fieldName;
|
||||
const data = rowDataMapRef.current.get(tabKey) || [];
|
||||
if (itemIndex < 0 || itemIndex >= data.length) {
|
||||
return baseStyleName ?? "";
|
||||
}
|
||||
const row = data[itemIndex] as Record<string, string | number>;
|
||||
const extra = cellStyleCallbackRef.current?.({
|
||||
rowIndex: itemIndex,
|
||||
fieldName,
|
||||
row,
|
||||
});
|
||||
if (!extra) return baseStyleName ?? "";
|
||||
return baseStyleName ? `${extra} ${baseStyleName}` : extra;
|
||||
};
|
||||
attachedCount += 1;
|
||||
}
|
||||
|
||||
if (attachedCount === 0 && attempt < 20) {
|
||||
setTimeout(() => attachCellStyleCallbacksForTab(tabKey, columns, attempt + 1), 100);
|
||||
return;
|
||||
}
|
||||
|
||||
setTimeout(() => {
|
||||
const latestGv = gridRefs.current.get(tabKey)?.gridView;
|
||||
safeGridViewRefresh(latestGv ?? null);
|
||||
}, 0);
|
||||
}, []);
|
||||
|
||||
/** 스타일 콜백은 ref로 최신 row를 읽음 — 여기서는 재부착 없이 refresh만 (이른 columnByName 호출 방지) */
|
||||
useLayoutEffect(() => {
|
||||
if (!cellStyleCallback) return;
|
||||
const id = requestAnimationFrame(() => {
|
||||
gridRefs.current.forEach((ref) => {
|
||||
safeGridViewRefresh(ref?.gridView ?? null);
|
||||
});
|
||||
});
|
||||
return () => cancelAnimationFrame(id);
|
||||
}, [cellStyleCallback, rowDataMap]);
|
||||
|
||||
const [internalActiveTab, setInternalActiveTab] = useState<string>(() => {
|
||||
const firstTab = columnInfo[0];
|
||||
return firstTab?.tabKey || '';
|
||||
@@ -559,25 +650,34 @@ const TabDataGrid = ({
|
||||
|
||||
// rowDataMap이 변경될 때 그리드에 데이터 반영 (Excel import 등)
|
||||
useEffect(() => {
|
||||
const timeoutIds: ReturnType<typeof setTimeout>[] = [];
|
||||
|
||||
columnInfo.forEach((info) => {
|
||||
const tabKey = info.tabKey;
|
||||
const gridRef = gridRefs.current.get(tabKey);
|
||||
const currentData = rowDataMap.get(tabKey);
|
||||
|
||||
if (gridRef?.gridView && gridRef?.dataProvider && currentData && currentData.length > 0) {
|
||||
setTimeout(() => {
|
||||
const id = setTimeout(() => {
|
||||
try {
|
||||
const dp = gridRef.dataProvider as RealGridDataProviderFill | null;
|
||||
if (dp?.fillJsonData) {
|
||||
dp.fillJsonData(currentData, { fillMode: "set" });
|
||||
}
|
||||
gridRef.gridView.refresh();
|
||||
const latestRef = gridRefs.current.get(tabKey);
|
||||
const gv = latestRef?.gridView;
|
||||
const dp = latestRef?.dataProvider as RealGridDataProviderFill | null;
|
||||
if (!gv || !dp?.fillJsonData || !currentData.length) return;
|
||||
|
||||
dp.fillJsonData(currentData, { fillMode: "set" });
|
||||
gv.refresh();
|
||||
} catch (error) {
|
||||
console.error("그리드 데이터 설정 오류:", error);
|
||||
}
|
||||
}, 100);
|
||||
timeoutIds.push(id);
|
||||
}
|
||||
});
|
||||
|
||||
return () => {
|
||||
timeoutIds.forEach((tid) => clearTimeout(tid));
|
||||
};
|
||||
}, [rowDataMap, columnInfo]);
|
||||
|
||||
// getGridDataRef: 현재 활성 탭 그리드 데이터 반환 함수 할당
|
||||
@@ -1096,6 +1196,12 @@ const TabDataGrid = ({
|
||||
|
||||
const onSortingHandler = createOnSortingHandler(columns, setRowData, sortDirRef, originalRowsRef, findGridElement);
|
||||
(gridView as { onSorting?: (g: unknown, f: unknown[], d: unknown[]) => boolean }).onSorting = enableSort ? onSortingHandler : () => false;
|
||||
|
||||
if (cellStyleCallbackRef.current) {
|
||||
setTimeout(() => {
|
||||
attachCellStyleCallbacksForTab(tabKey, columns);
|
||||
}, 100);
|
||||
}
|
||||
}, 150);
|
||||
}
|
||||
} else {
|
||||
|
||||
@@ -1,17 +1,45 @@
|
||||
import { useState } from "react";
|
||||
import { useRef, useState } from "react";
|
||||
|
||||
import { useAlertStore } from "@/shared/lib";
|
||||
import { statisticsInputSewSupplyRateApi } from "@/entities/statistics/api/input/statistics-input-sew-supply-rate-service";
|
||||
import { sewagePipeMaintainApiService } from "@/entities/statistics/api/input/statistics-input-sewage-pipe-maintain-service";
|
||||
import type { SewagePipeMaintainRequestParams } from "@/entities/statistics/model/input/statistics-input-sewage-pipe-maintain-interface";
|
||||
import { LoadingWithAnimation } from "@common/components";
|
||||
|
||||
import SearchForm from "@/components/module/SearchForm";
|
||||
import { TabDataGrid } from '@rsone/components';
|
||||
import SubmitButton from "@/components/button/SumitButton";
|
||||
import SaveButton from "@/components/button/SaveButton";
|
||||
import LastYearDataButton from "@/components/button/LastYearDataButton";
|
||||
import SaveButton from "@/components/button/SaveButton";
|
||||
import SubmitExceptionButton from "@/components/button/SubmitExceptionButton";
|
||||
|
||||
import { RepairStatusInpColumn } from "@/components/util/column/input/sewagePipeMaintain/RepairStatusInpColumn";
|
||||
import SubmitButton from "@/components/button/SumitButton";
|
||||
import SearchForm from "@/components/module/SearchForm";
|
||||
import TabDataGrid from "@/components/module/TabDataGrid";
|
||||
import type { SearchFormValues } from "@/components/type/SearchForm.type";
|
||||
import { PipeDredgingStatusInpColumn } from "@/components/util/column/input/sewagePipeMaintain/PipeDredgingStatusInpColumn";
|
||||
import { RepairStatusInpColumn } from "@/components/util/column/input/sewagePipeMaintain/RepairStatusInpColumn";
|
||||
import { toGridRows } from "@/components/util/grid/gridFunction";
|
||||
|
||||
function buildSewagePipeMaintainSearchParam(
|
||||
values: SearchFormValues,
|
||||
overrides?: { mode?: string },
|
||||
): SewagePipeMaintainRequestParams {
|
||||
return {
|
||||
statsYr: values.year,
|
||||
sewerBzmnCd: values.bsnmCd,
|
||||
ctpvNm: values.sido,
|
||||
sggNm: values.gugun === "ALL" ? "" : values.gugun,
|
||||
...(overrides?.mode ? { mode: overrides.mode } : {}),
|
||||
};
|
||||
}
|
||||
|
||||
// 하수도 통계 관리 > 03. 하수관로 유지관리
|
||||
const SewagePipeMaintainInp = () => {
|
||||
const { setMessage: alert } = useAlertStore((state) => state);
|
||||
const [isLoading, setIsLoading] = useState(false);
|
||||
const [searchValues, setSearchValues] = useState<SearchFormValues | null>(null);
|
||||
const [activeTab, setActiveTab] = useState<string>(RepairStatusInpColumn.tabKey);
|
||||
const [lastSearchedValues, setLastSearchedValues] = useState<SearchFormValues | null>(null);
|
||||
const [lastSearchedYear, setLastSearchedYear] = useState<string | null>(null);
|
||||
const [hasSearched, setHasSearched] = useState(false);
|
||||
const searchParamRef = useRef<SewagePipeMaintainRequestParams | null>(null);
|
||||
|
||||
// tab List
|
||||
const SewagePipeMaintainInpTabList = [
|
||||
@@ -24,9 +52,69 @@ const SewagePipeMaintainInp = () => {
|
||||
// 예외 제출 로직
|
||||
};
|
||||
|
||||
const getLastYearDataFunc = () => {
|
||||
console.log('get last year data');
|
||||
// 지난연도 데이터 가져오기 로직
|
||||
const loadActiveTabData = async (
|
||||
tabKey: string,
|
||||
param: SewagePipeMaintainRequestParams,
|
||||
append: boolean,
|
||||
): Promise<void> => {
|
||||
if (tabKey === RepairStatusInpColumn.tabKey) {
|
||||
const response = await sewagePipeMaintainApiService.getSewagePipeMaintainRepair(param);
|
||||
if (response.status !== "success") {
|
||||
alert(response.message || "데이터 조회 중 오류가 발생했습니다.");
|
||||
return;
|
||||
}
|
||||
const commonInfo = response.data.commonInfo;
|
||||
const convertedData = (response.data.repairStatusList ?? []).map((d) => ({
|
||||
ctpvNm: commonInfo.ctpvNm,
|
||||
...d,
|
||||
}));
|
||||
setRowDataMap((prev) => {
|
||||
const next = append ? new Map(prev) : new Map<string, Record<string, string | number>[]>();
|
||||
next.set(RepairStatusInpColumn.tabKey, toGridRows(convertedData));
|
||||
return next;
|
||||
});
|
||||
return;
|
||||
}
|
||||
|
||||
if (tabKey === PipeDredgingStatusInpColumn.tabKey) {
|
||||
const response = await sewagePipeMaintainApiService.getSewagePipeMaintainDredging(param);
|
||||
if (response.status !== "success") {
|
||||
alert(response.message || "데이터 조회 중 오류가 발생했습니다.");
|
||||
return;
|
||||
}
|
||||
const commonInfo = response.data.commonInfo;
|
||||
const convertedData = (response.data.pipeDredgingStatusList ?? []).map((d) => ({
|
||||
ctpvNm: commonInfo.ctpvNm,
|
||||
...d,
|
||||
}));
|
||||
setRowDataMap((prev) => {
|
||||
const next = append ? new Map(prev) : new Map<string, Record<string, string | number>[]>();
|
||||
next.set(PipeDredgingStatusInpColumn.tabKey, toGridRows(convertedData));
|
||||
return next;
|
||||
});
|
||||
}
|
||||
};
|
||||
|
||||
const getLastYearDataFunc = async () => {
|
||||
const values = lastSearchedValues ?? searchValues;
|
||||
if (!values?.sido || values.sido === "ALL") {
|
||||
alert("시도를 선택해주세요.");
|
||||
return;
|
||||
}
|
||||
if (!lastSearchedYear) {
|
||||
alert("먼저 데이터를 조회해주세요.");
|
||||
return;
|
||||
}
|
||||
|
||||
try {
|
||||
setIsLoading(true);
|
||||
const param = buildSewagePipeMaintainSearchParam(values, { mode: "PRE" });
|
||||
await loadActiveTabData(activeTab, param, true);
|
||||
} catch {
|
||||
alert("데이터 조회 중 오류가 발생했습니다.");
|
||||
} finally {
|
||||
setIsLoading(false);
|
||||
}
|
||||
};
|
||||
|
||||
const submitFunc = () => {
|
||||
@@ -40,22 +128,83 @@ const SewagePipeMaintainInp = () => {
|
||||
};
|
||||
|
||||
const [rowDataMap, setRowDataMap] = useState<Map<string, Record<string, string | number>[]>>(new Map());
|
||||
|
||||
const handleReset = () => {
|
||||
setRowDataMap(new Map());
|
||||
setActiveTab(RepairStatusInpColumn.tabKey);
|
||||
setLastSearchedValues(null);
|
||||
setLastSearchedYear(null);
|
||||
setHasSearched(false);
|
||||
searchParamRef.current = null;
|
||||
};
|
||||
|
||||
const handleSearch = async (values: SearchFormValues) => {
|
||||
if (!values.sido || values.sido === "ALL") {
|
||||
alert("시도를 선택해주세요.");
|
||||
return;
|
||||
}
|
||||
|
||||
try {
|
||||
const periodResponse = await statisticsInputSewSupplyRateApi.checkInputPeriod(values.year || "");
|
||||
if (periodResponse.status !== "success") {
|
||||
alert(periodResponse.message);
|
||||
return;
|
||||
}
|
||||
|
||||
setIsLoading(true);
|
||||
const searchParam = buildSewagePipeMaintainSearchParam(values);
|
||||
searchParamRef.current = searchParam;
|
||||
setLastSearchedValues(values);
|
||||
setLastSearchedYear(values.year ?? null);
|
||||
setHasSearched(true);
|
||||
await loadActiveTabData(activeTab, searchParam, false);
|
||||
} catch {
|
||||
alert("데이터 조회 중 오류가 발생했습니다.");
|
||||
} finally {
|
||||
setIsLoading(false);
|
||||
}
|
||||
};
|
||||
|
||||
const handleActiveTabChange = async (tabKey: string) => {
|
||||
setActiveTab(tabKey);
|
||||
const hasRows = (rowDataMap.get(tabKey) ?? []).length > 0;
|
||||
if (hasRows || !searchParamRef.current) return;
|
||||
try {
|
||||
setIsLoading(true);
|
||||
await loadActiveTabData(tabKey, searchParamRef.current, true);
|
||||
} catch {
|
||||
alert("데이터 조회 중 오류가 발생했습니다.");
|
||||
} finally {
|
||||
setIsLoading(false);
|
||||
}
|
||||
};
|
||||
|
||||
const hasRowData = Array.from(rowDataMap.values()).some((rows) => rows.length > 0);
|
||||
|
||||
return (
|
||||
<>
|
||||
<SearchForm />
|
||||
<div className="card !py-0">
|
||||
<div className="flex justify-end items-center gap-[0.6rem] m-[0.6rem]">
|
||||
<SubmitExceptionButton SubmitExceptionFunc={SubmitExceptionFunc} />
|
||||
<LastYearDataButton getLastYearDataFunc={getLastYearDataFunc} />
|
||||
<SubmitButton submitFunc={submitFunc} />
|
||||
<SaveButton saveFunc={saveFunc} />
|
||||
<SearchForm onSubmit={handleSearch} onReset={handleReset} onValuesChange={setSearchValues} />
|
||||
{(hasRowData || hasSearched) && (
|
||||
<div className="card !py-0">
|
||||
<div className="flex justify-end items-center gap-[0.6rem] m-[0.6rem]">
|
||||
<SubmitExceptionButton SubmitExceptionFunc={SubmitExceptionFunc} />
|
||||
<LastYearDataButton getLastYearDataFunc={() => void getLastYearDataFunc()} />
|
||||
<SubmitButton submitFunc={submitFunc} />
|
||||
<SaveButton saveFunc={saveFunc} />
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
)}
|
||||
{isLoading && <div className="absolute inset-0 z-50 [data-theme='black']:bg-transparent rounded-lg p-10 flex justify-center items-center">
|
||||
<div className="relative size-[5rem]">
|
||||
<LoadingWithAnimation color="primary" />
|
||||
</div>
|
||||
</div>}
|
||||
<TabDataGrid
|
||||
columnInfo={SewagePipeMaintainInpTabList}
|
||||
rowDataMap={rowDataMap}
|
||||
setRowDataMap={setRowDataMap}
|
||||
activeTab={activeTab}
|
||||
onActiveTabChange={handleActiveTabChange}
|
||||
/>
|
||||
</>
|
||||
);
|
||||
|
||||
@@ -1,18 +1,18 @@
|
||||
"use client";
|
||||
|
||||
import { useCallback, useState } from 'react';
|
||||
import { useCallback, useState, useEffect } from 'react';
|
||||
|
||||
import {
|
||||
Button,
|
||||
Label,
|
||||
LoadingWithAnimation,
|
||||
}
|
||||
from "@common/components";
|
||||
} from "@common/components";
|
||||
import DataGrid from '@/components/module/DataGrid';
|
||||
import { CodeSelectWithAll } from '@/entities/code';
|
||||
|
||||
import { statisticsAPi } from '@/entities/statistics/api/statistics-service';
|
||||
import type { StatisticsLogRequest } from '@/entities/statistics/model/statistics-interface';
|
||||
import type { StatisticsLogRequest, StatisticsLog } from '@/entities/statistics/model/statistics-interface';
|
||||
import { LogHistoryDetailDialog } from '@/components/statistics/management/LogHistoryDetailDialog';
|
||||
import { toGridRows } from '@/components/util/grid/gridFunction';
|
||||
|
||||
import { LogHistoryColumn } from '@/components/util/column/management/LogHistoryColumn';
|
||||
@@ -27,6 +27,11 @@ const LogHistory = () => {
|
||||
const [rowData, setRowData] = useState<Record<string, string | number>[]>([]);
|
||||
const [pageIndex, setPageIndex] = useState(0);
|
||||
const [totalPages, setTotalPages] = useState(0);
|
||||
const [detailDialogOpen, setDetailDialogOpen] = useState(false);
|
||||
const [selectedLogRow, setSelectedLogRow] = useState<Record<
|
||||
string,
|
||||
string | number
|
||||
> | null>(null);
|
||||
|
||||
const loadLogs = useCallback(async (page1Based: number) => {
|
||||
const param: StatisticsLogRequest = {
|
||||
@@ -41,7 +46,13 @@ const LogHistory = () => {
|
||||
const response = await statisticsAPi.getLogList(param);
|
||||
|
||||
if (response.status === 'success') {
|
||||
setRowData(toGridRows(response.data?.statsLogList ?? []));
|
||||
const lostList = response.data?.statsLogList ?? [];
|
||||
const convertedData: StatisticsLog[] = lostList.map((item: StatisticsLog) => ({
|
||||
...item,
|
||||
dmndFwkNm: item.dmndFwkNm === 'save' ? '저장' : (item.dmndFwkNm === 'submit' ? '제출' : '예외 제출'),
|
||||
}));
|
||||
|
||||
setRowData(toGridRows(convertedData));
|
||||
setTotalPages(response.data?.pageInfo?.totalPages ?? 0);
|
||||
setPageIndex(Math.max(0, page1Based - 1));
|
||||
} else {
|
||||
@@ -59,6 +70,20 @@ const LogHistory = () => {
|
||||
await loadLogs(1);
|
||||
};
|
||||
|
||||
const handleRowClick = (row: Record<string, string | number>) => {
|
||||
setSelectedLogRow(row);
|
||||
setDetailDialogOpen(true);
|
||||
};
|
||||
|
||||
const handleDetailDialogOpenChange = (next: boolean) => {
|
||||
setDetailDialogOpen(next);
|
||||
if (!next) setSelectedLogRow(null);
|
||||
};
|
||||
|
||||
useEffect(() => {
|
||||
loadLogs(1);
|
||||
}, []);
|
||||
|
||||
return (
|
||||
<div className="relative">
|
||||
<div className="card card-border">
|
||||
@@ -97,6 +122,12 @@ const LogHistory = () => {
|
||||
isExcelImport={false}
|
||||
rowData={rowData}
|
||||
setRowData={() => { }}
|
||||
onRowClick={handleRowClick}
|
||||
/>
|
||||
<LogHistoryDetailDialog
|
||||
open={detailDialogOpen}
|
||||
onOpenChange={handleDetailDialogOpenChange}
|
||||
row={selectedLogRow}
|
||||
/>
|
||||
<LogHistoryTablePagination
|
||||
pageCount={totalPages}
|
||||
|
||||
@@ -0,0 +1,56 @@
|
||||
"use client";
|
||||
|
||||
import { useEffect } from "react";
|
||||
|
||||
import {
|
||||
Button,
|
||||
Dialog,
|
||||
DialogClose,
|
||||
DialogContent,
|
||||
DialogFooter,
|
||||
DialogHeader,
|
||||
DialogTitle,
|
||||
} from "@common/components";
|
||||
|
||||
import { statisticsAPi } from "@/entities/statistics/api/statistics-service";
|
||||
|
||||
export interface LogHistoryDetailDialogProps {
|
||||
open: boolean;
|
||||
onOpenChange: (open: boolean) => void;
|
||||
row: Record<string, string | number> | null;
|
||||
}
|
||||
|
||||
export function LogHistoryDetailDialog({
|
||||
open,
|
||||
onOpenChange,
|
||||
row,
|
||||
}: LogHistoryDetailDialogProps) {
|
||||
useEffect(() => {
|
||||
if (!open || !row) return;
|
||||
|
||||
const sn = row.statsLogSn;
|
||||
void (async () => {
|
||||
const response = await statisticsAPi.getLogDetail(
|
||||
sn !== undefined && sn !== null ? String(sn) : "",
|
||||
);
|
||||
console.log(response.data);
|
||||
})();
|
||||
}, [open, row]);
|
||||
|
||||
return (
|
||||
<Dialog open={open} onOpenChange={onOpenChange}>
|
||||
<DialogContent className="max-w-[60rem]" aria-describedby={undefined}>
|
||||
<DialogHeader>
|
||||
<DialogTitle />
|
||||
</DialogHeader>
|
||||
<DialogFooter>
|
||||
<DialogClose asChild>
|
||||
<Button size="lg" color="white" type="button">
|
||||
닫기
|
||||
</Button>
|
||||
</DialogClose>
|
||||
</DialogFooter>
|
||||
</DialogContent>
|
||||
</Dialog>
|
||||
);
|
||||
}
|
||||
@@ -43,7 +43,7 @@ export function LogHistoryTablePagination({
|
||||
const canNext = pageCount > 0 && currentPage < pageCount - 1;
|
||||
|
||||
return (
|
||||
<div className="mt-[24px] flex items-center justify-center space-x-2">
|
||||
<div className="mt-[24px] mb-4 flex items-center justify-center space-x-2">
|
||||
<Button
|
||||
variant="ghost"
|
||||
color="white"
|
||||
|
||||
@@ -1,29 +1,63 @@
|
||||
import { useState, useMemo, useRef } from "react";
|
||||
import TabDataGrid from "@/components/module/TabDataGrid";
|
||||
import SearchForm from "@/components/module/SearchForm";
|
||||
import SaveButton from "@/components/button/SaveButton";
|
||||
import ApproveButton from "@/components/button/ApproveButton";
|
||||
import ReviewOpinionButton from "@/components/button/ReviewOpinionButton";
|
||||
import ReturnButton from "@/components/button/ReturnButton";
|
||||
import { LoadingWithAnimation } from "@common/components";
|
||||
import { useMemo, useRef,useState } from "react";
|
||||
|
||||
import { useAlertStore } from "@/shared/lib";
|
||||
import { statisticsManagementApi } from "@/entities/statistics/api/statistics-management-service";
|
||||
import { SewagePipeMaintainColumnInfoList } from "@/components/util/column/review/SewagePipeMaintainRvwColumn";
|
||||
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";
|
||||
import { LoadingWithAnimation } from "@common/components";
|
||||
|
||||
import ApproveButton from "@/components/button/ApproveButton";
|
||||
import ReturnButton from "@/components/button/ReturnButton";
|
||||
import ReviewOpinionButton from "@/components/button/ReviewOpinionButton";
|
||||
import SaveButton from "@/components/button/SaveButton";
|
||||
import SearchForm from "@/components/module/SearchForm";
|
||||
import TabDataGrid from "@/components/module/TabDataGrid";
|
||||
import type { ColumnConfig,ColumnInfoList } from "@/components/type/DataGrid.type";
|
||||
import type { SearchFormValues } from "@/components/type/SearchForm.type";
|
||||
import { SewagePipeMaintainColumnInfoList } from "@/components/util/column/review/SewagePipeMaintainRvwColumn";
|
||||
import { toGridRows } from "@/components/util/grid/gridFunction";
|
||||
|
||||
|
||||
const firstTabKey = SewagePipeMaintainColumnInfoList[0]?.tabKey ?? "ST00030001";
|
||||
|
||||
async function fetchSewagePipeMaintainReviewTab(
|
||||
tabKey: string,
|
||||
searchParam: SewerPipeMtcRequestParams,
|
||||
) {
|
||||
if (tabKey === "ST00030001") {
|
||||
return statisticsManagementApi.getSewerPipeMtcList(searchParam);
|
||||
}
|
||||
if (tabKey === "ST00030002") {
|
||||
return statisticsManagementApi.getSewerPipeDrdgList(searchParam);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
function getListDataByTab(tabKey: string, responseData: unknown): object[] {
|
||||
if (Array.isArray(responseData)) {
|
||||
return responseData as object[];
|
||||
}
|
||||
if (!responseData || typeof responseData !== "object") {
|
||||
return [];
|
||||
}
|
||||
if (tabKey === "ST00030001") {
|
||||
return (((responseData as { mtcStatusList?: unknown[] }).mtcStatusList) ?? []) as object[];
|
||||
}
|
||||
if (tabKey === "ST00030002") {
|
||||
return (((responseData as { drdgStatusList?: unknown[] }).drdgStatusList) ?? []) as object[];
|
||||
}
|
||||
return [];
|
||||
}
|
||||
|
||||
// 하수도 통계 검토 03. 하수관로 유지 관리
|
||||
const SewagePipeMaintainRvw = () => {
|
||||
const { setMessage: alert } = useAlertStore((state) => state);
|
||||
const [rowDataMap, setRowDataMap] = useState<Map<string, Record<string, string | number>[]>>(new Map());
|
||||
const [isLoading, setIsLoading] = useState<boolean>(false);
|
||||
const [activeTab, setActiveTab] = useState<string>('ST00030001');
|
||||
const [activeTab, setActiveTab] = useState<string>(firstTabKey);
|
||||
|
||||
const searchParamRef = useRef<SewerPipeMtcRequestParams | null>(null);
|
||||
const searchDoneRef = useRef(false);
|
||||
const lazyTabLoggedRef = useRef<Set<string>>(new Set());
|
||||
|
||||
const columnInfo = useMemo(() => {
|
||||
return SewagePipeMaintainColumnInfoList.map((tab: ColumnInfoList) => ({
|
||||
@@ -38,8 +72,10 @@ const SewagePipeMaintainRvw = () => {
|
||||
|
||||
const handleReset = () => {
|
||||
setRowDataMap(new Map());
|
||||
setActiveTab('ST00030001');
|
||||
setActiveTab(firstTabKey);
|
||||
searchParamRef.current = null;
|
||||
searchDoneRef.current = false;
|
||||
lazyTabLoggedRef.current.clear();
|
||||
};
|
||||
|
||||
const handleSearch = async (values: SearchFormValues) => {
|
||||
@@ -48,9 +84,6 @@ const SewagePipeMaintainRvw = () => {
|
||||
return;
|
||||
}
|
||||
|
||||
setActiveTab('ST00030001');
|
||||
setRowDataMap(new Map());
|
||||
|
||||
try {
|
||||
setIsLoading(true);
|
||||
|
||||
@@ -62,17 +95,17 @@ const SewagePipeMaintainRvw = () => {
|
||||
};
|
||||
|
||||
searchParamRef.current = searchParam;
|
||||
const response = await statisticsManagementApi.getSewerPipeMtcList(searchParam);
|
||||
searchDoneRef.current = true;
|
||||
lazyTabLoggedRef.current.clear();
|
||||
setRowDataMap(new Map());
|
||||
|
||||
const response = await fetchSewagePipeMaintainReviewTab(activeTab, searchParam);
|
||||
|
||||
if (response?.status === 'success' && response.data) {
|
||||
const newRowDataMap = new Map<string, Record<string, string | number>[]>();
|
||||
|
||||
const listData = Array.isArray(response.data)
|
||||
? response.data
|
||||
: (response.data.mtcStatusList || []);
|
||||
|
||||
newRowDataMap.set('ST00030001', toGridRows(listData as object[]));
|
||||
setRowDataMap(newRowDataMap);
|
||||
const listData = getListDataByTab(activeTab, response.data);
|
||||
setRowDataMap(
|
||||
new Map([[activeTab, toGridRows(listData)]]),
|
||||
);
|
||||
} else {
|
||||
alert(response?.message || "데이터가 없습니다.");
|
||||
}
|
||||
@@ -86,43 +119,40 @@ const SewagePipeMaintainRvw = () => {
|
||||
const handleActiveTabChange = async (tabKey: string) => {
|
||||
setActiveTab(tabKey);
|
||||
|
||||
const existingAData = rowDataMap.get('ST00030001');
|
||||
const activeTabData = rowDataMap.get(tabKey);
|
||||
|
||||
const hasAData = Array.isArray(existingAData) && existingAData.length > 0;
|
||||
const hasActiveTabData = Array.isArray(activeTabData) && activeTabData.length > 0;
|
||||
|
||||
if (hasAData && !hasActiveTabData && searchParamRef.current) {
|
||||
try {
|
||||
setIsLoading(true);
|
||||
const canLazyLoad =
|
||||
searchParamRef.current &&
|
||||
!hasActiveTabData &&
|
||||
!lazyTabLoggedRef.current.has(tabKey) &&
|
||||
searchDoneRef.current;
|
||||
|
||||
let response;
|
||||
if (!canLazyLoad) return;
|
||||
|
||||
if (tabKey === 'ST00030001') {
|
||||
response = await statisticsManagementApi.getSewerPipeMtcList(searchParamRef.current);
|
||||
} else if (tabKey === 'ST00030002') {
|
||||
response = await statisticsManagementApi.getSewerPipeDrdgList(searchParamRef.current);
|
||||
}
|
||||
const searchParam = searchParamRef.current;
|
||||
if (!searchParam) return;
|
||||
|
||||
if (response?.status === 'success' && response.data) {
|
||||
setRowDataMap(prev => {
|
||||
const next = new Map(prev);
|
||||
try {
|
||||
setIsLoading(true);
|
||||
|
||||
const listData = Array.isArray(response.data)
|
||||
? response.data
|
||||
: (response.data.mtcStatusList || []);
|
||||
const response = await fetchSewagePipeMaintainReviewTab(tabKey, searchParam);
|
||||
lazyTabLoggedRef.current.add(tabKey);
|
||||
|
||||
next.set(tabKey, toGridRows(listData as object[]));
|
||||
return next;
|
||||
});
|
||||
} else {
|
||||
alert(response?.message || "데이터가 없습니다.");
|
||||
}
|
||||
} catch {
|
||||
alert('데이터 조회 중 오류가 발생했습니다.');
|
||||
} finally {
|
||||
setIsLoading(false);
|
||||
if (response?.status === "success" && response.data) {
|
||||
setRowDataMap((prev) => {
|
||||
const next = new Map(prev);
|
||||
const listData = getListDataByTab(tabKey, response.data);
|
||||
next.set(tabKey, toGridRows(listData));
|
||||
return next;
|
||||
});
|
||||
} else {
|
||||
alert(response?.message || "데이터가 없습니다.");
|
||||
}
|
||||
} catch {
|
||||
alert("데이터 조회 중 오류가 발생했습니다.");
|
||||
} finally {
|
||||
setIsLoading(false);
|
||||
}
|
||||
};
|
||||
|
||||
|
||||
@@ -1,29 +1,52 @@
|
||||
import { useState, useMemo, useRef } from "react";
|
||||
import TabDataGrid from "@/components/module/TabDataGrid";
|
||||
import SearchForm from "@/components/module/SearchForm";
|
||||
import SaveButton from "@/components/button/SaveButton";
|
||||
import ApproveButton from "@/components/button/ApproveButton";
|
||||
import ReviewOpinionButton from "@/components/button/ReviewOpinionButton";
|
||||
import ReturnButton from "@/components/button/ReturnButton";
|
||||
import { LoadingWithAnimation } from "@common/components";
|
||||
import { useMemo, useRef,useState } from "react";
|
||||
|
||||
import { useAlertStore } from "@/shared/lib";
|
||||
import { statisticsManagementApi } from "@/entities/statistics/api/statistics-management-service";
|
||||
import { SewagePipeColumnInfoListRvw } from "@/components/util/column/review/SewagePipeRvwColumn";
|
||||
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 { SewagePipeReviewRequestParams } from "@/entities/statistics/model/statistics-sewage-pipe-review-interface";
|
||||
import { LoadingWithAnimation } from "@common/components";
|
||||
|
||||
import ApproveButton from "@/components/button/ApproveButton";
|
||||
import ReturnButton from "@/components/button/ReturnButton";
|
||||
import ReviewOpinionButton from "@/components/button/ReviewOpinionButton";
|
||||
import SaveButton from "@/components/button/SaveButton";
|
||||
import SearchForm from "@/components/module/SearchForm";
|
||||
import TabDataGrid from "@/components/module/TabDataGrid";
|
||||
import type { ColumnConfig,ColumnInfoList } from "@/components/type/DataGrid.type";
|
||||
import type { SearchFormValues } from "@/components/type/SearchForm.type";
|
||||
import { SewagePipeColumnInfoListRvw } from "@/components/util/column/review/SewagePipeRvwColumn";
|
||||
import { toGridRows } from "@/components/util/grid/gridFunction";
|
||||
|
||||
// 하수도 통계 검토 02.하수관로
|
||||
const firstTabKey = SewagePipeColumnInfoListRvw[0]?.tabKey ?? "ST00020001";
|
||||
|
||||
async function fetchSewagePipeReviewTab(
|
||||
tabKey: string,
|
||||
searchParam: SewagePipeReviewRequestParams,
|
||||
) {
|
||||
if (tabKey === "ST00020001") {
|
||||
return statisticsManagementApi.getSewagePipeReviewRegionalList(searchParam);
|
||||
}
|
||||
if (tabKey === "ST00020002") {
|
||||
return statisticsManagementApi.getSewagePipeFacilityList(searchParam);
|
||||
}
|
||||
if (tabKey === "ST00020003") {
|
||||
return statisticsManagementApi.getSewagePipeTypeList(searchParam);
|
||||
}
|
||||
if (tabKey === "ST00020004") {
|
||||
return statisticsManagementApi.getSewagePipeDiamList(searchParam);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
// 하수도 통계 검토 02.하수관로
|
||||
const SewagePipeRvw = () => {
|
||||
const { setMessage: alert } = useAlertStore((state) => state);
|
||||
const [rowDataMap, setRowDataMap] = useState<Map<string, Record<string, string | number>[]>>(new Map());
|
||||
const [isLoading, setIsLoading] = useState<boolean>(false);
|
||||
const [activeTab, setActiveTab] = useState<string>('ST00020001');
|
||||
const [activeTab, setActiveTab] = useState<string>(firstTabKey);
|
||||
|
||||
const searchParamRef = useRef<SewagePipeReviewRequestParams | null>(null);
|
||||
const searchDoneRef = useRef(false);
|
||||
const lazyTabLoggedRef = useRef<Set<string>>(new Set());
|
||||
|
||||
const columnInfo = useMemo(() => {
|
||||
return SewagePipeColumnInfoListRvw.map((tab: ColumnInfoList) => ({
|
||||
@@ -38,19 +61,18 @@ const SewagePipeRvw = () => {
|
||||
|
||||
const handleReset = () => {
|
||||
setRowDataMap(new Map());
|
||||
setActiveTab('ST00020001');
|
||||
setActiveTab(firstTabKey);
|
||||
searchParamRef.current = null;
|
||||
searchDoneRef.current = false;
|
||||
lazyTabLoggedRef.current.clear();
|
||||
};
|
||||
|
||||
const handleSearch = async (values: SearchFormValues) => {
|
||||
if (!values.sido || values.sido === 'ALL') {
|
||||
alert('시도를 선택해주세요.');
|
||||
if (!values.sido || values.sido === "ALL") {
|
||||
alert("시도를 선택해주세요.");
|
||||
return;
|
||||
}
|
||||
|
||||
setActiveTab('ST00020001');
|
||||
|
||||
setRowDataMap(new Map());
|
||||
|
||||
try {
|
||||
setIsLoading(true);
|
||||
|
||||
@@ -58,21 +80,25 @@ const SewagePipeRvw = () => {
|
||||
statsYr: values.year,
|
||||
sewerBzmnCd: values.bsnmCd,
|
||||
ctpvNm: values.sido,
|
||||
sggNm: values.gugun === 'ALL' ? '' : values.gugun
|
||||
sggNm: values.gugun === "ALL" ? "" : values.gugun,
|
||||
};
|
||||
|
||||
searchParamRef.current = searchParam;
|
||||
const response = await statisticsManagementApi.getSewagePipeReviewRegionalList(searchParam);
|
||||
searchDoneRef.current = true;
|
||||
lazyTabLoggedRef.current.clear();
|
||||
setRowDataMap(new Map());
|
||||
|
||||
if (response?.status === 'success' && response.data) {
|
||||
const newRowDataMap = new Map<string, Record<string, string | number>[]>();
|
||||
newRowDataMap.set('ST00020001', toGridRows(response.data as object[]));
|
||||
setRowDataMap(newRowDataMap);
|
||||
const response = await fetchSewagePipeReviewTab(activeTab, searchParam);
|
||||
|
||||
if (response?.status === "success" && response.data) {
|
||||
setRowDataMap(
|
||||
new Map([[activeTab, toGridRows(response.data as object[])]]),
|
||||
);
|
||||
} else {
|
||||
alert(response?.message || '데이터 조회 중 오류가 발생했습니다.');
|
||||
alert(response?.message || "데이터 조회 중 오류가 발생했습니다.");
|
||||
}
|
||||
} catch {
|
||||
alert('데이터 조회 중 오류가 발생했습니다.');
|
||||
alert("데이터 조회 중 오류가 발생했습니다.");
|
||||
} finally {
|
||||
setIsLoading(false);
|
||||
}
|
||||
@@ -81,42 +107,39 @@ const SewagePipeRvw = () => {
|
||||
const handleActiveTabChange = async (tabKey: string) => {
|
||||
setActiveTab(tabKey);
|
||||
|
||||
const existingAData = rowDataMap.get('ST00020001');
|
||||
const activeTabData = rowDataMap.get(tabKey);
|
||||
|
||||
const hasAData = Array.isArray(existingAData) && existingAData.length > 0;
|
||||
const hasActiveTabData = Array.isArray(activeTabData) && activeTabData.length > 0;
|
||||
|
||||
if (hasAData && !hasActiveTabData && searchParamRef.current) {
|
||||
const canLazyLoad =
|
||||
searchParamRef.current &&
|
||||
!hasActiveTabData &&
|
||||
!lazyTabLoggedRef.current.has(tabKey) &&
|
||||
searchDoneRef.current;
|
||||
|
||||
try {
|
||||
setIsLoading(true);
|
||||
if (!canLazyLoad) return;
|
||||
|
||||
let response;
|
||||
const searchParam = searchParamRef.current;
|
||||
if (!searchParam) return;
|
||||
|
||||
if (tabKey === 'ST00020002') {
|
||||
response = await statisticsManagementApi.getSewagePipeFacilityList(searchParamRef.current);
|
||||
} else if (tabKey === 'ST00020003') {
|
||||
response = await statisticsManagementApi.getSewagePipeTypeList(searchParamRef.current);
|
||||
} else if (tabKey === 'ST00020004') {
|
||||
response = await statisticsManagementApi.getSewagePipeDiamList(searchParamRef.current);
|
||||
}
|
||||
try {
|
||||
setIsLoading(true);
|
||||
|
||||
if (response?.status === 'success' && response.data) {
|
||||
const response = await fetchSewagePipeReviewTab(tabKey, searchParam);
|
||||
lazyTabLoggedRef.current.add(tabKey);
|
||||
|
||||
setRowDataMap(prev => {
|
||||
const next = new Map(prev);
|
||||
next.set(tabKey, toGridRows(response.data as object[]));
|
||||
return next;
|
||||
});
|
||||
} else {
|
||||
alert(response?.message || "데이터가 없습니다.");
|
||||
}
|
||||
} catch {
|
||||
alert('데이터 조회 중 오류가 발생했습니다.');
|
||||
} finally {
|
||||
setIsLoading(false);
|
||||
if (response?.status === "success" && response.data) {
|
||||
setRowDataMap((prev) => {
|
||||
const next = new Map(prev);
|
||||
next.set(tabKey, toGridRows(response.data as object[]));
|
||||
return next;
|
||||
});
|
||||
} else {
|
||||
alert(response?.message || "데이터가 없습니다.");
|
||||
}
|
||||
} catch {
|
||||
alert("데이터 조회 중 오류가 발생했습니다.");
|
||||
} finally {
|
||||
setIsLoading(false);
|
||||
}
|
||||
};
|
||||
|
||||
@@ -152,4 +175,4 @@ const SewagePipeRvw = () => {
|
||||
);
|
||||
};
|
||||
|
||||
export default SewagePipeRvw;
|
||||
export default SewagePipeRvw;
|
||||
|
||||
@@ -3,11 +3,12 @@ import DataGrid from "@/components/module/DataGrid";
|
||||
import SearchForm from "@/components/module/SearchForm";
|
||||
import ReviewOpinionButton from "@/components/button/ReviewOpinionButton";
|
||||
import ReturnButton from "@/components/button/ReturnButton";
|
||||
import SubmitButton from "@/components/button/SumitButton";
|
||||
import { LoadingWithAnimation } from "@common/components";
|
||||
|
||||
import { useAlertStore } from "@/shared/lib";
|
||||
import { SeweragePenetrationRateInfoList } from "@/components/util/column/review/SeweragePenetrationRateRvwColumn";
|
||||
import type { SewerageSupplyRateReviewItem } from "@/entities/statistics/model/statistics-sewerage-penetration-review-interface";
|
||||
import type { SewerageSupplyRateReviewItem, statsStatusInfo } from "@/entities/statistics/model/statistics-sewerage-penetration-review-interface";
|
||||
import { statisticsManagementApi } from "@/entities/statistics/api/statistics-management-service";
|
||||
import type { SearchFormValues } from "@/components/type/SearchForm.type";
|
||||
import { toGridRows } from "@/components/util/grid/gridFunction";
|
||||
@@ -17,6 +18,7 @@ const SeweragePenetrationRateRvw = () => {
|
||||
const { setMessage: alert } = useAlertStore((state) => state);
|
||||
const [rowData, setRowData] = useState<Record<string, string | number>[]>([]);
|
||||
const [isLoading, setIsLoading] = useState<boolean>(false);
|
||||
const [statsStatusInfo, setStatsStatusInfo] = useState<statsStatusInfo>({});
|
||||
|
||||
const columnInfo = useMemo(() => {
|
||||
const { columns, columnLayout, fixedColumns, rowStartNum } = SeweragePenetrationRateInfoList;
|
||||
@@ -32,8 +34,24 @@ const SeweragePenetrationRateRvw = () => {
|
||||
};
|
||||
}, []);
|
||||
|
||||
const { showReviewOpinionButton, showReturnButton, showSubmitButton } = useMemo(() => {
|
||||
const lae = statsStatusInfo.laeSbmsnSttsCd != null ? String(statsStatusInfo.laeSbmsnSttsCd) : "";
|
||||
const pic = statsStatusInfo.statPicSbmsnSttsCd != null ? String(statsStatusInfo.statPicSbmsnSttsCd) : "";
|
||||
const laeIs3 = lae === "3";
|
||||
const reviewSubmitVisible = laeIs3 && (pic === "0" || pic === "1");
|
||||
return {
|
||||
showReviewOpinionButton: reviewSubmitVisible,
|
||||
showSubmitButton: reviewSubmitVisible,
|
||||
showReturnButton: laeIs3 && pic !== "3",
|
||||
};
|
||||
}, [statsStatusInfo]);
|
||||
|
||||
const showActionBar =
|
||||
showReviewOpinionButton || showReturnButton || showSubmitButton;
|
||||
|
||||
const handleReset = () => {
|
||||
setRowData([]);
|
||||
setStatsStatusInfo({});
|
||||
};
|
||||
|
||||
const handleSearch = async (values: SearchFormValues) => {
|
||||
@@ -60,7 +78,8 @@ const SeweragePenetrationRateRvw = () => {
|
||||
|
||||
spcCtpnRgnCn: !item.spcCtpnRgnCn ? '해당없음' : item.spcCtpnRgnCn,
|
||||
}));
|
||||
|
||||
|
||||
setStatsStatusInfo(response.data.statsStatusInfo);
|
||||
setRowData(toGridRows(convertedData));
|
||||
} else {
|
||||
setRowData([]);
|
||||
@@ -74,21 +93,27 @@ const SeweragePenetrationRateRvw = () => {
|
||||
}
|
||||
};
|
||||
|
||||
const approveFunc = () => console.log('approveFunc');
|
||||
const saveFunc = () => console.log('submit');
|
||||
const submitFunc = () => console.log('submit');
|
||||
|
||||
const reviewOpinionFunc = () => console.log('reviewOpinionFunc');
|
||||
|
||||
const returnFunc = () => console.log('returnFunc');
|
||||
|
||||
return (
|
||||
<div className="relative">
|
||||
<SearchForm onSubmit={handleSearch} onReset={handleReset} />
|
||||
|
||||
<div className="card !py-0">
|
||||
<div className="flex justify-end items-center gap-[0.6rem] m-[0.6rem]">
|
||||
<ReviewOpinionButton reviewOpinionFunc={reviewOpinionFunc} />
|
||||
<ReturnButton returnFunc={returnFunc} />
|
||||
{showActionBar && (
|
||||
<div className="card !py-0">
|
||||
<div className="flex justify-end items-center gap-[0.6rem] m-[0.6rem]">
|
||||
{showReviewOpinionButton && (
|
||||
<ReviewOpinionButton reviewOpinionFunc={reviewOpinionFunc} />
|
||||
)}
|
||||
{showReturnButton && <ReturnButton returnFunc={returnFunc} />}
|
||||
{showSubmitButton && <SubmitButton submitFunc={submitFunc} />}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
)}
|
||||
|
||||
{isLoading && (
|
||||
<div className="absolute inset-0 z-50 [data-theme='black']:bg-transparent rounded-lg p-10 flex justify-center items-center">
|
||||
|
||||
@@ -10,7 +10,6 @@ import { LoadingWithAnimation } from "@common/components";
|
||||
import { useAlertStore } from "@/shared/lib";
|
||||
import { StatsInputStatusInfoList } from "@/components/util/column/review/StatsInputStatusRvwColumn";
|
||||
import { statisticsManagementApi } from "@/entities/statistics/api/statistics-management-service";
|
||||
import type { StatsInputStatusReviewItem } from "@/entities/statistics/model/statistics-input-review-interface";
|
||||
import { toGridRows } from "@/components/util/grid/gridFunction";
|
||||
import type { SearchFormValues } from "@/components/type/SearchForm.type";
|
||||
|
||||
@@ -52,13 +51,9 @@ const StatsInputStatusRvw = () => {
|
||||
});
|
||||
|
||||
if (response.status === 'success' && response.data) {
|
||||
const rawList = response.data.sewerageSupplyRateList ?? [];
|
||||
const convertedData: StatsInputStatusReviewItem[] = rawList.map((item: StatsInputStatusReviewItem) => ({
|
||||
...item,
|
||||
// status: item.status || '미확인',
|
||||
}));
|
||||
const rawList = response.data.sewerageInputList ?? [];
|
||||
|
||||
setRowData(toGridRows(convertedData));
|
||||
setRowData(toGridRows(rawList));
|
||||
} else {
|
||||
setRowData([]);
|
||||
alert(response.message || "조회된 데이터가 없습니다.");
|
||||
@@ -103,7 +98,7 @@ const StatsInputStatusRvw = () => {
|
||||
isExcelImport={false}
|
||||
showHeaderCheckbox={true}
|
||||
rowStartNum={2}
|
||||
fixedColumns={4}
|
||||
fixedColumns={3}
|
||||
rowData={rowData}
|
||||
setRowData={setRowData}
|
||||
/>
|
||||
|
||||
@@ -1,11 +1,97 @@
|
||||
import { useMemo, useState } from "react";
|
||||
|
||||
import { useAlertStore } from "@/shared/lib";
|
||||
import { statisticsTotalStatusApi } from "@/entities/statistics/api/statistics-total-service";
|
||||
import { LoadingWithAnimation } from "@common/components";
|
||||
|
||||
import SearchForm from "@/components/module/SearchForm";
|
||||
import TabDataGrid from "@/components/module/TabDataGrid";
|
||||
import type { ColumnConfig, ColumnInfoList } from "@/components/type/DataGrid.type";
|
||||
import type { SearchFormValues } from "@/components/type/SearchForm.type";
|
||||
import { SewagePipeColumnInfoListTot } from "@/components/util/column/total/SewagePipeTotColumn";
|
||||
import { toGridRows } from "@/components/util/grid/gridFunction";
|
||||
|
||||
const SewagePipeTot = () => {
|
||||
const { setMessage: alert } = useAlertStore((state) => state);
|
||||
const [rowDataMap, setRowDataMap] = useState<Map<string, Record<string, string | number>[]>>(new Map());
|
||||
const [isLoading, setIsLoading] = useState(false);
|
||||
const [activeTab, setActiveTab] = useState("ST00020001");
|
||||
|
||||
const columnInfo = useMemo(
|
||||
() =>
|
||||
SewagePipeColumnInfoListTot.map((tab: ColumnInfoList) => ({
|
||||
...tab,
|
||||
columns: (tab.columns ?? []).map((col: ColumnConfig) => ({
|
||||
...col,
|
||||
editable: false as const,
|
||||
styleName: col.styleName ?? ("rg-cell-readonly" as const),
|
||||
})),
|
||||
})),
|
||||
[],
|
||||
);
|
||||
|
||||
const handleReset = () => {
|
||||
setRowDataMap(new Map());
|
||||
setActiveTab("ST00020001");
|
||||
};
|
||||
|
||||
const handleSearch = async (values: SearchFormValues) => {
|
||||
setActiveTab("ST00020001");
|
||||
setRowDataMap(new Map());
|
||||
|
||||
try {
|
||||
setIsLoading(true);
|
||||
|
||||
const param = {
|
||||
ctpvNm: values.sido === "ALL" ? "" : values.sido,
|
||||
sggNm: values.gugun === "ALL" ? "" : values.gugun,
|
||||
sewerBzmnCd: values.bsnmCd,
|
||||
statsYr: values.year,
|
||||
rowDataYn: values.isDetail,
|
||||
};
|
||||
|
||||
const response = await statisticsTotalStatusApi.getSewagePipeRegionalStatusList(param);
|
||||
|
||||
if (response.status === "success" && response.data) {
|
||||
const next = new Map<string, Record<string, string | number>[]>();
|
||||
next.set("ST00020001", toGridRows(response.data as object[]));
|
||||
setRowDataMap(next);
|
||||
} else {
|
||||
alert(response.message || "데이터 조회 중 오류가 발생했습니다.");
|
||||
}
|
||||
} catch {
|
||||
alert("데이터 조회 중 오류가 발생했습니다.");
|
||||
} finally {
|
||||
setIsLoading(false);
|
||||
}
|
||||
};
|
||||
|
||||
return (
|
||||
<>
|
||||
<SearchForm />
|
||||
</>
|
||||
<div className="relative">
|
||||
<SearchForm isDetail={true} onSubmit={handleSearch} onReset={handleReset} />
|
||||
{isLoading && (
|
||||
<div className="absolute inset-0 z-50 [data-theme='black']:bg-transparent rounded-lg p-10 flex justify-center items-center">
|
||||
<div className="relative size-[5rem]">
|
||||
<LoadingWithAnimation color="primary" />
|
||||
</div>
|
||||
</div>
|
||||
)}
|
||||
<TabDataGrid
|
||||
columnInfo={columnInfo}
|
||||
isExcelImport={false}
|
||||
rowDataMap={rowDataMap}
|
||||
setRowDataMap={setRowDataMap}
|
||||
activeTab={activeTab}
|
||||
onActiveTabChange={setActiveTab}
|
||||
cellStyleCallback={({ row }) => {
|
||||
const rowType = String(row.rowType ?? "");
|
||||
if (rowType === "DETAIL") return undefined;
|
||||
if (rowType === "BIZ_SUM") return "rg-cell-rowtype-biz-sum";
|
||||
return "rg-cell-rowtype-other";
|
||||
}}
|
||||
/>
|
||||
</div>
|
||||
);
|
||||
};
|
||||
|
||||
export default SewagePipeTot;
|
||||
export default SewagePipeTot;
|
||||
|
||||
@@ -1,5 +1,7 @@
|
||||
import React from "react";
|
||||
|
||||
import { ValueType } from "realgrid";
|
||||
|
||||
import { type SewerageSupplyRateStatusInfo } from "@/entities/statistics/model/input/statistics-sewage-supply-rate-input-interface";
|
||||
|
||||
// RealGrid 타입 정의
|
||||
@@ -287,6 +289,8 @@ export type TabDataGridProps = {
|
||||
enableSort?: boolean;
|
||||
/** 분할 탭 상단 시설 조회 다이얼로그용 — 상위 화면 검색의 통계연도(searchParam.statsYr) */
|
||||
facilitySearchStatsYr?: string | null;
|
||||
/** 일반 탭 그리드(비분할) 셀 styleName — DataGrid의 cellStyleCallback과 동일 */
|
||||
cellStyleCallback?: CellStyleCallback;
|
||||
};
|
||||
|
||||
export type SplitDataGridProps = {
|
||||
|
||||
+35
-33
@@ -1,52 +1,54 @@
|
||||
import { footerInt, footerDecimal1, footerDecimal2 } from "@/components/util/grid/footerSummary";
|
||||
import { ValueType } from "realgrid";
|
||||
|
||||
import { footerDecimal1, footerDecimal2,footerInt } from "@/components/util/grid/footerSummary";
|
||||
|
||||
// 하수도 통계 관리 > 03.하수관로 유지관리 > tab 2. 관로준설
|
||||
export const PipeDredgingStatusInpColumn = {
|
||||
columns: [
|
||||
// 행정구역
|
||||
{ name: 'SIDO', fieldName: '시도', header: { text: '시도' }, editable: false },
|
||||
{ name: 'GUGUN', fieldName: '시군구', header: { text: '시군구' }, editable: false, footer: { text: '합계' } },
|
||||
{ name: 'admdstCd', fieldName: 'admdstCd', header: { text: '행정구역코드' }, editable: false },
|
||||
{ name: 'sggNm', fieldName: 'sggNm', header: { text: '시군구명' }, editable: false, footer: { text: '합계' } },
|
||||
{ name: 'admdstNm', fieldName: 'admdstNm', header: { text: '행정구역명' }, editable: false },
|
||||
|
||||
// 하수관로 총 시설연장
|
||||
{ name: 'PIPL_FCLTY_EXTN', fieldName: '하수관로총시설연장(m)', header: { text: '하수관로총시설연장(m)' }, editable: false, footer: footerDecimal2, valueType: ValueType.NUMBER, dataFormat: '#,##0.00' },
|
||||
{ name: 'wholFcltPrlg', fieldName: 'wholFcltPrlg', header: { text: '하수관로총시설연장(m)' }, editable: false, footer: footerDecimal2, valueType: ValueType.NUMBER, dataFormat: '#,##0.00' },
|
||||
|
||||
// 준설연장 및 개소수 > 관로(m)
|
||||
{ name: 'DRDG_PIPE_SM', fieldName: '합계', header: { text: '합계' }, editable: false, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
{ name: 'DRDG_CMBN_PIPE', fieldName: '합류식', header: { text: '합류식' }, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
{ name: 'wholSwagePpl', fieldName: 'wholSwagePpl', header: { text: '합계' }, editable: false, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
{ name: 'cbsysPplPrlg', fieldName: 'cbsysPplPrlg', header: { text: '합류식' }, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
|
||||
// 준설연장 및 개소수 > 관로(m) > 분류식
|
||||
{ name: 'DRDG_RAINWTR_PIPE', fieldName: '우수', header: { text: '우수' }, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
{ name: 'DRDG_PLTWTR_PIPE', fieldName: '오수', header: { text: '오수' }, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
{ name: 'sprsysExlnPrlg', fieldName: 'sprsysExlnPrlg', header: { text: '우수' }, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
{ name: 'sprsysDrtwPrlg', fieldName: 'sprsysDrtwPrlg', header: { text: '오수' }, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
|
||||
// 준설연장 및 개소수 > 맨홀, 오·우수받이, 토실·토구
|
||||
{ name: 'MNHLE_SITE', fieldName: '맨홀(개소)', header: { text: '맨홀(개소)' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
{ name: 'PLTWTR_RCVR_SITE', fieldName: '오·우수받이(개소)', header: { text: '오·우수받이(개소)' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
{ name: 'SOILSPLL_SOILHOLE_SITE', fieldName: '토실·토구(개소)', header: { text: '토실·토구(개소)' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
{ name: 'mnhlCnt', fieldName: 'mnhlCnt', header: { text: '맨홀(개소)' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
{ name: 'exlnDrtwRcvprpCnt', fieldName: 'exlnDrtwRcvprpCnt', header: { text: '오·우수받이(개소)' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
{ name: 'stofcbrOtflCnt', fieldName: 'stofcbrOtflCnt', header: { text: '토실·토구(개소)' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
|
||||
// 계획 & 비율
|
||||
{ name: 'DRDG_TRGET_EXTN', fieldName: '준설 계획 연장(m)', header: { text: '준설 계획 연장(m)' }, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
{ name: 'DRDG_TRGET_RT', fieldName: '계획대비 준설율(%)', header: { text: '계획대비 준설율(%)' }, editable: false, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
{ name: 'PIPL_FCLTY_RT', fieldName: '총시설연장대비 준설율(%)', header: { text: '총시설연장대비 준설율(%)' }, editable: false, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
{ name: 'drdgnPlanPrlg', fieldName: 'drdgnPlanPrlg', header: { text: '준설 계획 연장(m)' }, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
{ name: 'drdgnTrgtCtrsDrdgnRt', fieldName: 'drdgnTrgtCtrsDrdgnRt', header: { text: '계획대비 준설율(%)' }, editable: false, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
{ name: 'wholPrlgCtrsDrdgnRt', fieldName: 'wholPrlgCtrsDrdgnRt', header: { text: '총시설연장대비 준설율(%)' }, editable: false, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
|
||||
// 준설실적
|
||||
{ name: 'DRDG_ACMSLT_AMOUNT', fieldName: '금액(백만원)', header: { text: '금액(백만원)' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
{ name: 'DRDG_ACMSLT_QY', fieldName: '준설량(m³)', header: { text: '준설량(m³)' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
{ name: 'drdgnAmt', fieldName: 'drdgnAmt', header: { text: '금액(백만원)' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
{ name: 'drdgnQnt', fieldName: 'drdgnQnt', header: { text: '준설량(m³)' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
|
||||
// 준설토사처리
|
||||
{ name: 'DRDG_ACMSLT_UNTPC', fieldName: '준설토처리비(백만원)', header: { text: '준설토처리비(백만원)' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
{ name: 'DRDG_ETND_SM', fieldName: '처리량 계(톤)', header: { text: '처리량 계(톤)' }, editable: false, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
{ name: 'RCLM', fieldName: '매립', header: { text: '매립' }, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
{ name: 'OCEAN_DPSL', fieldName: '해양투기', header: { text: '해양투기' }, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
{ name: 'RUSE', fieldName: '재활용', header: { text: '재활용' }, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
{ name: 'ETC', fieldName: '기타(소각, 고형화, 시멘트원료 등)', header: { text: '기타(소각, 고형화, 시멘트원료 등)' }, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
{ name: 'drdgnUntprcAmt', fieldName: 'drdgnUntprcAmt', header: { text: '준설토처리비(백만원)' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
{ name: 'wholDrdgnPrcsQnt', fieldName: 'wholDrdgnPrcsQnt', header: { text: '처리량 계(톤)' }, editable: false, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
{ name: 'rclmQnt', fieldName: 'rclmQnt', header: { text: '매립' }, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
{ name: 'oceanEmsnQnt', fieldName: 'oceanEmsnQnt', header: { text: '해양투기' }, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
{ name: 'rcycQnt', fieldName: 'rcycQnt', header: { text: '재활용' }, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
{ name: 'etcQnt', fieldName: 'etcQnt', header: { text: '기타(소각, 고형화, 시멘트원료 등)' }, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
|
||||
// 비고
|
||||
{ name: 'RMK', fieldName: '비고', header: { text: '비고' } },
|
||||
{ name: 'rmrk', fieldName: 'rmrk', header: { text: '비고' } },
|
||||
],
|
||||
columnLayout: [
|
||||
{ name: 'group_admin', header: { text: '행정구역' }, items: ['SIDO', 'GUGUN'] },
|
||||
'PIPL_FCLTY_EXTN',
|
||||
{ name: 'group_admin', header: { text: '행정구역' }, items: ['admdstCd', 'sggNm', 'admdstNm'] },
|
||||
'wholFcltPrlg',
|
||||
{
|
||||
name: 'group_dredge_info',
|
||||
header: { text: '준설연장 및 개소수' },
|
||||
@@ -55,28 +57,28 @@ export const PipeDredgingStatusInpColumn = {
|
||||
name: 'group_pipe',
|
||||
header: { text: '관로(m)' },
|
||||
items: [
|
||||
'DRDG_PIPE_SM', 'DRDG_CMBN_PIPE',
|
||||
{ name: 'group_sep', header: { text: '분류식' }, items: ['DRDG_RAINWTR_PIPE', 'DRDG_PLTWTR_PIPE'] }
|
||||
'wholSwagePpl', 'cbsysPplPrlg',
|
||||
{ name: 'group_sep', header: { text: '분류식' }, items: ['sprsysExlnPrlg', 'sprsysDrtwPrlg'] }
|
||||
]
|
||||
},
|
||||
'MNHLE_SITE', 'PLTWTR_RCVR_SITE', 'SOILSPLL_SOILHOLE_SITE'
|
||||
'mnhlCnt', 'exlnDrtwRcvprpCnt', 'stofcbrOtflCnt'
|
||||
]
|
||||
},
|
||||
'DRDG_TRGET_EXTN', 'DRDG_TRGET_RT', 'PIPL_FCLTY_RT',
|
||||
'drdgnPlanPrlg', 'drdgnTrgtCtrsDrdgnRt', 'wholPrlgCtrsDrdgnRt',
|
||||
{
|
||||
name: 'group_perf',
|
||||
header: { text: '준설실적' },
|
||||
items: ['DRDG_ACMSLT_AMOUNT', 'DRDG_ACMSLT_QY']
|
||||
items: ['drdgnAmt', 'drdgnQnt']
|
||||
},
|
||||
{
|
||||
name: 'group_soil_treat',
|
||||
header: { text: '준설토사처리' },
|
||||
items: ['DRDG_ACMSLT_UNTPC', 'DRDG_ETND_SM', 'RCLM', 'OCEAN_DPSL', 'RUSE', 'ETC']
|
||||
items: ['drdgnUntprcAmt', 'wholDrdgnPrcsQnt', 'rclmQnt', 'oceanEmsnQnt', 'rcycQnt', 'etcQnt']
|
||||
},
|
||||
'RMK'
|
||||
'rmrk'
|
||||
],
|
||||
rowStartNum: 4,
|
||||
fixedColumns: 1,
|
||||
tabKey: 'pipeDredgingStatusInp',
|
||||
tabKey: 'ST00030002',
|
||||
tabLabel: '관로준설'
|
||||
};
|
||||
+34
-33
@@ -5,51 +5,52 @@ import { ValueType } from "realgrid";
|
||||
export const RepairStatusInpColumn = {
|
||||
columns: [
|
||||
// 행정구역
|
||||
{ name: 'SIDO', fieldName: '시도', header: { text: '시도' }, editable: false },
|
||||
{ name: 'GUGUN', fieldName: '시군구', header: { text: '시군구' }, editable: false, footer: { text: '합계' } },
|
||||
{ name: 'admdstCd', fieldName: 'admdstCd', header: { text: '행정구역코드' }, editable: false },
|
||||
{ name: 'sggNm', fieldName: 'sggNm', header: { text: '시군구명' }, editable: false, footer: { text: '합계' } },
|
||||
{ name: 'admdstNm', fieldName: 'admdstNm', header: { text: '행정구역명' }, editable: false },
|
||||
|
||||
// 개·보수관로 > 전체보수(m)
|
||||
{ name: 'RPAIR_PIPE_SM', fieldName: '소계', header: { text: '소계' }, editable: false, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
{ name: 'RPAIR_CMBN_PIPE', fieldName: '합류식', header: { text: '합류식' }, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
{ name: 'mendngWhol', fieldName: 'mendngWhol', header: { text: '소계' }, editable: false, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
{ name: 'cbsysMendngPrlg', fieldName: 'cbsysMendngPrlg', header: { text: '합류식' }, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
|
||||
// 개·보수관로 > 전체보수(m) > 분류식
|
||||
{ name: 'RPAIR_RAINWTR_PIPE', fieldName: '우수', header: { text: '우수' }, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
{ name: 'RPAIR_PLTWTR_PIPE', fieldName: '오수', header: { text: '오수' }, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
{ name: 'sprsysExlnPrlg', fieldName: 'sprsysExlnPrlg', header: { text: '우수' }, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
{ name: 'sprsysDrtwPrlg', fieldName: 'sprsysDrtwPrlg', header: { text: '오수' }, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
|
||||
// 개·보수관로 > 부분보수(개소)
|
||||
{ name: 'RPAIR_PIPE_SM2', fieldName: '소계', header: { text: '소계' }, editable: false, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
{ name: 'RPAIR_CMBN_PIPE2', fieldName: '합류식', header: { text: '합류식' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
{ name: 'partMendngWhol', fieldName: 'partMendngWhol', header: { text: '소계' }, editable: false, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
{ name: 'cbsysPartMendngPrlg', fieldName: 'cbsysPartMendngPrlg', header: { text: '합류식' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
|
||||
// 개·보수관로 > 부분보수(개소) > 분류식
|
||||
{ name: 'RPAIR_RAINWTR_PIPE2', fieldName: '우수', header: { text: '우수' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
{ name: 'RPAIR_PLTWTR_PIPE2', fieldName: '오수', header: { text: '오수' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
{ name: 'sprsysExlnMendngPrlg', fieldName: 'sprsysExlnMendngPrlg', header: { text: '우수' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
{ name: 'sprsysDrtwMendngPrlg', fieldName: 'sprsysDrtwMendngPrlg', header: { text: '오수' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
|
||||
// 맨홀(개소)
|
||||
{ name: 'MNHLE_SITE', fieldName: '합류식맨홀', header: { text: '합류식맨홀' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
{ name: 'cbsysMnhlCnt', fieldName: 'cbsysMnhlCnt', header: { text: '합류식맨홀' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
|
||||
// 맨홀(개소) > 분류식
|
||||
{ name: 'PLTWTR_MNHLE_SITE', fieldName: '오수맨홀', header: { text: '오수맨홀' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
{ name: 'RAINWTR_MNHLE_SITE', fieldName: '우수맨홀', header: { text: '우수맨홀' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
{ name: 'sprsysDrtwMnhlCnt', fieldName: 'sprsysDrtwMnhlCnt', header: { text: '오수맨홀' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
{ name: 'sprsysExlnMnhlCnt', fieldName: 'sprsysExlnMnhlCnt', header: { text: '우수맨홀' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
|
||||
// 받이
|
||||
{ name: 'PLTWTR_RCVR_SITE', fieldName: '오수받이(개소)', header: { text: '오수받이(개소)' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
{ name: 'RAINWTR_RCVR_SITE', fieldName: '빗물받이(개소)', header: { text: '빗물받이(개소)' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
{ name: 'drtwRcvprpCnt', fieldName: 'drtwRcvprpCnt', header: { text: '오수받이(개소)' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
{ name: 'exlnRcvprpCnt', fieldName: 'exlnRcvprpCnt', header: { text: '빗물받이(개소)' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
|
||||
// 토실, 토구
|
||||
{ name: 'SOILSPLL_SITE', fieldName: '토실(개소)', header: { text: '토실(개소)' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
{ name: 'SOILHOLE_SITE', fieldName: '토구(개소)', header: { text: '토구(개소)' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
{ name: 'stofcbrCnt', fieldName: 'stofcbrCnt', header: { text: '토실(개소)' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
{ name: 'otflCnt', fieldName: 'otflCnt', header: { text: '토구(개소)' }, footer: footerInt, valueType: ValueType.NUMBER, dataFormat: '#,##0' },
|
||||
|
||||
// 수밀검사CCTV조사량(m)
|
||||
{ name: 'CCTV', fieldName: '수밀검사CCTV조사량(m)', header: { text: '수밀검사CCTV조사량(m)' }, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
{ name: 'cctvExmnPrlg', fieldName: 'cctvExmnPrlg', header: { text: '수밀검사·CCTV조사량(m)' }, footer: footerDecimal1, valueType: ValueType.NUMBER, dataFormat: '#,##0.0' },
|
||||
|
||||
// 비고
|
||||
{ name: 'RMK', fieldName: '비고', header: { text: '비고' } },
|
||||
{ name: 'rmrk', fieldName: 'rmrk', header: { text: '비고' } },
|
||||
],
|
||||
columnLayout: [
|
||||
{
|
||||
name: 'group_admin',
|
||||
header: { text: '행정구역' },
|
||||
items: ['SIDO', 'GUGUN']
|
||||
items: ['admdstCd', 'sggNm', 'admdstNm']
|
||||
},
|
||||
{
|
||||
name: 'group_repair_main',
|
||||
@@ -59,12 +60,12 @@ export const RepairStatusInpColumn = {
|
||||
name: 'group_full_repair',
|
||||
header: { text: '전체보수(m)' },
|
||||
items: [
|
||||
'RPAIR_PIPE_SM',
|
||||
'RPAIR_CMBN_PIPE',
|
||||
'mendngWhol',
|
||||
'cbsysMendngPrlg',
|
||||
{
|
||||
name: 'group_full_sep',
|
||||
header: { text: '분류식' },
|
||||
items: ['RPAIR_RAINWTR_PIPE', 'RPAIR_PLTWTR_PIPE']
|
||||
items: ['sprsysExlnPrlg', 'sprsysDrtwPrlg']
|
||||
}
|
||||
]
|
||||
},
|
||||
@@ -72,12 +73,12 @@ export const RepairStatusInpColumn = {
|
||||
name: 'group_part_repair',
|
||||
header: { text: '부분보수(개소)' },
|
||||
items: [
|
||||
'RPAIR_PIPE_SM2',
|
||||
'RPAIR_CMBN_PIPE2',
|
||||
'partMendngWhol',
|
||||
'cbsysPartMendngPrlg',
|
||||
{
|
||||
name: 'group_part_sep',
|
||||
header: { text: '분류식' },
|
||||
items: ['RPAIR_RAINWTR_PIPE2', 'RPAIR_PLTWTR_PIPE2']
|
||||
items: ['sprsysExlnMendngPrlg', 'sprsysDrtwMendngPrlg']
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -87,29 +88,29 @@ export const RepairStatusInpColumn = {
|
||||
name: 'group_manhole',
|
||||
header: { text: '맨홀(개소)' },
|
||||
items: [
|
||||
'MNHLE_SITE',
|
||||
'cbsysMnhlCnt',
|
||||
{
|
||||
name: 'group_mh_sep',
|
||||
header: { text: '분류식' },
|
||||
items: ['PLTWTR_MNHLE_SITE', 'RAINWTR_MNHLE_SITE']
|
||||
items: ['sprsysDrtwMnhlCnt', 'sprsysExlnMnhlCnt']
|
||||
}
|
||||
]
|
||||
},
|
||||
{
|
||||
name: 'group_inlet',
|
||||
header: { text: '받이' },
|
||||
items: ['PLTWTR_RCVR_SITE', 'RAINWTR_RCVR_SITE']
|
||||
items: ['drtwRcvprpCnt', 'exlnRcvprpCnt']
|
||||
},
|
||||
{
|
||||
name: 'group_chamber',
|
||||
header: { text: '토실,토구' },
|
||||
items: ['SOILSPLL_SITE', 'SOILHOLE_SITE']
|
||||
items: ['stofcbrCnt', 'otflCnt']
|
||||
},
|
||||
'CCTV',
|
||||
'RMK'
|
||||
'cctvExmnPrlg',
|
||||
'rmrk'
|
||||
],
|
||||
rowStartNum: 4,
|
||||
fixedColumns: 1,
|
||||
tabKey: 'repairStatusInp',
|
||||
tabKey: 'ST00030001',
|
||||
tabLabel: '개보수'
|
||||
};
|
||||
@@ -6,7 +6,7 @@ export const LogHistoryColumn = {
|
||||
{ name: 'menuNm', fieldName: 'menuNm', header: { text: '메뉴명' }, editable: false },
|
||||
{ name: 'tblNm', fieldName: 'tblNm', header: { text: '테이블명' }, visible: false, editable: false },
|
||||
{ name: 'dmndFwkNm', fieldName: 'dmndFwkNm', header: { text: '요청 기능명' }, editable: false },
|
||||
{ name: 'rgtrId', fieldName: 'rgtrId', header: { text: '등록자' }, editable: false },
|
||||
{ name: 'rgtrId', fieldName: 'rgtrId', header: { text: '등록자' }, editable: false, visible: false },
|
||||
{ name: 'regDt', fieldName: 'regDt', header: { text: '등록일' }, editable: false },
|
||||
],
|
||||
|
||||
|
||||
@@ -1,7 +1,13 @@
|
||||
import { ValueType } from "realgrid";
|
||||
import dayjs from 'dayjs';
|
||||
import { footerIntArrayByDivision, footerDecimal3ArrayByDivision, footerAvgDecimalArrayByDivision } from "@/components/util/grid/footerSummary";
|
||||
import { ValueType } from "realgrid";
|
||||
|
||||
import type { GridView } from "@/components/type/DataGrid.type";
|
||||
import {
|
||||
footerAvgDecimalArrayByDivision,
|
||||
footerDecimal1ArrayByDivision,
|
||||
footerDecimal3ArrayByDivision,
|
||||
footerIntArrayByDivision,
|
||||
} from "@/components/util/grid/footerSummary";
|
||||
|
||||
|
||||
const currentYear = dayjs().year() - 1;
|
||||
@@ -258,7 +264,7 @@ const rawList = [
|
||||
{ name: 'prcsZoneArea', fieldName: 'prcsZoneArea', header: { text: '합계' }, footer: footerDecimal3ArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.000' },
|
||||
{ name: 'cbsysPrcsZoneArea', fieldName: 'cbsysPrcsZoneArea', header: { text: '합류식' }, footer: footerDecimal3ArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.000' },
|
||||
{ name: 'sprsysPrcsZoneArea', fieldName: 'sprsysPrcsZoneArea', header: { text: '분류식' }, footer: footerDecimal3ArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.000' },
|
||||
{ name: 'sprsysVartnRt', fieldName: 'sprsysVartnRt', header: { text: '분류식화' }, footer: footerDecimal3ArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.000' },
|
||||
{ name: 'sprsysVartnRt', fieldName: 'sprsysVartnRt', header: { text: '분류식화율' }, footer: footerDecimal3ArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.000' },
|
||||
{ name: 'mltvEqpmCnt', fieldName: 'mltvEqpmCnt', header: { text: '합계' }, footer: footerIntArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0' },
|
||||
{ name: 'cbsysMltvEqpmCnt', fieldName: 'cbsysMltvEqpmCnt', header: { text: '합류식' }, footer: footerIntArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0' },
|
||||
{ name: 'sprsysMltvEqpmCnt', fieldName: 'sprsysMltvEqpmCnt', header: { text: '분류식 합계' }, footer: footerIntArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0' },
|
||||
@@ -386,9 +392,9 @@ const rawList = [
|
||||
]
|
||||
},
|
||||
|
||||
{ name: 'pipeByPrstWholSum', fieldName: 'pipeByPrstWhol', header: { text: '계' }, footer: footerAvgDecimalArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.0' },
|
||||
{ name: 'lyngPrlgSum', fieldName: 'lyngPrlg', header: { text: '매설연장(m)' }, footer: footerAvgDecimalArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.0' },
|
||||
{ name: 'dmltnPrlgSum', fieldName: 'dmltnPrlg', header: { text: '철거연장(m)' }, footer: footerAvgDecimalArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.0' },
|
||||
{ name: 'pipeByPrstWhol', fieldName: 'pipeByPrstWhol', header: { text: '계' }, footer: footerDecimal1ArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.0' },
|
||||
{ name: 'lyngPrlg', fieldName: 'lyngPrlg', header: { text: '매설연장(m)' }, footer: footerDecimal1ArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.0' },
|
||||
{ name: 'dmltnPrlg', fieldName: 'dmltnPrlg', header: { text: '철거연장(m)' }, footer: footerDecimal1ArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.0' },
|
||||
|
||||
|
||||
...Array.from({ length: totalCount }, (_, i) => {
|
||||
@@ -399,38 +405,38 @@ const rawList = [
|
||||
const dmltnField = `yy${dtoNum}DmltnPrlg`;
|
||||
|
||||
return [
|
||||
{ name: wholField, fieldName: wholField, header: { text: '계' }, footer: footerAvgDecimalArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.0' },
|
||||
{ name: lyngField, fieldName: lyngField, header: { text: '매설연장(m)' }, footer: footerAvgDecimalArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.0' },
|
||||
{ name: dmltnField, fieldName: dmltnField, header: { text: '철거연장(m)' }, footer: footerAvgDecimalArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.0' }
|
||||
{ name: wholField, fieldName: wholField, header: { text: '계' }, footer: footerDecimal1ArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.0' },
|
||||
{ name: lyngField, fieldName: lyngField, header: { text: '매설연장(m)' }, footer: footerDecimal1ArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.0' },
|
||||
{ name: dmltnField, fieldName: dmltnField, header: { text: '철거연장(m)' }, footer: footerDecimal1ArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.0' }
|
||||
];
|
||||
}).flat(),
|
||||
|
||||
{ name: 'rmrk', fieldName: 'rmrk', header: { text: '비고' } },
|
||||
], columnLayout: [
|
||||
{
|
||||
name: 'areaGroup',
|
||||
header: { text: '행정구역' },
|
||||
items: [{ column: 'ctpvNm', footerUserSpans: [{ colspan: 4 }, { colspan: 4 }] },
|
||||
'sggNm', 'swrgPipeNm'
|
||||
] },
|
||||
'displayYear',
|
||||
{ name: 'summaryGroup', header: { text: '총계' }, items: ['pipeByPrstWholSum', 'lyngPrlgSum', 'dmltnPrlgSum'] },
|
||||
{
|
||||
name: "areaGroup",
|
||||
header: { text: "행정구역" },
|
||||
items: [
|
||||
{ column: "ctpvNm", footerUserSpans: [{ colspan: 3 }, { colspan: 3 }] },
|
||||
"sggNm",
|
||||
"swrgPipeNm",
|
||||
],
|
||||
},
|
||||
"displayYear",
|
||||
{ name: "summaryGroup", header: { text: "총계" }, items: ["pipeByPrstWhol", "lyngPrlg", "dmltnPrlg"] },
|
||||
|
||||
...Array.from({ length: totalCount }, (_, i) => {
|
||||
|
||||
const dtoNum = totalCount - i;
|
||||
const yearLabel = i === 0
|
||||
? '1996년이전'
|
||||
: `${startYear + (i - 1)}년`;
|
||||
const yearLabel = i === 0 ? "1996년이전" : `${startYear + (i - 1)}년`;
|
||||
|
||||
return {
|
||||
name: `group_${yearLabel}`,
|
||||
header: { text: yearLabel },
|
||||
items: [`yy${dtoNum}PrlgWhol`, `yy${dtoNum}LyngPrlg`, `yy${dtoNum}DmltnPrlg`]
|
||||
items: [`yy${dtoNum}PrlgWhol`, `yy${dtoNum}LyngPrlg`, `yy${dtoNum}DmltnPrlg`],
|
||||
};
|
||||
}),
|
||||
'rmrk'
|
||||
]
|
||||
"rmrk",
|
||||
],
|
||||
},
|
||||
|
||||
{
|
||||
@@ -511,14 +517,14 @@ const rawList = [
|
||||
},
|
||||
|
||||
/* 관경별 수치 필드 */
|
||||
{ name: 'pdmtByTsmWhol', fieldName: 'pdmtByTsmWhol', header: { text: '총계(m)' }, footer: footerAvgDecimalArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.0' },
|
||||
{ name: 'step1PdmtPrlg', fieldName: 'step1PdmtPrlg', header: { text: '200mm 미만' }, footer: footerAvgDecimalArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.0' },
|
||||
{ name: 'step2PdmtPrlg', fieldName: 'step2PdmtPrlg', header: { text: '200mm이상~\n300mm미만' }, footer: footerAvgDecimalArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.0' },
|
||||
{ name: 'step3PdmtPrlg', fieldName: 'step3PdmtPrlg', header: { text: '300mm이상~\n500mm미만' }, footer: footerAvgDecimalArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.0' },
|
||||
{ name: 'step4PdmtPrlg', fieldName: 'step4PdmtPrlg', header: { text: '500mm이상~\n800mm미만' }, footer: footerAvgDecimalArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.0' },
|
||||
{ name: 'step5PdmtPrlg', fieldName: 'step5PdmtPrlg', header: { text: '800mm 이상' }, footer: footerAvgDecimalArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.0' },
|
||||
{ name: 'sqrePdmtPrlg', fieldName: 'sqrePdmtPrlg', header: { text: '사각형(m)' }, footer: footerAvgDecimalArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.0' },
|
||||
{ name: 'etcPdmtPrlg', fieldName: 'etcPdmtPrlg', header: { text: '기타\n(측구/개거 등)' }, footer: footerAvgDecimalArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.0' },
|
||||
{ name: 'pdmtByTsmWhol', fieldName: 'pdmtByTsmWhol', header: { text: '총계(m)' }, footer: footerDecimal1ArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.0' },
|
||||
{ name: 'step1PdmtPrlg', fieldName: 'step1PdmtPrlg', header: { text: '200mm 미만' }, footer: footerDecimal1ArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.0' },
|
||||
{ name: 'step2PdmtPrlg', fieldName: 'step2PdmtPrlg', header: { text: '200mm이상~\n300mm미만' }, footer: footerDecimal1ArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.0' },
|
||||
{ name: 'step3PdmtPrlg', fieldName: 'step3PdmtPrlg', header: { text: '300mm이상~\n500mm미만' }, footer: footerDecimal1ArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.0' },
|
||||
{ name: 'step4PdmtPrlg', fieldName: 'step4PdmtPrlg', header: { text: '500mm이상~\n800mm미만' }, footer: footerDecimal1ArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.0' },
|
||||
{ name: 'step5PdmtPrlg', fieldName: 'step5PdmtPrlg', header: { text: '800mm 이상' }, footer: footerDecimal1ArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.0' },
|
||||
{ name: 'sqrePdmtPrlg', fieldName: 'sqrePdmtPrlg', header: { text: '사각형(m)' }, footer: footerDecimal1ArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.0' },
|
||||
{ name: 'etcPdmtPrlg', fieldName: 'etcPdmtPrlg', header: { text: '기타\n(측구/개거 등)' }, footer: footerDecimal1ArrayByDivision, valueType: ValueType.NUMBER, numberFormat: '#,##0.0' },
|
||||
|
||||
{ name: 'rmrk', fieldName: 'rmrk', header: { text: '비고' } }, // rmk -> rmrk
|
||||
],
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
import { ValueType } from "realgrid";
|
||||
import {
|
||||
footerIntArrayByDivision,
|
||||
footerDecimal1ArrayByDivision,
|
||||
footerDecimal3ArrayByDivision
|
||||
import {
|
||||
footerIntArrayByDivision,
|
||||
footerDecimal1ArrayByDivision,
|
||||
footerDecimal3ArrayByDivision
|
||||
} from "@/components/util/grid/footerSummary";
|
||||
import type { GridView } from "@/components/type/DataGrid.type";
|
||||
|
||||
@@ -56,10 +56,9 @@ const rawReservoirList = [
|
||||
}
|
||||
]
|
||||
},
|
||||
{ name: 'sggNm', fieldName: 'sggNm', header: { text: '시군구' }, mergeCells: true, sortdisable: true },
|
||||
{ name: 'admdstNm', fieldName: 'admdstNm', header: { text: '행정구역명' }, mergeCells: true },
|
||||
{ name: 'impdFcltNm', fieldName: 'impdFcltNm', header: { text: '저류시설명' }, mergeCells: true, sortdisable: true },
|
||||
{ name: 'impdFcltPstnCn', fieldName: 'impdFcltPstnCn', header: { text: '저류시설위치' }, mergeCells: true, sortdisable: true },
|
||||
{ name: 'sggNm', fieldName: 'sggNm', header: { text: '시군구' }, mergeCells: true, sortdisable: true },
|
||||
{ name: 'fcltNm', fieldName: 'fcltNm', header: { text: '저류시설명' }, mergeCells: true, sortdisable: true },
|
||||
{ name: 'fcltPstnCn', fieldName: 'fcltPstnCn', header: { text: '저류시설위치' }, mergeCells: true, sortdisable: true },
|
||||
{
|
||||
name: 'displayYear',
|
||||
fieldName: 'displayYear',
|
||||
@@ -101,7 +100,7 @@ const rawReservoirList = [
|
||||
]
|
||||
},
|
||||
|
||||
/* 2. 시설 제원 */
|
||||
/* 2. 시설 제원 */
|
||||
{ name: 'oprtngStrtYmd', fieldName: 'oprtngStrtYmd', header: { text: '가동개시 년월일' } },
|
||||
{ name: 'planDesignFreqCnt', fieldName: 'planDesignFreqCnt', header: { text: '계획설계빈도' } },
|
||||
{ name: 'fldngPrvtnYn', fieldName: 'fldngPrvtnYn', header: { text: '침수예방' } },
|
||||
@@ -117,12 +116,12 @@ const rawReservoirList = [
|
||||
{ name: 'pumpFcltN1PerPpqty', fieldName: 'pumpFcltN1PerPpqty', header: { text: '대당 양수량' }, valueType: ValueType.NUMBER, numberFormat: '#,##0.0', footer: footerDecimal1ArrayByDivision },
|
||||
{ name: 'pumpFcltN1PumpCnt', fieldName: 'pumpFcltN1PumpCnt', header: { text: '펌프대수' }, valueType: ValueType.NUMBER, numberFormat: '#,##0', footer: footerIntArrayByDivision },
|
||||
{ name: 'pumpFcltN1RsrvPumpCnt', fieldName: 'pumpFcltN1RsrvPumpCnt', header: { text: '예비펌프대수' }, valueType: ValueType.NUMBER, numberFormat: '#,##0', footer: footerIntArrayByDivision },
|
||||
|
||||
|
||||
{ name: 'pumpFcltN2DmtrExpln', fieldName: 'pumpFcltN2DmtrExpln', header: { text: '구경(mm)' } },
|
||||
{ name: 'pumpFcltN2PerPpqty', fieldName: 'pumpFcltN2PerPpqty', header: { text: '대당 양수량' }, valueType: ValueType.NUMBER, numberFormat: '#,##0.0', footer: footerDecimal1ArrayByDivision },
|
||||
{ name: 'pumpFcltN2PumpCnt', fieldName: 'pumpFcltN2PumpCnt', header: { text: '펌프대수' }, valueType: ValueType.NUMBER, numberFormat: '#,##0', footer: footerIntArrayByDivision },
|
||||
{ name: 'pumpFcltN2RsrvPumpCnt', fieldName: 'pumpFcltN2RsrvPumpCnt', header: { text: '예비펌프대수' }, valueType: ValueType.NUMBER, numberFormat: '#,##0', footer: footerIntArrayByDivision },
|
||||
|
||||
|
||||
{ name: 'pumpFcltN3DmtrExpln', fieldName: 'pumpFcltN3DmtrExpln', header: { text: '구경(mm)' } },
|
||||
{ name: 'pumpFcltN3PerPpqty', fieldName: 'pumpFcltN3PerPpqty', header: { text: '대당 양수량' }, valueType: ValueType.NUMBER, numberFormat: '#,##0.0', footer: footerDecimal1ArrayByDivision },
|
||||
{ name: 'pumpFcltN3PumpCnt', fieldName: 'pumpFcltN3PumpCnt', header: { text: '펌프대수' }, valueType: ValueType.NUMBER, numberFormat: '#,##0', footer: footerIntArrayByDivision },
|
||||
@@ -151,11 +150,11 @@ const rawReservoirList = [
|
||||
columnLayout: [
|
||||
{
|
||||
name: 'areaGroup', header: { text: '행정구역' }, items: [
|
||||
{ column: 'ctpvNm', footerUserSpans: [{ colspan: 4 }, { colspan: 4 }] },
|
||||
'sggNm','admdstNm'
|
||||
{ column: 'ctpvNm', footerUserSpans: [{ colspan: 5 }, { colspan: 5 }] },
|
||||
'sggNm'
|
||||
]
|
||||
},
|
||||
'impdFcltNm', 'impdFcltPstnCn','displayYear', 'oprtngStrtYmd', 'planDesignFreqCnt',
|
||||
'fcltNm', 'fcltPstnCn', 'displayYear', 'oprtngStrtYmd', 'planDesignFreqCnt',
|
||||
{ name: 'purposeGroup', header: { text: '설치목적' }, items: ['fldngPrvtnYn', 'wqPlltnMtgtYn', 'rtlztnUsgYn'] },
|
||||
'fcltStrctCn', 'wtrStrgZoneArea', 'impdFcltCpct',
|
||||
{
|
||||
@@ -175,167 +174,166 @@ const rawReservoirList = [
|
||||
'rmrk'
|
||||
]
|
||||
},
|
||||
{
|
||||
{
|
||||
tabKey: 'ST00040002',
|
||||
tabLabel: '빗물펌프장',
|
||||
rowStartNum: 3,
|
||||
fixedColumns: 2,
|
||||
columns: [
|
||||
{
|
||||
name: 'ctpvNm',
|
||||
fieldName: 'ctpvNm',
|
||||
header: { text: '시도' },
|
||||
mergeCells: true,
|
||||
sortdisable: true,
|
||||
footer: [
|
||||
{
|
||||
valueCallback: (grid: GridView) => {
|
||||
const divisionIndex = 0;
|
||||
const dataSource = grid.getDataSource();
|
||||
const rowCount = dataSource.getRowCount();
|
||||
const uniqueValues = new Set<string>();
|
||||
for (let i = 0; i < rowCount; i++) {
|
||||
const divisionValue = dataSource.getValue(i, 'displayYear');
|
||||
if (divisionValue !== null && divisionValue !== undefined && divisionValue !== '') {
|
||||
uniqueValues.add(String(divisionValue));
|
||||
columns: [
|
||||
{
|
||||
name: 'ctpvNm',
|
||||
fieldName: 'ctpvNm',
|
||||
header: { text: '시도' },
|
||||
mergeCells: true,
|
||||
sortdisable: true,
|
||||
footer: [
|
||||
{
|
||||
valueCallback: (grid: GridView) => {
|
||||
const divisionIndex = 0;
|
||||
const dataSource = grid.getDataSource();
|
||||
const rowCount = dataSource.getRowCount();
|
||||
const uniqueValues = new Set<string>();
|
||||
for (let i = 0; i < rowCount; i++) {
|
||||
const divisionValue = dataSource.getValue(i, 'displayYear');
|
||||
if (divisionValue !== null && divisionValue !== undefined && divisionValue !== '') {
|
||||
uniqueValues.add(String(divisionValue));
|
||||
}
|
||||
}
|
||||
const divisionValues = Array.from(uniqueValues);
|
||||
if (divisionValues.length > divisionIndex) return divisionValues[divisionIndex] + ' 합계';
|
||||
return '합계';
|
||||
}
|
||||
const divisionValues = Array.from(uniqueValues);
|
||||
if (divisionValues.length > divisionIndex) return divisionValues[divisionIndex] + ' 합계';
|
||||
return '합계';
|
||||
}
|
||||
},
|
||||
{
|
||||
valueCallback: (grid: GridView) => {
|
||||
const divisionIndex = 1;
|
||||
const dataSource = grid.getDataSource();
|
||||
const rowCount = dataSource.getRowCount();
|
||||
const uniqueValues = new Set<string>();
|
||||
for (let i = 0; i < rowCount; i++) {
|
||||
const divisionValue = dataSource.getValue(i, 'displayYear');
|
||||
if (divisionValue !== null && divisionValue !== undefined && divisionValue !== '') {
|
||||
uniqueValues.add(String(divisionValue));
|
||||
},
|
||||
{
|
||||
valueCallback: (grid: GridView) => {
|
||||
const divisionIndex = 1;
|
||||
const dataSource = grid.getDataSource();
|
||||
const rowCount = dataSource.getRowCount();
|
||||
const uniqueValues = new Set<string>();
|
||||
for (let i = 0; i < rowCount; i++) {
|
||||
const divisionValue = dataSource.getValue(i, 'displayYear');
|
||||
if (divisionValue !== null && divisionValue !== undefined && divisionValue !== '') {
|
||||
uniqueValues.add(String(divisionValue));
|
||||
}
|
||||
}
|
||||
const divisionValues = Array.from(uniqueValues);
|
||||
if (divisionValues.length > divisionIndex) return divisionValues[divisionIndex] + ' 합계';
|
||||
return '합계';
|
||||
}
|
||||
const divisionValues = Array.from(uniqueValues);
|
||||
if (divisionValues.length > divisionIndex) return divisionValues[divisionIndex] + ' 합계';
|
||||
return '합계';
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
{ name: 'sggNm', fieldName: 'sggNm', header: { text: '시군구' }, mergeCells: true, sortdisable: true },
|
||||
{ name: 'admdstNm', fieldName: 'admdstNm', header: { text: '행정구역명' }, mergeCells: true },
|
||||
{ name: 'impdFcltNm', fieldName: 'impdFcltNm', header: { text: '시설명' }, mergeCells: true, sortdisable: true },
|
||||
{ name: 'impdFcltPstnCn',fieldName: 'impdFcltPstnCn',header: { text: '위치' }, mergeCells: true, sortdisable: true },
|
||||
{
|
||||
name: 'displayYear',
|
||||
fieldName: 'displayYear',
|
||||
header: { text: '구분' },
|
||||
sortdisable: true,
|
||||
footer: [
|
||||
{
|
||||
valueCallback: (grid: GridView) => {
|
||||
const divisionIndex = 0;
|
||||
const dataSource = grid.getDataSource();
|
||||
const rowCount = dataSource.getRowCount();
|
||||
const uniqueValues = new Set<string>();
|
||||
for (let i = 0; i < rowCount; i++) {
|
||||
const divisionValue = dataSource.getValue(i, 'displayYear');
|
||||
if (divisionValue !== null && divisionValue !== undefined && divisionValue !== '') {
|
||||
uniqueValues.add(String(divisionValue));
|
||||
]
|
||||
},
|
||||
{ name: 'sggNm', fieldName: 'sggNm', header: { text: '시군구' }, mergeCells: true, sortdisable: true },
|
||||
{ name: 'fcltNm', fieldName: 'fcltNm', header: { text: '시설명' }, mergeCells: true, sortdisable: true },
|
||||
{ name: 'fcltPstnCn', fieldName: 'fcltPstnCn', header: { text: '위치' }, mergeCells: true, sortdisable: true },
|
||||
{
|
||||
name: 'displayYear',
|
||||
fieldName: 'displayYear',
|
||||
header: { text: '구분' },
|
||||
sortdisable: true,
|
||||
footer: [
|
||||
{
|
||||
valueCallback: (grid: GridView) => {
|
||||
const divisionIndex = 0;
|
||||
const dataSource = grid.getDataSource();
|
||||
const rowCount = dataSource.getRowCount();
|
||||
const uniqueValues = new Set<string>();
|
||||
for (let i = 0; i < rowCount; i++) {
|
||||
const divisionValue = dataSource.getValue(i, 'displayYear');
|
||||
if (divisionValue !== null && divisionValue !== undefined && divisionValue !== '') {
|
||||
uniqueValues.add(String(divisionValue));
|
||||
}
|
||||
}
|
||||
const divisionValues = Array.from(uniqueValues);
|
||||
return divisionValues.length > divisionIndex ? divisionValues[divisionIndex] + ' 합계' : '';
|
||||
}
|
||||
const divisionValues = Array.from(uniqueValues);
|
||||
return divisionValues.length > divisionIndex ? divisionValues[divisionIndex] + ' 합계' : '';
|
||||
}
|
||||
},
|
||||
{
|
||||
valueCallback: (grid: GridView) => {
|
||||
const divisionIndex = 1;
|
||||
const dataSource = grid.getDataSource();
|
||||
const rowCount = dataSource.getRowCount();
|
||||
const uniqueValues = new Set<string>();
|
||||
for (let i = 0; i < rowCount; i++) {
|
||||
const divisionValue = dataSource.getValue(i, 'displayYear');
|
||||
if (divisionValue !== null && divisionValue !== undefined && divisionValue !== '') {
|
||||
uniqueValues.add(String(divisionValue));
|
||||
},
|
||||
{
|
||||
valueCallback: (grid: GridView) => {
|
||||
const divisionIndex = 1;
|
||||
const dataSource = grid.getDataSource();
|
||||
const rowCount = dataSource.getRowCount();
|
||||
const uniqueValues = new Set<string>();
|
||||
for (let i = 0; i < rowCount; i++) {
|
||||
const divisionValue = dataSource.getValue(i, 'displayYear');
|
||||
if (divisionValue !== null && divisionValue !== undefined && divisionValue !== '') {
|
||||
uniqueValues.add(String(divisionValue));
|
||||
}
|
||||
}
|
||||
const divisionValues = Array.from(uniqueValues);
|
||||
return divisionValues.length > divisionIndex ? divisionValues[divisionIndex] + ' 합계' : '';
|
||||
}
|
||||
const divisionValues = Array.from(uniqueValues);
|
||||
return divisionValues.length > divisionIndex ? divisionValues[divisionIndex] + ' 합계' : '';
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
]
|
||||
},
|
||||
|
||||
/* 2. 시설 제원 */
|
||||
{ name: 'fcltyKndCn', fieldName: 'fcltyKndCn', header: { text: '시설물종류' } },
|
||||
{ name: 'oprtngStrtYmd', fieldName: 'oprtngStrtYmd', header: { text: '가동개시 년월일' } },
|
||||
{ name: 'planDesignFreqCnt', fieldName: 'planDesignFreqCnt', header: { text: '계획설계빈도' } },
|
||||
{ name: 'wtrStrgZoneArea', fieldName: 'wtrStrgZoneArea', header: { text: '집수구역면적(㎢)' }, valueType: ValueType.NUMBER, numberFormat: '#,##0.000', footer: footerDecimal3ArrayByDivision },
|
||||
{ name: 'rsvrYn', fieldName: 'rsvrYn', header: { text: '유수지유무\n(유,무)' } },
|
||||
{ name: 'rsvrImpndQnt', fieldName: 'rsvrImpndQnt', header: { text: '저류량(㎥)' }, valueType: ValueType.NUMBER, numberFormat: '#,##0.0', footer: footerDecimal1ArrayByDivision },
|
||||
{ name: 'abstnRgnImdQnt', fieldName: 'abstnRgnImdQnt', header: { text: '저류량(㎥)' }, valueType: ValueType.NUMBER, numberFormat: '#,##0.0', footer: footerDecimal1ArrayByDivision },
|
||||
{ name: 'fcltCpct', fieldName: 'fcltCpct', header: { text: '시설용량(㎥)' }, valueType: ValueType.NUMBER, numberFormat: '#,##0.0', footer: footerDecimal1ArrayByDivision },
|
||||
/* 2. 시설 제원 */
|
||||
{ name: 'fcltyKndCn', fieldName: 'fcltyKndCn', header: { text: '시설물종류' } },
|
||||
{ name: 'oprtngStrtYmd', fieldName: 'oprtngStrtYmd', header: { text: '가동개시 년월일' } },
|
||||
{ name: 'planDesignFreqCnt', fieldName: 'planDesignFreqCnt', header: { text: '계획설계빈도' } },
|
||||
{ name: 'wtrStrgZoneArea', fieldName: 'wtrStrgZoneArea', header: { text: '집수구역면적(㎢)' }, valueType: ValueType.NUMBER, numberFormat: '#,##0.000', footer: footerDecimal3ArrayByDivision },
|
||||
{ name: 'rsvrYn', fieldName: 'rsvrYn', header: { text: '유수지유무\n(유,무)' } },
|
||||
{ name: 'rsvrImpndQnt', fieldName: 'rsvrImpndQnt', header: { text: '저류량(㎥)' }, valueType: ValueType.NUMBER, numberFormat: '#,##0.0', footer: footerDecimal1ArrayByDivision },
|
||||
{ name: 'abstnRgnImdQnt', fieldName: 'abstnRgnImdQnt', header: { text: '저류량(㎥)' }, valueType: ValueType.NUMBER, numberFormat: '#,##0.0', footer: footerDecimal1ArrayByDivision },
|
||||
{ name: 'fcltCpct', fieldName: 'fcltCpct', header: { text: '시설용량(㎥)' }, valueType: ValueType.NUMBER, numberFormat: '#,##0.0', footer: footerDecimal1ArrayByDivision },
|
||||
|
||||
/* 3. 펌프시설 */
|
||||
{ name: 'pumpFcltN1DmtrExpln', fieldName: 'pumpFcltN1DmtrExpln', header: { text: '구경(mm)' } },
|
||||
{ name: 'pumpFcltN1PerPpqty', fieldName: 'pumpFcltN1PerPpqty', header: { text: '대당 양수량' }, valueType: ValueType.NUMBER, numberFormat: '#,##0.0', footer: footerDecimal1ArrayByDivision },
|
||||
{ name: 'pumpFcltN1PumpCnt', fieldName: 'pumpFcltN1PumpCnt', header: { text: '펌프대수' }, valueType: ValueType.NUMBER, numberFormat: '#,##0', footer: footerIntArrayByDivision },
|
||||
{ name: 'pumpFcltN1RsrvPumpCnt', fieldName: 'pumpFcltN1RsrvPumpCnt', header: { text: '예비펌프대수' }, valueType: ValueType.NUMBER, numberFormat: '#,##0', footer: footerIntArrayByDivision },
|
||||
/* 3. 펌프시설 */
|
||||
{ name: 'pumpFcltN1DmtrExpln', fieldName: 'pumpFcltN1DmtrExpln', header: { text: '구경(mm)' } },
|
||||
{ name: 'pumpFcltN1PerPpqty', fieldName: 'pumpFcltN1PerPpqty', header: { text: '대당 양수량' }, valueType: ValueType.NUMBER, numberFormat: '#,##0.0', footer: footerDecimal1ArrayByDivision },
|
||||
{ name: 'pumpFcltN1PumpCnt', fieldName: 'pumpFcltN1PumpCnt', header: { text: '펌프대수' }, valueType: ValueType.NUMBER, numberFormat: '#,##0', footer: footerIntArrayByDivision },
|
||||
{ name: 'pumpFcltN1RsrvPumpCnt', fieldName: 'pumpFcltN1RsrvPumpCnt', header: { text: '예비펌프대수' }, valueType: ValueType.NUMBER, numberFormat: '#,##0', footer: footerIntArrayByDivision },
|
||||
|
||||
{ name: 'pumpFcltN2DmtrExpln', fieldName: 'pumpFcltN2DmtrExpln', header: { text: '구경(mm)' } },
|
||||
{ name: 'pumpFcltN2PerPpqty', fieldName: 'pumpFcltN2PerPpqty', header: { text: '대당 양수량' }, valueType: ValueType.NUMBER, numberFormat: '#,##0.0', footer: footerDecimal1ArrayByDivision },
|
||||
{ name: 'pumpFcltN2PumpCnt', fieldName: 'pumpFcltN2PumpCnt', header: { text: '펌프대수' }, valueType: ValueType.NUMBER, numberFormat: '#,##0', footer: footerIntArrayByDivision },
|
||||
{ name: 'pumpFcltN2RsrvPumpCnt', fieldName: 'pumpFcltN2RsrvPumpCnt', header: { text: '예비펌프대수' }, valueType: ValueType.NUMBER, numberFormat: '#,##0', footer: footerIntArrayByDivision },
|
||||
{ name: 'pumpFcltN2DmtrExpln', fieldName: 'pumpFcltN2DmtrExpln', header: { text: '구경(mm)' } },
|
||||
{ name: 'pumpFcltN2PerPpqty', fieldName: 'pumpFcltN2PerPpqty', header: { text: '대당 양수량' }, valueType: ValueType.NUMBER, numberFormat: '#,##0.0', footer: footerDecimal1ArrayByDivision },
|
||||
{ name: 'pumpFcltN2PumpCnt', fieldName: 'pumpFcltN2PumpCnt', header: { text: '펌프대수' }, valueType: ValueType.NUMBER, numberFormat: '#,##0', footer: footerIntArrayByDivision },
|
||||
{ name: 'pumpFcltN2RsrvPumpCnt', fieldName: 'pumpFcltN2RsrvPumpCnt', header: { text: '예비펌프대수' }, valueType: ValueType.NUMBER, numberFormat: '#,##0', footer: footerIntArrayByDivision },
|
||||
|
||||
{ name: 'pumpFcltN3DmtrExpln', fieldName: 'pumpFcltN3DmtrExpln', header: { text: '구경(mm)' } },
|
||||
{ name: 'pumpFcltN3PerPpqty', fieldName: 'pumpFcltN3PerPpqty', header: { text: '대당 양수량' }, valueType: ValueType.NUMBER, numberFormat: '#,##0.0', footer: footerDecimal1ArrayByDivision },
|
||||
{ name: 'pumpFcltN3PumpCnt', fieldName: 'pumpFcltN3PumpCnt', header: { text: '펌프대수' }, valueType: ValueType.NUMBER, numberFormat: '#,##0', footer: footerIntArrayByDivision },
|
||||
{ name: 'pumpFcltN3RsrvPumpCnt', fieldName: 'pumpFcltN3RsrvPumpCnt', header: { text: '예비펌프대수' }, valueType: ValueType.NUMBER, numberFormat: '#,##0', footer: footerIntArrayByDivision },
|
||||
{ name: 'pumpFcltN3DmtrExpln', fieldName: 'pumpFcltN3DmtrExpln', header: { text: '구경(mm)' } },
|
||||
{ name: 'pumpFcltN3PerPpqty', fieldName: 'pumpFcltN3PerPpqty', header: { text: '대당 양수량' }, valueType: ValueType.NUMBER, numberFormat: '#,##0.0', footer: footerDecimal1ArrayByDivision },
|
||||
{ name: 'pumpFcltN3PumpCnt', fieldName: 'pumpFcltN3PumpCnt', header: { text: '펌프대수' }, valueType: ValueType.NUMBER, numberFormat: '#,##0', footer: footerIntArrayByDivision },
|
||||
{ name: 'pumpFcltN3RsrvPumpCnt', fieldName: 'pumpFcltN3RsrvPumpCnt', header: { text: '예비펌프대수' }, valueType: ValueType.NUMBER, numberFormat: '#,##0', footer: footerIntArrayByDivision },
|
||||
|
||||
/* 4. 부대시설 */
|
||||
{ name: 'prcsgFcltYn', fieldName: 'prcsgFcltYn', header: { text: '전처리시설' } },
|
||||
{ name: 'ddrztnEqpmYn', fieldName: 'ddrztnEqpmYn', header: { text: '탈취설비' } },
|
||||
{ name: 'oslfEtgtYn', fieldName: 'oslfEtgtYn', header: { text: '자가발전' } },
|
||||
{ name: 'dschgWtrsExpln',fieldName: 'dschgWtrsExpln',header: { text: '방류수역' } },
|
||||
/* 4. 부대시설 */
|
||||
{ name: 'prcsgFcltYn', fieldName: 'prcsgFcltYn', header: { text: '전처리시설' } },
|
||||
{ name: 'ddrztnEqpmYn', fieldName: 'ddrztnEqpmYn', header: { text: '탈취설비' } },
|
||||
{ name: 'oslfEtgtYn', fieldName: 'oslfEtgtYn', header: { text: '자가발전' } },
|
||||
{ name: 'dschgWtrsExpln', fieldName: 'dschgWtrsExpln', header: { text: '방류수역' } },
|
||||
|
||||
/* 5. 최종처분량 */
|
||||
{ name: 'prcptnLastDspsQnt', fieldName: 'prcptnLastDspsQnt', header: { text: '침사(량)' }, valueType: ValueType.NUMBER, numberFormat: '#,##0', footer: footerIntArrayByDivision },
|
||||
{ name: 'ctmnLastDspsQnt', fieldName: 'ctmnLastDspsQnt', header: { text: '협잡물(량)' }, valueType: ValueType.NUMBER, numberFormat: '#,##0', footer: footerIntArrayByDivision },
|
||||
/* 5. 최종처분량 */
|
||||
{ name: 'prcptnLastDspsQnt', fieldName: 'prcptnLastDspsQnt', header: { text: '침사(량)' }, valueType: ValueType.NUMBER, numberFormat: '#,##0', footer: footerIntArrayByDivision },
|
||||
{ name: 'ctmnLastDspsQnt', fieldName: 'ctmnLastDspsQnt', header: { text: '협잡물(량)' }, valueType: ValueType.NUMBER, numberFormat: '#,##0', footer: footerIntArrayByDivision },
|
||||
|
||||
/* 6. 운영실적 */
|
||||
{ name: 'oprtngDayCnt', fieldName: 'oprtngDayCnt', header: { text: '가동일수' }, valueType: ValueType.NUMBER, numberFormat: '#,##0', footer: footerIntArrayByDivision },
|
||||
{ name: 'grssMltvQnt', fieldName: 'grssMltvQnt', header: { text: '총배수량(㎥/년)' }, valueType: ValueType.NUMBER, numberFormat: '#,##0', footer: footerIntArrayByDivision },
|
||||
{ name: 'rmrk', fieldName: 'rmrk', header: { text: '비고' } },
|
||||
],
|
||||
columnLayout: [
|
||||
{
|
||||
name: 'areaGroup', header: { text: '행정구역' }, items: [
|
||||
{ column: 'ctpvNm', footerUserSpans: [{ colspan: 4 }, { colspan: 4 }] },
|
||||
'sggNm', 'admdstNm',
|
||||
]
|
||||
},
|
||||
'displayYear', 'fcltyKndCn', 'oprtngStrtYmd', 'planDesignFreqCnt', 'wtrStrgZoneArea',
|
||||
{ name: 'revGroup', header: { text: '유수지' }, items: ['rsvrYn', 'rsvrImpndQnt'] },
|
||||
{ name: 'absGroup', header: { text: '흡수정' }, items: ['abstnRgnImdQnt'] },
|
||||
'fcltCpct',
|
||||
{
|
||||
name: 'pumpMainGroup', header: { text: '펌프시설' },
|
||||
items: [
|
||||
{ name: 'p1Group', header: { text: '펌프시설1' }, items: ['pumpFcltN1DmtrExpln', 'pumpFcltN1PerPpqty', 'pumpFcltN1PumpCnt', 'pumpFcltN1RsrvPumpCnt'] },
|
||||
{ name: 'p2Group', header: { text: '펌프시설2' }, items: ['pumpFcltN2DmtrExpln', 'pumpFcltN2PerPpqty', 'pumpFcltN2PumpCnt', 'pumpFcltN2RsrvPumpCnt'] },
|
||||
{ name: 'p3Group', header: { text: '펌프시설3' }, items: ['pumpFcltN3DmtrExpln', 'pumpFcltN3PerPpqty', 'pumpFcltN3PumpCnt', 'pumpFcltN3RsrvPumpCnt'] }
|
||||
]
|
||||
},
|
||||
{ name: 'subFacGroup', header: { text: '부대시설' }, items: ['prcsgFcltYn', 'ddrztnEqpmYn', 'oslfEtgtYn'] },
|
||||
'dschgWtrsExpln',
|
||||
{ name: 'disposalAmtGroup', header: { text: '최종처분량(ton/년)' }, items: ['prcptnLastDspsQnt', 'ctmnLastDspsQnt'] },
|
||||
{ name: 'opGroup', header: { text: '운영실적' }, items: ['oprtngDayCnt', 'grssMltvQnt'] },
|
||||
'rmrk'
|
||||
]
|
||||
}
|
||||
/* 6. 운영실적 */
|
||||
{ name: 'oprtngDayCnt', fieldName: 'oprtngDayCnt', header: { text: '가동일수' }, valueType: ValueType.NUMBER, numberFormat: '#,##0', footer: footerIntArrayByDivision },
|
||||
{ name: 'grssMltvQnt', fieldName: 'grssMltvQnt', header: { text: '총배수량(㎥/년)' }, valueType: ValueType.NUMBER, numberFormat: '#,##0', footer: footerIntArrayByDivision },
|
||||
{ name: 'rmrk', fieldName: 'rmrk', header: { text: '비고' } },
|
||||
],
|
||||
columnLayout: [
|
||||
{
|
||||
name: 'areaGroup', header: { text: '행정구역' }, items: [
|
||||
{ column: 'ctpvNm', footerUserSpans: [{ colspan: 4 }, { colspan: 4 }] },
|
||||
'sggNm', 'fcltNm'
|
||||
]
|
||||
},
|
||||
'displayYear', 'fcltyKndCn', 'oprtngStrtYmd', 'planDesignFreqCnt', 'wtrStrgZoneArea',
|
||||
{ name: 'revGroup', header: { text: '유수지' }, items: ['rsvrYn', 'rsvrImpndQnt'] },
|
||||
{ name: 'absGroup', header: { text: '흡수정' }, items: ['abstnRgnImdQnt'] },
|
||||
'fcltCpct',
|
||||
{
|
||||
name: 'pumpMainGroup', header: { text: '펌프시설' },
|
||||
items: [
|
||||
{ name: 'p1Group', header: { text: '펌프시설1' }, items: ['pumpFcltN1DmtrExpln', 'pumpFcltN1PerPpqty', 'pumpFcltN1PumpCnt', 'pumpFcltN1RsrvPumpCnt'] },
|
||||
{ name: 'p2Group', header: { text: '펌프시설2' }, items: ['pumpFcltN2DmtrExpln', 'pumpFcltN2PerPpqty', 'pumpFcltN2PumpCnt', 'pumpFcltN2RsrvPumpCnt'] },
|
||||
{ name: 'p3Group', header: { text: '펌프시설3' }, items: ['pumpFcltN3DmtrExpln', 'pumpFcltN3PerPpqty', 'pumpFcltN3PumpCnt', 'pumpFcltN3RsrvPumpCnt'] }
|
||||
]
|
||||
},
|
||||
{ name: 'subFacGroup', header: { text: '부대시설' }, items: ['prcsgFcltYn', 'ddrztnEqpmYn', 'oslfEtgtYn'] },
|
||||
'dschgWtrsExpln',
|
||||
{ name: 'disposalAmtGroup', header: { text: '최종처분량(ton/년)' }, items: ['prcptnLastDspsQnt', 'ctmnLastDspsQnt'] },
|
||||
{ name: 'opGroup', header: { text: '운영실적' }, items: ['oprtngDayCnt', 'grssMltvQnt'] },
|
||||
'rmrk'
|
||||
]
|
||||
}
|
||||
];
|
||||
|
||||
export const SewageReservoirPumpInfoListRvw = rawReservoirList.map(tab => ({
|
||||
|
||||
@@ -76,7 +76,7 @@ const rawSeweragePenetrationRateInfoList = {
|
||||
}
|
||||
]
|
||||
},
|
||||
{ name: 'wtsysNm', fieldName: 'rvbsn', header: { text: '수계' } },
|
||||
{ name: 'rvbsn', fieldName: 'rvbsn', header: { text: '수계' } },
|
||||
{ name: 'trbtrNm', fieldName: 'trbtrNm', header: { text: '지류' } },
|
||||
{ name: 'mdbsn', fieldName: 'mdbsn', header: { text: '세부단위유역' } },
|
||||
{ name: 'lgbsn', fieldName: 'lgbsn', header: { text: '중권역' } },
|
||||
@@ -117,7 +117,7 @@ const rawSeweragePenetrationRateInfoList = {
|
||||
]
|
||||
},
|
||||
'displayYear',
|
||||
'wtsysNm',
|
||||
'rvbsn',
|
||||
'trbtrNm',
|
||||
{
|
||||
name: 'groupB',
|
||||
|
||||
@@ -8,26 +8,28 @@ const StatsInputStatusInfoColumnRaw = {
|
||||
{ name: 'sggNm', fieldName: 'sggNm', header: { text: '시군구' }, },
|
||||
{ name: 'sewerBzmnCd', fieldName: 'sewerBzmnCd', header: { text: '사업자코드' }, visible: false },
|
||||
{ name: 'statsCd', fieldName: 'statsCd', header: { text: '메뉴코드' }, visible: false },
|
||||
{ name: 'status', fieldName: 'status', header: { text: '진행상태' }, mergeCells: true },
|
||||
{ name: 'statsNm', fieldName: 'statsNm', header: { text: '구분' }, width: 220 },
|
||||
{ name: 'tabNm', fieldName: 'tabNm', header: { text: '구분' }, width: 220 },
|
||||
|
||||
{ name: 'chargerNm', fieldName: 'chargerNm', header: { text: '제출자' } },
|
||||
{ name: 'chargerCttpc', fieldName: 'chargerCttpc', header: { text: '연락처' } },
|
||||
{ name: 'statusNm', fieldName: 'statusNm', header: { text: '지자체진행상태' } },
|
||||
{ name: 'statusNm2', fieldName: 'statusNm2', header: { text: '진행상태' } },
|
||||
{ name: 'submitStatusNm', fieldName: 'submitStatusNm', header: { text: '지자체진행상태' } },
|
||||
{ name: 'submitStatusCd', fieldName: 'submitStatusCd', header: { text: '지자체진행상태코드' }, visible: false },
|
||||
{ name: 'prvnStatusNm', fieldName: 'prvnStatusNm', header: { text: '진행상태' } },
|
||||
{ name: 'prvnStatusCd', fieldName: 'prvnStatusCd', header: { text: '진행상태코드' }, visible: false },
|
||||
],
|
||||
|
||||
columnLayout: [
|
||||
'ctpvNm',
|
||||
'sggNm',
|
||||
'statsNm',
|
||||
'status',
|
||||
'tabNm',
|
||||
'chargerNm',
|
||||
'chargerCttpc',
|
||||
'statusNm',
|
||||
'statusNm2',
|
||||
'submitStatusNm',
|
||||
'prvnStatusNm',
|
||||
'statsCd',
|
||||
'sewerBzmnCd',
|
||||
'submitStatusCd',
|
||||
'prvnStatusCd'
|
||||
]
|
||||
};
|
||||
|
||||
|
||||
@@ -0,0 +1,799 @@
|
||||
import dayjs from "dayjs";
|
||||
import { headers } from "next/headers";
|
||||
import { ValueType } from "realgrid";
|
||||
|
||||
/**
|
||||
* 하수도 통계 관리 > 02. 하수관로 (합계)
|
||||
* 항목은 검토(SewagePipeRvwColumn)와 동일하나 footer·mergeCells·구분(displayYear)·비고(rmrk) 제외.
|
||||
* 표시 형식은 SeweragePentrationRateTotColumn과 같이 dataFormat + editable: false.
|
||||
*/
|
||||
const currentYear = dayjs().year() - 1;
|
||||
const startYear = 1996;
|
||||
const totalCount = currentYear - startYear + 1 + 1;
|
||||
|
||||
const rawSewagePipeTotList = [
|
||||
{
|
||||
tabKey: "ST00020001",
|
||||
tabLabel: "지역별 시설현황",
|
||||
rowStartNum: 4,
|
||||
fixedColumns: 2,
|
||||
columns: [
|
||||
{ name: "ctpvNm", fieldName: "ctpvNm", header: { text: "시도" }, editable: false },
|
||||
{ name: "sggNm", fieldName: "sggNm", header: { text: "시군구" }, editable: false },
|
||||
{ name: "admdstNm", fieldName: "admdstNm", header: { text: "행정구역명" }, editable: false },
|
||||
{ name: "goalYr", fieldName: "goalYr", header: { text: "하수정보기본계획목표년도" }, editable: false },
|
||||
{
|
||||
name: "wholPplMtncPlanPrlg",
|
||||
fieldName: "wholPplMtncPlanPrlg",
|
||||
header: { text: "총관로정비\n계획연장(m)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "wholPlanPrlg",
|
||||
fieldName: "wholPlanPrlg",
|
||||
header: { text: "총계획연장(m)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "wholFcltPrlg",
|
||||
fieldName: "wholFcltPrlg",
|
||||
header: { text: "총시설연장(m)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "swagePplPsplyRt",
|
||||
fieldName: "swagePplPsplyRt",
|
||||
header: { text: "하수관로\n보급률(%)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "cbsysPplMtncPlanArea",
|
||||
fieldName: "cbsysPplMtncPlanArea",
|
||||
header: { text: "관로정비\n계획면적(㎢)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.000",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "cbsysPplMtncPlanPrlg",
|
||||
fieldName: "cbsysPplMtncPlanPrlg",
|
||||
header: { text: "관로정비\n계획연장(m)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "cbsysPlanPrlg",
|
||||
fieldName: "cbsysPlanPrlg",
|
||||
header: { text: "계획연장(m)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "cbsysFcltPrlg",
|
||||
fieldName: "cbsysFcltPrlg",
|
||||
header: { text: "시설연장(m)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "cbsysSqrePrlg",
|
||||
fieldName: "cbsysSqrePrlg",
|
||||
header: { text: "사각형(m)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "cbsysCiclPrlg",
|
||||
fieldName: "cbsysCiclPrlg",
|
||||
header: { text: "원형(m)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "cbsysOpnPrlg",
|
||||
fieldName: "cbsysOpnPrlg",
|
||||
header: { text: "개거(m)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "cbsysGttrPrlg",
|
||||
fieldName: "cbsysGttrPrlg",
|
||||
header: { text: "측구(m)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "drtwPplMtncPlanArea",
|
||||
fieldName: "drtwPplMtncPlanArea",
|
||||
header: { text: "관로정비\n계획면적(㎢)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.000",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "drtwPplMtncPlanPrlg",
|
||||
fieldName: "drtwPplMtncPlanPrlg",
|
||||
header: { text: "관로정비\n계획연장(m)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "drtwPplPlanPrlg",
|
||||
fieldName: "drtwPplPlanPrlg",
|
||||
header: { text: "계획연장(m)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "drtwPplFcltPrlg",
|
||||
fieldName: "drtwPplFcltPrlg",
|
||||
header: { text: "시설연장(m)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "drtwPplSqrePrlg",
|
||||
fieldName: "drtwPplSqrePrlg",
|
||||
header: { text: "사각형(m)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "drtwPplCiclPrlg",
|
||||
fieldName: "drtwPplCiclPrlg",
|
||||
header: { text: "원형(m)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "exlnPplMtncPlanArea",
|
||||
fieldName: "exlnPplMtncPlanArea",
|
||||
header: { text: "관로정비\n계획면적(㎢)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.000",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "exlnPplMtncPlanPrlg",
|
||||
fieldName: "exlnPplMtncPlanPrlg",
|
||||
header: { text: "관로정비\n계획연장(m)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "exlnPplPlanPrlg",
|
||||
fieldName: "exlnPplPlanPrlg",
|
||||
header: { text: "계획연장(m)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "exlnPplFcltPrlg",
|
||||
fieldName: "exlnPplFcltPrlg",
|
||||
header: { text: "시설연장(m)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "exlnPplSqrePrlg",
|
||||
fieldName: "exlnPplSqrePrlg",
|
||||
header: { text: "사각형(m)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "exlnPplCiclPrlg",
|
||||
fieldName: "exlnPplCiclPrlg",
|
||||
header: { text: "원형(m)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "exlnPplOpnPrlg",
|
||||
fieldName: "exlnPplOpnPrlg",
|
||||
header: { text: "개거(m)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "exlnPplGttrPrlg",
|
||||
fieldName: "exlnPplGttrPrlg",
|
||||
header: { text: "측구(m)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "cbsysMnhlCnt",
|
||||
fieldName: "cbsysMnhlCnt",
|
||||
header: { text: "합류식맨홀(개소)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "sprsysDrtwMnhlCnt",
|
||||
fieldName: "sprsysDrtwMnhlCnt",
|
||||
header: { text: "오수맨홀(개소)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "sprsysExlnMnhlCnt",
|
||||
fieldName: "sprsysExlnMnhlCnt",
|
||||
header: { text: "우수맨홀(개소)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "drtwRcvprpCnt",
|
||||
fieldName: "drtwRcvprpCnt",
|
||||
header: { text: "오수받이(개소)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "exlnRcvprpCnt",
|
||||
fieldName: "exlnRcvprpCnt",
|
||||
header: { text: "우수받이(개소)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "stofcbrCnt",
|
||||
fieldName: "stofcbrCnt",
|
||||
header: { text: "우수토실(개소)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "exlnOtflCnt",
|
||||
fieldName: "exlnOtflCnt",
|
||||
header: { text: "우수토구(개소)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "sewerLdgrEdpPrlg",
|
||||
fieldName: "sewerLdgrEdpPrlg",
|
||||
header: { text: "하수도대장전산화연장(m)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "sewerLdgrEdpRt",
|
||||
fieldName: "sewerLdgrEdpRt",
|
||||
header: { text: "하수도대장전산화율(%)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.0",
|
||||
editable: false,
|
||||
},
|
||||
],
|
||||
columnLayout: [
|
||||
{
|
||||
name: "areaGroup",
|
||||
header: { text: "행정구역" },
|
||||
items: ["ctpvNm", "sggNm", "admdstNm"],
|
||||
},
|
||||
"goalYr",
|
||||
"wholPplMtncPlanPrlg",
|
||||
"wholPlanPrlg",
|
||||
"wholFcltPrlg",
|
||||
"swagePplPsplyRt",
|
||||
{
|
||||
name: "combinedGroup",
|
||||
header: { text: "합류식(m)" },
|
||||
items: [
|
||||
"cbsysPplMtncPlanArea",
|
||||
"cbsysPplMtncPlanPrlg",
|
||||
"cbsysPlanPrlg",
|
||||
"cbsysFcltPrlg",
|
||||
{ name: "cmbnAmGroup", header: { text: "암거" }, items: ["cbsysSqrePrlg", "cbsysCiclPrlg"] },
|
||||
"cbsysOpnPrlg",
|
||||
"cbsysGttrPrlg",
|
||||
],
|
||||
},
|
||||
{
|
||||
name: "sepGroup",
|
||||
header: { text: "분류식(m)" },
|
||||
items: [
|
||||
{
|
||||
name: "foulPipeGroup",
|
||||
header: { text: "오수관로" },
|
||||
items: [
|
||||
"drtwPplMtncPlanArea",
|
||||
"drtwPplMtncPlanPrlg",
|
||||
"drtwPplPlanPrlg",
|
||||
"drtwPplFcltPrlg",
|
||||
{ name: "foulAmGroup", header: { text: "암거" }, items: ["drtwPplSqrePrlg", "drtwPplCiclPrlg"] },
|
||||
],
|
||||
},
|
||||
{
|
||||
name: "rainPipeGroup",
|
||||
header: { text: "우수관로" },
|
||||
items: [
|
||||
"exlnPplMtncPlanArea",
|
||||
"exlnPplMtncPlanPrlg",
|
||||
"exlnPplPlanPrlg",
|
||||
"exlnPplFcltPrlg",
|
||||
{ name: "rainAmGroup", header: { text: "암거" }, items: ["exlnPplSqrePrlg", "exlnPplCiclPrlg"] },
|
||||
"exlnPplOpnPrlg",
|
||||
"exlnPplGttrPrlg",
|
||||
],
|
||||
},
|
||||
],
|
||||
},
|
||||
"cbsysMnhlCnt",
|
||||
{ name: "fcltyGroup", header: { text: "분류식" }, items: ["sprsysDrtwMnhlCnt", "sprsysExlnMnhlCnt"] },
|
||||
"drtwRcvprpCnt",
|
||||
"exlnRcvprpCnt",
|
||||
"stofcbrCnt",
|
||||
"exlnOtflCnt",
|
||||
"sewerLdgrEdpPrlg",
|
||||
"sewerLdgrEdpRt",
|
||||
],
|
||||
},
|
||||
|
||||
{
|
||||
tabKey: "ST00020002",
|
||||
tabLabel: "시설별 설치현황",
|
||||
rowStartNum: 4,
|
||||
fixedColumns: 3,
|
||||
columns: [
|
||||
{ name: "ctpvNm", fieldName: "ctpvNm", header: { text: "시도" }, editable: false },
|
||||
{ name: "sggNm", fieldName: "sggNm", header: { text: "시군구" }, editable: false },
|
||||
{ name: "admdstNm", fieldName: "admdstNm", header: { text: "행정구역명" }, editable: false },
|
||||
{ name: "swtrmtFcltNm", fieldName: "swtrmtFcltNm", header: { text: "하수처리시설 명" }, editable: false },
|
||||
{
|
||||
name: "prcsFcltCpct",
|
||||
fieldName: "prcsFcltCpct",
|
||||
header: { text: "하수처리\n시설용량\n(㎥/일)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.0",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "prcsZoneArea",
|
||||
fieldName: "prcsZoneArea",
|
||||
header: { text: "합계" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.000",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "cbsysPrcsZoneArea",
|
||||
fieldName: "cbsysPrcsZoneArea",
|
||||
header: { text: "합류식" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.000",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "sprsysPrcsZoneArea",
|
||||
fieldName: "sprsysPrcsZoneArea",
|
||||
header: { text: "분류식" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.000",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "sprsysVartnRt",
|
||||
fieldName: "sprsysVartnRt",
|
||||
header: { text: "분류식화율" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.000",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "mltvEqpmCnt",
|
||||
fieldName: "mltvEqpmCnt",
|
||||
header: { text: "합계" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "cbsysMltvEqpmCnt",
|
||||
fieldName: "cbsysMltvEqpmCnt",
|
||||
header: { text: "합류식" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "sprsysMltvEqpmCnt",
|
||||
fieldName: "sprsysMltvEqpmCnt",
|
||||
header: { text: "합계" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "sprsysMltvLnkgCnt",
|
||||
fieldName: "sprsysMltvLnkgCnt",
|
||||
header: { text: "연결" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "sprsysMltvYetLnkgCnt",
|
||||
fieldName: "sprsysMltvYetLnkgCnt",
|
||||
header: { text: "미연결" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "wholFcltPrlg",
|
||||
fieldName: "wholFcltPrlg",
|
||||
header: { text: "총\n시설연장\n(m)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "wholIcptgAtlfcPrlg",
|
||||
fieldName: "wholIcptgAtlfcPrlg",
|
||||
header: { text: "합계" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "icptgPrlg",
|
||||
fieldName: "icptgPrlg",
|
||||
header: { text: "차집" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "atlfcsPrlg",
|
||||
fieldName: "atlfcsPrlg",
|
||||
header: { text: "오수간선" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "cbsysStofcbrCnt",
|
||||
fieldName: "cbsysStofcbrCnt",
|
||||
header: { text: "우수토실(합류)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "sprsysStofcbrCnt",
|
||||
fieldName: "sprsysStofcbrCnt",
|
||||
header: { text: "우수토실(분류)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "sprsysExlnOtflCnt",
|
||||
fieldName: "sprsysExlnOtflCnt",
|
||||
header: { text: "우수토구(분류)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "wholBrchlnPrlg",
|
||||
fieldName: "wholBrchlnPrlg",
|
||||
header: { text: "합계" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "cbsysBrchlnPrlg",
|
||||
fieldName: "cbsysBrchlnPrlg",
|
||||
header: { text: "합류식" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "exlnBrchlnPrlg",
|
||||
fieldName: "exlnBrchlnPrlg",
|
||||
header: { text: "우수" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "drtwBrchlnPrlg",
|
||||
fieldName: "drtwBrchlnPrlg",
|
||||
header: { text: "오수" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.00",
|
||||
editable: false,
|
||||
},
|
||||
],
|
||||
columnLayout: [
|
||||
{
|
||||
name: "addrGroup",
|
||||
header: { text: "행정구역" },
|
||||
items: ["ctpvNm", "sggNm", "admdstNm"],
|
||||
},
|
||||
"swtrmtFcltNm",
|
||||
"prcsFcltCpct",
|
||||
{
|
||||
name: "areaGroup",
|
||||
header: { text: "처리구역면적(㎢)" },
|
||||
items: ["prcsZoneArea", "cbsysPrcsZoneArea", "sprsysPrcsZoneArea"],
|
||||
},
|
||||
"sprsysVartnRt",
|
||||
{
|
||||
name: "drainGroup",
|
||||
header: { text: "배수설비(개소)" },
|
||||
items: [
|
||||
"mltvEqpmCnt",
|
||||
"cbsysMltvEqpmCnt",
|
||||
{
|
||||
name: "sprsysGroup",
|
||||
header: { text: "분류식" },
|
||||
items: [
|
||||
"sprsysMltvEqpmCnt", "sprsysMltvLnkgCnt", "sprsysMltvYetLnkgCnt"
|
||||
]
|
||||
}
|
||||
],
|
||||
},
|
||||
{
|
||||
name: "pipeGroup",
|
||||
header: { text: "하수관로" },
|
||||
items: [
|
||||
"wholFcltPrlg",
|
||||
{
|
||||
name: "trunkGroup",
|
||||
header: { text: "차집/오수간선(m)" },
|
||||
items: ["wholIcptgAtlfcPrlg", "icptgPrlg", "atlfcsPrlg"],
|
||||
},
|
||||
{
|
||||
name: "siteGroup",
|
||||
header: { text: "토실/토구(개소)" },
|
||||
items: [
|
||||
{ name: "cmbnSiteGroup", header: { text: "합류식" }, items: ["cbsysStofcbrCnt"] },
|
||||
{ name: "sepSiteGroup", header: { text: "분류식" }, items: ["sprsysStofcbrCnt", "sprsysExlnOtflCnt"] },
|
||||
],
|
||||
},
|
||||
{
|
||||
name: "branchGroup",
|
||||
header: { text: "지선(m)" },
|
||||
items: [
|
||||
"wholBrchlnPrlg",
|
||||
"cbsysBrchlnPrlg",
|
||||
{ name: "sepBranchGroup", header: { text: "분류식" }, items: ["exlnBrchlnPrlg", "drtwBrchlnPrlg"] },
|
||||
],
|
||||
},
|
||||
],
|
||||
},
|
||||
],
|
||||
},
|
||||
|
||||
{
|
||||
tabKey: "ST00020003",
|
||||
tabLabel: "관종별 현황",
|
||||
rowStartNum: 2,
|
||||
fixedColumns: 2,
|
||||
columns: [
|
||||
{ name: "ctpvNm", fieldName: "ctpvNm", header: { text: "시도" }, editable: false },
|
||||
{ name: "sggNm", fieldName: "sggNm", header: { text: "시군구" }, editable: false },
|
||||
{ name: "admdstNm", fieldName: "admdstNm", header: { text: "행정구역명" }, editable: false },
|
||||
{ name: "swrgPipeNm", fieldName: "swrgPipeNm", header: { text: "관종" }, editable: false },
|
||||
{
|
||||
name: "pipeByPrstWholSum",
|
||||
fieldName: "pipeByPrstWhol",
|
||||
header: { text: "계" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.0",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "lyngPrlgSum",
|
||||
fieldName: "lyngPrlg",
|
||||
header: { text: "매설연장(m)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.0",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "dmltnPrlgSum",
|
||||
fieldName: "dmltnPrlg",
|
||||
header: { text: "철거연장(m)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.0",
|
||||
editable: false,
|
||||
},
|
||||
...Array.from({ length: totalCount }, (_, i) => {
|
||||
const dtoNum = totalCount - i;
|
||||
const wholField = `yy${dtoNum}PrlgWhol`;
|
||||
const lyngField = `yy${dtoNum}LyngPrlg`;
|
||||
const dmltnField = `yy${dtoNum}DmltnPrlg`;
|
||||
return [
|
||||
{
|
||||
name: wholField,
|
||||
fieldName: wholField,
|
||||
header: { text: "계" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.0",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: lyngField,
|
||||
fieldName: lyngField,
|
||||
header: { text: "매설연장(m)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.0",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: dmltnField,
|
||||
fieldName: dmltnField,
|
||||
header: { text: "철거연장(m)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.0",
|
||||
editable: false,
|
||||
},
|
||||
];
|
||||
}).flat(),
|
||||
],
|
||||
columnLayout: [
|
||||
{
|
||||
name: "areaGroup",
|
||||
header: { text: "행정구역" },
|
||||
items: ["ctpvNm", "sggNm", "admdstNm"],
|
||||
},
|
||||
"swrgPipeNm",
|
||||
{
|
||||
name: "summaryGroup",
|
||||
header: { text: "총계" },
|
||||
items: ["pipeByPrstWholSum", "lyngPrlgSum", "dmltnPrlgSum"],
|
||||
},
|
||||
...Array.from({ length: totalCount }, (_, i) => {
|
||||
const dtoNum = totalCount - i;
|
||||
const yearLabel = i === 0 ? "1996년이전" : `${startYear + (i - 1)}년`;
|
||||
return {
|
||||
name: `group_${yearLabel}`,
|
||||
header: { text: yearLabel },
|
||||
items: [`yy${dtoNum}PrlgWhol`, `yy${dtoNum}LyngPrlg`, `yy${dtoNum}DmltnPrlg`],
|
||||
};
|
||||
}),
|
||||
],
|
||||
},
|
||||
|
||||
{
|
||||
tabKey: "ST00020004",
|
||||
tabLabel: "관경별 현황",
|
||||
rowStartNum: 2,
|
||||
fixedColumns: 3,
|
||||
columns: [
|
||||
{ name: "ctpvNm", fieldName: "ctpvNm", header: { text: "시도" }, editable: false },
|
||||
{ name: "sggNm", fieldName: "sggNm", header: { text: "시군구" }, editable: false },
|
||||
{ name: "admdstNm", fieldName: "admdstNm", header: { text: "행정구역명" }, editable: false },
|
||||
{ name: "swrgPipeNm", fieldName: "swrgPipeNm", header: { text: "관종" }, editable: false },
|
||||
{
|
||||
name: "pdmtByTsmWhol",
|
||||
fieldName: "pdmtByTsmWhol",
|
||||
header: { text: "총계(m)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.0",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "step1PdmtPrlg",
|
||||
fieldName: "step1PdmtPrlg",
|
||||
header: { text: "200mm 미만" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.0",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "step2PdmtPrlg",
|
||||
fieldName: "step2PdmtPrlg",
|
||||
header: { text: "200mm이상~\n300mm미만" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.0",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "step3PdmtPrlg",
|
||||
fieldName: "step3PdmtPrlg",
|
||||
header: { text: "300mm이상~\n500mm미만" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.0",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "step4PdmtPrlg",
|
||||
fieldName: "step4PdmtPrlg",
|
||||
header: { text: "500mm이상~\n800mm미만" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.0",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "step5PdmtPrlg",
|
||||
fieldName: "step5PdmtPrlg",
|
||||
header: { text: "800mm 이상" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.0",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "sqrePdmtPrlg",
|
||||
fieldName: "sqrePdmtPrlg",
|
||||
header: { text: "사각형(m)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.0",
|
||||
editable: false,
|
||||
},
|
||||
{
|
||||
name: "etcPdmtPrlg",
|
||||
fieldName: "etcPdmtPrlg",
|
||||
header: { text: "기타\n(측구/개거 등)" },
|
||||
valueType: ValueType.NUMBER,
|
||||
dataFormat: "#,##0.0",
|
||||
editable: false,
|
||||
},
|
||||
],
|
||||
columnLayout: [
|
||||
{
|
||||
name: "addrGroup",
|
||||
header: { text: "행정구역" },
|
||||
items: ["ctpvNm", "sggNm", "admdstNm"],
|
||||
},
|
||||
"swrgPipeNm",
|
||||
"pdmtByTsmWhol",
|
||||
{
|
||||
name: "circleGroup",
|
||||
header: { text: "원형(m)" },
|
||||
items: ["step1PdmtPrlg", "step2PdmtPrlg", "step3PdmtPrlg", "step4PdmtPrlg", "step5PdmtPrlg"],
|
||||
},
|
||||
"sqrePdmtPrlg",
|
||||
"etcPdmtPrlg",
|
||||
],
|
||||
},
|
||||
];
|
||||
|
||||
export const SewagePipeColumnInfoListTot = rawSewagePipeTotList.map((tab) => ({
|
||||
...tab,
|
||||
columns: tab.columns.map((col) => ({ ...col, editable: false as const })),
|
||||
}));
|
||||
+29
@@ -0,0 +1,29 @@
|
||||
import { stClient } from "@/shared/api/client";
|
||||
import { ENDPOINT } from "@/shared/config";
|
||||
|
||||
import type {
|
||||
SewagePipeMaintainDredgingResponse,
|
||||
SewagePipeMaintainRepairResponse,
|
||||
SewagePipeMaintainRequestParams,
|
||||
SewagePipeMaintainService,
|
||||
} from "../../model/input/statistics-input-sewage-pipe-maintain-interface";
|
||||
|
||||
export class SewagePipeMaintainApiService implements SewagePipeMaintainService {
|
||||
public async getSewagePipeMaintainRepair(param: SewagePipeMaintainRequestParams): Promise<SewagePipeMaintainRepairResponse> {
|
||||
const response = await stClient.get<SewagePipeMaintainRepairResponse>(
|
||||
`${ENDPOINT.ST_SERVICE.INPUT}/sewage-pipe-maintain/repair`,
|
||||
{ params: param }
|
||||
);
|
||||
return response.data;
|
||||
};
|
||||
|
||||
public async getSewagePipeMaintainDredging(param: SewagePipeMaintainRequestParams): Promise<SewagePipeMaintainDredgingResponse> {
|
||||
const response = await stClient.get<SewagePipeMaintainDredgingResponse>(
|
||||
`${ENDPOINT.ST_SERVICE.INPUT}/sewage-pipe-maintain/dredging`,
|
||||
{ params: param }
|
||||
);
|
||||
return response.data;
|
||||
};
|
||||
}
|
||||
|
||||
export const sewagePipeMaintainApiService = new SewagePipeMaintainApiService();
|
||||
@@ -13,6 +13,7 @@ import {
|
||||
type SubmitExceptionResponse,
|
||||
type StatisticsLogRequest,
|
||||
type StatisticsLogResponse,
|
||||
type StatisticsLogDetailResponse,
|
||||
} from "../model/statistics-interface";
|
||||
|
||||
export class StatisticsAPiService implements StatisticsService {
|
||||
@@ -72,6 +73,13 @@ export class StatisticsAPiService implements StatisticsService {
|
||||
);
|
||||
return response.data;
|
||||
}
|
||||
|
||||
public async getLogDetail(param: string): Promise<StatisticsLogDetailResponse> {
|
||||
const response = await stClient.get<StatisticsLogDetailResponse>(
|
||||
`${ENDPOINT.ST_SERVICE.INPUTCOMMON}/logs/${param}`,
|
||||
);
|
||||
return response.data;
|
||||
}
|
||||
}
|
||||
|
||||
export const statisticsAPi = new StatisticsAPiService();
|
||||
@@ -2,6 +2,7 @@ import { ENDPOINT } from "@/shared/config";
|
||||
import { stClient } from "@/shared/api/client";
|
||||
|
||||
import type { SewerageSupplyRateRequest, SewerageSupplyRateResponse } from "../model/statistics-total/statistics-sewage-supply-rate-total-interface";
|
||||
import type { SewagePipeTotalRequest, SewagePipeTotalResponse } from "../model/statistics-total/statistics-sewage-pipe-total-interface";
|
||||
|
||||
export class StatisticsTotalApiService {
|
||||
public async getSewerageSupplyRateList(params: SewerageSupplyRateRequest): Promise<SewerageSupplyRateResponse> {
|
||||
@@ -11,6 +12,14 @@ export class StatisticsTotalApiService {
|
||||
);
|
||||
return response.data;
|
||||
}
|
||||
|
||||
public async getSewagePipeRegionalStatusList(params: SewagePipeTotalRequest): Promise<SewagePipeTotalResponse> {
|
||||
const response = await stClient.get<SewagePipeTotalResponse> (
|
||||
`${ENDPOINT.ST_SERVICE.TOTAL}/sewer-pipe/regional-status`,
|
||||
{ params: params }
|
||||
);
|
||||
return response.data;
|
||||
}
|
||||
}
|
||||
|
||||
export const statisticsTotalStatusApi = new StatisticsTotalApiService();
|
||||
+112
@@ -0,0 +1,112 @@
|
||||
import type { ApiResponse } from "../statistics-interface";
|
||||
|
||||
export interface SewagePipeMaintainRepairStatusInfo {
|
||||
laePicNm: string | null;
|
||||
laePicTelNo: string | null;
|
||||
laeKbrdrDeptNm: string | null;
|
||||
laeKbrdrJbgdNm: string | null;
|
||||
laeIdfrNm: string | null;
|
||||
laeIdfrTelNo: string | null;
|
||||
laeIdfrDeptNm: string | null;
|
||||
laeIdfrJbgdNm: string | null;
|
||||
laeSbmsnSttsCd: string | null;
|
||||
laeSbmsnYmd: string | null;
|
||||
}
|
||||
|
||||
export interface SewagePipeMaintainRepairVerificationResultItem {
|
||||
vrfcCd: string;
|
||||
rsnExpln: string;
|
||||
}
|
||||
|
||||
/** 필드명 -> 검증 결과 배열 */
|
||||
export type SewagePipeMaintainRepairVerificationResult = Record<
|
||||
string,
|
||||
SewagePipeMaintainRepairVerificationResultItem[]
|
||||
>;
|
||||
|
||||
export interface SewagePipeMaintainRepairCommonInfo {
|
||||
statsYr: string;
|
||||
ctpvNm: string;
|
||||
sewerBzmnCd: string;
|
||||
statsCd: string;
|
||||
verificationResult?: SewagePipeMaintainRepairVerificationResult;
|
||||
}
|
||||
|
||||
export interface SewagePipeMaintainRepairItem {
|
||||
admdstCd: string;
|
||||
sggNm: string;
|
||||
admdstNm: string;
|
||||
mendngWhol: number;
|
||||
cbsysMendngPrlg: number;
|
||||
sprsysExlnPrlg: number;
|
||||
sprsysDrtwPrlg: number;
|
||||
partMendngWhol: number;
|
||||
cbsysPartMendngPrlg: number;
|
||||
sprsysExlnMendngPrlg: number;
|
||||
sprsysDrtwMendngPrlg: number;
|
||||
cbsysMnhlCnt: number;
|
||||
sprsysDrtwMnhlCnt: number;
|
||||
sprsysExlnMnhlCnt: number;
|
||||
drtwRcvprpCnt: number;
|
||||
exlnRcvprpCnt: number;
|
||||
stofcbrCnt: number;
|
||||
otflCnt: number;
|
||||
cctvExmnPrlg: number;
|
||||
rmrk: string | null;
|
||||
verificationResult?: SewagePipeMaintainRepairVerificationResult;
|
||||
}
|
||||
|
||||
export interface SewagePipeMaintainRepairData {
|
||||
statusInfo: SewagePipeMaintainRepairStatusInfo;
|
||||
commonInfo: SewagePipeMaintainRepairCommonInfo;
|
||||
repairStatusList: SewagePipeMaintainRepairItem[];
|
||||
}
|
||||
|
||||
export interface SewagePipeMaintainDredgingItem {
|
||||
admdstCd: string;
|
||||
sggNm: string;
|
||||
admdstNm: string;
|
||||
wholFcltPrlg: number;
|
||||
wholSwagePpl: number;
|
||||
cbsysPplPrlg: number;
|
||||
sprsysExlnPrlg: number;
|
||||
sprsysDrtwPrlg: number;
|
||||
mnhlCnt: number;
|
||||
exlnDrtwRcvprpCnt: number;
|
||||
stofcbrOtflCnt: number;
|
||||
drdgnPlanPrlg: number;
|
||||
drdgnTrgtCtrsDrdgnRt: number;
|
||||
wholPrlgCtrsDrdgnRt: number;
|
||||
drdgnAmt: number;
|
||||
drdgnQnt: number;
|
||||
drdgnUntprcAmt: number;
|
||||
wholDrdgnPrcsQnt: number;
|
||||
rclmQnt: number;
|
||||
oceanEmsnQnt: number;
|
||||
rcycQnt: number;
|
||||
etcQnt: number;
|
||||
rmrk: string | null;
|
||||
verificationResult?: SewagePipeMaintainRepairVerificationResult;
|
||||
}
|
||||
|
||||
export interface SewagePipeMaintainDredgingData {
|
||||
statusInfo: SewagePipeMaintainRepairStatusInfo;
|
||||
commonInfo: SewagePipeMaintainRepairCommonInfo;
|
||||
pipeDredgingStatusList: SewagePipeMaintainDredgingItem[];
|
||||
}
|
||||
|
||||
export interface SewagePipeMaintainRequestParams {
|
||||
ctpvNm?: string;
|
||||
sggNm?: string;
|
||||
sewerBzmnCd?: string;
|
||||
statsYr?: string;
|
||||
mode?: string;
|
||||
}
|
||||
|
||||
export type SewagePipeMaintainRepairResponse = ApiResponse<SewagePipeMaintainRepairData>;
|
||||
export type SewagePipeMaintainDredgingResponse = ApiResponse<SewagePipeMaintainDredgingData>;
|
||||
|
||||
export interface SewagePipeMaintainService {
|
||||
getSewagePipeMaintainRepair(param: SewagePipeMaintainRequestParams): Promise<SewagePipeMaintainRepairResponse>;
|
||||
getSewagePipeMaintainDredging(param: SewagePipeMaintainRequestParams): Promise<SewagePipeMaintainDredgingResponse>;
|
||||
}
|
||||
@@ -7,17 +7,18 @@ export interface StatsInputStatusReviewItem {
|
||||
ctpvNm?: string;
|
||||
sggNm?: string;
|
||||
sewerBzmnCd?: string;
|
||||
status?: string;
|
||||
statsNm?: string;
|
||||
tabNm?: string;
|
||||
statsCd?: string;
|
||||
statusNm?: string;
|
||||
statusCd?: string;
|
||||
submitStatusNm?: string;
|
||||
prvnStatusNm?: string;
|
||||
chargerNm?: string;
|
||||
chargerCttpc?: string;
|
||||
submitStatusCd?: string;
|
||||
prvnStatusCd?: string;
|
||||
}
|
||||
|
||||
export interface StatsInputStatusReviewResponseData {
|
||||
sewerageSupplyRateList: StatsInputStatusReviewItem[];
|
||||
sewerageInputList: StatsInputStatusReviewItem[];
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -96,6 +96,24 @@ export interface StatisticsLogResponse {
|
||||
};
|
||||
}
|
||||
|
||||
/**
|
||||
* 통계 로그 데이터 상세조회 `data[]` 행.
|
||||
* `rmrk`, `sggNm`, `admdstCd`, `admdstNm`는 공통이고, 그 외 키는 통계/탭에 따라 가변.
|
||||
*/
|
||||
export interface StatisticsLogDetailRow {
|
||||
rmrk: string;
|
||||
sggNm: string;
|
||||
admdstCd: string;
|
||||
admdstNm: string;
|
||||
[key: string]: string | number | null | undefined;
|
||||
}
|
||||
|
||||
export interface StatisticsLogDetailResponse {
|
||||
status: string;
|
||||
message?: string;
|
||||
data?: StatisticsLogDetailRow[];
|
||||
}
|
||||
|
||||
export interface StatisticsService {
|
||||
getSidoList(): Promise<ApiResponse<SearchCondition>>;
|
||||
getSggList(sidoName: string): Promise<ApiResponse<Sgg[]>>;
|
||||
@@ -104,4 +122,5 @@ export interface StatisticsService {
|
||||
callImrService(param: ImrRequest): Promise<null>;
|
||||
submitException(param: SubmitExceptionRequest): Promise<SubmitExceptionResponse>;
|
||||
getLogList(param: StatisticsLogRequest): Promise<StatisticsLogResponse>;
|
||||
getLogDetail(param: string): Promise<StatisticsLogDetailResponse>;
|
||||
}
|
||||
@@ -131,12 +131,7 @@ export interface SewagePipeReviewFacilityItem {
|
||||
}
|
||||
|
||||
|
||||
export interface SewagePipeFacilityResponseData {
|
||||
facilityPipeList: SewagePipeReviewFacilityItem[];
|
||||
}
|
||||
|
||||
|
||||
export type SewagePipeFacilityApiResponse = ApiResponse<SewagePipeFacilityResponseData> & {
|
||||
export type SewagePipeFacilityApiResponse = ApiResponse<SewagePipeReviewFacilityItem[]> & {
|
||||
message: string;
|
||||
};
|
||||
|
||||
@@ -177,7 +172,7 @@ export type SewerPipeTypeApiResponse = ApiResponse<SewerPipeTypeItem[]>;
|
||||
|
||||
export interface SewagePipeTypeService {
|
||||
|
||||
getSewagePipeTypeList(params: SewagePipeReviewRequestParams): Promise<SewagePipeFacilityApiResponse>;
|
||||
getSewagePipeTypeList(params: SewagePipeReviewRequestParams): Promise<SewerPipeTypeApiResponse>;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -230,14 +225,9 @@ export interface SewerPipeDiamItem {
|
||||
}
|
||||
|
||||
|
||||
export interface SewerPipeDiamResponseData {
|
||||
pipeDiamStatusList: SewerPipeDiamItem[];
|
||||
}
|
||||
|
||||
|
||||
export type SewerPipeDiamApiResponse = ApiResponse<SewerPipeDiamResponseData>;
|
||||
export type SewerPipeDiamApiResponse = ApiResponse<SewerPipeDiamItem[]>;
|
||||
|
||||
|
||||
export interface SewagePipeDiamService {
|
||||
getSewagePipeDiamList(params: SewagePipeReviewRequestParams): Promise<SewagePipeFacilityApiResponse>;
|
||||
getSewagePipeDiamList(params: SewagePipeReviewRequestParams): Promise<SewerPipeDiamApiResponse>;
|
||||
}
|
||||
+50
-40
@@ -2,59 +2,69 @@ import type { ApiResponse } from "./statistics-interface";
|
||||
|
||||
// 검토 01.하수도 보급률 데이터 항목
|
||||
export interface SewerageSupplyRateReviewItem {
|
||||
ctpvNm: string;
|
||||
sggNm: string;
|
||||
statsYr: string;
|
||||
admdstNm: string;
|
||||
admdstCd: string;
|
||||
displayYear: string;
|
||||
rowType: 'OLD' | 'CURR';
|
||||
ctpvNm: string;
|
||||
sggNm: string;
|
||||
statsYr: string;
|
||||
admdstNm: string;
|
||||
admdstCd: string;
|
||||
displayYear: string;
|
||||
rowType: 'OLD' | 'CURR';
|
||||
|
||||
lgbsn: string;
|
||||
mdbsn: string;
|
||||
mdmbsn: string;
|
||||
rvbsn: string | null;
|
||||
trbtrNm: string | null;
|
||||
spcCtpnRgnCn: string | null;
|
||||
lgbsn: string;
|
||||
mdbsn: string;
|
||||
mdmbsn: string;
|
||||
rvbsn: string | null;
|
||||
trbtrNm: string | null;
|
||||
spcCtpnRgnCn: string | null;
|
||||
|
||||
wholPpltnCnt: number;
|
||||
wholArea: number;
|
||||
wholPpltnCnt: number;
|
||||
wholArea: number;
|
||||
|
||||
wholSwtrmtPpltnCnt: number;
|
||||
wholPblSwtrmtPpltnCnt: number;
|
||||
ts1SwtrmtPpltnCnt: number;
|
||||
ts2SwtrmtPpltnCnt: number;
|
||||
ts3SwtrmtPpltnCnt: number;
|
||||
|
||||
wholWwtPrcsPpltnCnt: number;
|
||||
ts1WwtPrcsPpltnCnt: number | null;
|
||||
ts2WwtPrcsPpltnCnt: number | null;
|
||||
ts3WwtPrcsPpltnCnt: number | null;
|
||||
|
||||
yetCntnPpltnCnt: number;
|
||||
staaArea: number;
|
||||
wholSwtrmtPpltnCnt: number;
|
||||
wholPblSwtrmtPpltnCnt: number;
|
||||
ts1SwtrmtPpltnCnt: number;
|
||||
ts2SwtrmtPpltnCnt: number;
|
||||
ts3SwtrmtPpltnCnt: number;
|
||||
|
||||
wholStaaExcpPpltnCnt: number;
|
||||
unprcsPpltnCnt: number | null;
|
||||
drtwPrcsPpltnCnt: number | null;
|
||||
spctnkPpltnCnt: number | null;
|
||||
staaExcpArea: number;
|
||||
wholWwtPrcsPpltnCnt: number;
|
||||
ts1WwtPrcsPpltnCnt: number | null;
|
||||
ts2WwtPrcsPpltnCnt: number | null;
|
||||
ts3WwtPrcsPpltnCnt: number | null;
|
||||
|
||||
staaPsplyRt: number;
|
||||
altdPrcsPsplyRt: number;
|
||||
sewerInstlRt: number;
|
||||
yetCntnPpltnCnt: number;
|
||||
staaArea: number;
|
||||
|
||||
wholStaaExcpPpltnCnt: number;
|
||||
unprcsPpltnCnt: number | null;
|
||||
drtwPrcsPpltnCnt: number | null;
|
||||
spctnkPpltnCnt: number | null;
|
||||
staaExcpArea: number;
|
||||
|
||||
staaPsplyRt: number;
|
||||
altdPrcsPsplyRt: number;
|
||||
sewerInstlRt: number;
|
||||
rmrk: string | null;
|
||||
}
|
||||
|
||||
export interface SewerageSupplyRateReviewRequestParams {
|
||||
ctpvNm?: string;
|
||||
sggNm?: string;
|
||||
statsYr?: string;
|
||||
sewerBzmnCd?: string;
|
||||
ctpvNm?: string;
|
||||
sggNm?: string;
|
||||
statsYr?: string;
|
||||
sewerBzmnCd?: string;
|
||||
}
|
||||
|
||||
export interface statsStatusInfo {
|
||||
statsCd?: string;
|
||||
laeSbmsnSttsCd?: string;
|
||||
statPicSbmsnSttsCd?: string;
|
||||
rjctOpnnCn?: string;
|
||||
splmntOpnnCn?: string
|
||||
}
|
||||
|
||||
export interface SewerageSupplyRateReviewResponseData {
|
||||
sewerageSupplyRateList: SewerageSupplyRateReviewItem[];
|
||||
statsStatusInfo: statsStatusInfo;
|
||||
|
||||
}
|
||||
|
||||
export type SewerageSupplyRateReviewApiResponse = ApiResponse<SewerageSupplyRateReviewResponseData> & {
|
||||
|
||||
+59
@@ -0,0 +1,59 @@
|
||||
export interface SewagePipeTotalRequest {
|
||||
ctpvNm?: string;
|
||||
sggNm?: string;
|
||||
statsYr?: string;
|
||||
sewerBzmnCd?: string;
|
||||
rowDataYn?: boolean;
|
||||
}
|
||||
|
||||
export interface SewagePipeTotalItem {
|
||||
ctpvNm: string;
|
||||
sggNm: string | null;
|
||||
admdstNm: string;
|
||||
admdstCd: string;
|
||||
statsYr: string;
|
||||
rowType: string;
|
||||
goalYr: string;
|
||||
wholPplMtncPlanPrlg: number;
|
||||
wholPlanPrlg: number;
|
||||
wholFcltPrlg: number;
|
||||
swagePplPsplyRt: number;
|
||||
cbsysPplMtncPlanArea: number;
|
||||
cbsysPplMtncPlanPrlg: number;
|
||||
cbsysPlanPrlg: number;
|
||||
cbsysFcltPrlg: number;
|
||||
cbsysSqrePrlg: number;
|
||||
cbsysCiclPrlg: number;
|
||||
cbsysOpnPrlg: number;
|
||||
cbsysGttrPrlg: number;
|
||||
drtwPplMtncPlanArea: number;
|
||||
drtwPplMtncPlanPrlg: number;
|
||||
drtwPplPlanPrlg: number;
|
||||
drtwPplFcltPrlg: number;
|
||||
drtwPplSqrePrlg: number;
|
||||
drtwPplCiclPrlg: number;
|
||||
exlnPplMtncPlanArea: number;
|
||||
exlnPplMtncPlanPrlg: number;
|
||||
exlnPplPlanPrlg: number;
|
||||
exlnPplFcltPrlg: number;
|
||||
exlnPplSqrePrlg: number;
|
||||
exlnPplCiclPrlg: number;
|
||||
exlnPplOpnPrlg: number;
|
||||
exlnPplGttrPrlg: number;
|
||||
cbsysMnhlCnt: number;
|
||||
sprsysDrtwMnhlCnt: number;
|
||||
sprsysExlnMnhlCnt: number;
|
||||
drtwRcvprpCnt: number;
|
||||
exlnRcvprpCnt: number;
|
||||
stofcbrCnt: number;
|
||||
exlnOtflCnt: number;
|
||||
sewerLdgrEdpPrlg: number;
|
||||
sewerLdgrEdpRt: number;
|
||||
rmrk: string | null;
|
||||
}
|
||||
|
||||
export interface SewagePipeTotalResponse {
|
||||
status: string;
|
||||
message: string;
|
||||
data: SewagePipeTotalItem[];
|
||||
}
|
||||
Reference in New Issue
Block a user