## Summary - 기상 맵 컨트롤 컴포넌트 추가 및 KHOA API 연동 개선 - KHOA API 엔드포인트 교체 및 해양예측 오버레이 Canvas 렌더링 전환 ## 변경 파일 - OceanForecastOverlay.tsx - WeatherMapOverlay.tsx - WeatherView.tsx - useOceanForecast.ts - khoaApi.ts - vite.config.ts ## Test plan - [ ] 기상정보 -> 기상 레이어 -> 해황 예보도 클릭 -> 이미지 렌더링 확인 - [ ] 기상정보 -> 기상 레이어 -> 백터 바람 클릭 -> 백터 이미지 렌더링 확인 Co-authored-by: Nan Kyung Lee <nankyunglee@Nanui-Macmini.local> Reviewed-on: #78 Co-authored-by: leedano <dnlee@gcsc.co.kr> Co-committed-by: leedano <dnlee@gcsc.co.kr>
95 lines
2.7 KiB
TypeScript
95 lines
2.7 KiB
TypeScript
/** 관리자 화면 9-섹션 메뉴 트리 */
|
|
|
|
export interface AdminMenuItem {
|
|
id: string;
|
|
label: string;
|
|
icon?: string;
|
|
children?: AdminMenuItem[];
|
|
}
|
|
|
|
export const ADMIN_MENU: AdminMenuItem[] = [
|
|
{
|
|
id: 'env-settings', label: '환경설정', icon: '⚙️',
|
|
children: [
|
|
{ id: 'menus', label: '메뉴관리' },
|
|
{ id: 'settings', label: '시스템설정' },
|
|
],
|
|
},
|
|
{
|
|
id: 'user-info', label: '사용자정보', icon: '👥',
|
|
children: [
|
|
{ id: 'users', label: '사용자관리' },
|
|
{ id: 'permissions', label: '권한관리' },
|
|
],
|
|
},
|
|
{
|
|
id: 'board-mgmt', label: '게시판관리', icon: '📋',
|
|
children: [
|
|
{ id: 'notice', label: '공지사항' },
|
|
{ id: 'board', label: '게시판' },
|
|
{ id: 'qna', label: 'QNA' },
|
|
],
|
|
},
|
|
{
|
|
id: 'reference', label: '기준정보', icon: '🗺️',
|
|
children: [
|
|
{
|
|
id: 'map-mgmt', label: '지도관리',
|
|
children: [
|
|
{ id: 'map-vector', label: '지도벡데이터' },
|
|
{ id: 'map-layer', label: '레이어' },
|
|
],
|
|
},
|
|
{
|
|
id: 'sensitive-map', label: '민감자원지도',
|
|
children: [
|
|
{ id: 'env-ecology', label: '환경/생태' },
|
|
{ id: 'social-economy', label: '사회/경제' },
|
|
],
|
|
},
|
|
{
|
|
id: 'coast-guard-assets', label: '해경자산',
|
|
children: [
|
|
{ id: 'cleanup-equip', label: '방제장비' },
|
|
{ id: 'dispersant-zone', label: '유처리제 제한구역' },
|
|
{ id: 'vessel-materials', label: '방제선 보유자재' },
|
|
{ id: 'cleanup-resource', label: '방제자원' },
|
|
],
|
|
},
|
|
],
|
|
},
|
|
{
|
|
id: 'external', label: '연계관리', icon: '🔗',
|
|
children: [
|
|
{
|
|
id: 'collection', label: '수집자료',
|
|
children: [
|
|
{ id: 'collect-vessel-signal', label: '선박신호' },
|
|
{ id: 'collect-hr', label: '인사정보' },
|
|
],
|
|
},
|
|
{
|
|
id: 'monitoring', label: '연계모니터링',
|
|
children: [
|
|
{ id: 'monitor-realtime', label: '실시간 관측자료' },
|
|
{ id: 'monitor-forecast', label: '수치예측자료' },
|
|
{ id: 'monitor-vessel', label: '선박위치정보' },
|
|
{ id: 'monitor-hr', label: '인사' },
|
|
],
|
|
},
|
|
],
|
|
},
|
|
];
|
|
|
|
/** 메뉴 ID로 라벨을 찾는 유틸리티 */
|
|
export function findMenuLabel(id: string, items: AdminMenuItem[] = ADMIN_MENU): string | null {
|
|
for (const item of items) {
|
|
if (item.id === id) return item.label;
|
|
if (item.children) {
|
|
const found = findMenuLabel(id, item.children);
|
|
if (found) return found;
|
|
}
|
|
}
|
|
return null;
|
|
}
|