Files
tk-factory-services/system1-factory/api/routes/monthlyStatusRoutes.js
Hyungi Ahn 93edf9529a refactor: 보안 취약점 제거 + 데드코드 정리 + 프론트엔드 중복 통합
- 인증 없는 임시 엔드포인트 삭제 (index.js, healthRoutes.js, publicPaths)
- skipAuth 우회 라우트 삭제 (workAnalysis.js)
- 하드코딩 유저 백도어 삭제 (routes/auth.js)
- 안전체크 CRUD에 admin 권한 추가 (tbmRoutes.js)
- deprecated shim 3개 삭제 + 8개 소비 파일 import 정리 (auth.js 직접 참조)
- 미사용 pageAccessController, db.js, common/security.js 삭제
- escapeHtml() 5곳 로컬 중복 제거 → api-base.js 전역 사용
- userPageAccess_v2_v2 캐시 키 버그 수정 (app-init.js)
- system3 .bak 파일 삭제, PROGRESS.md 업데이트

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-25 08:19:01 +09:00

25 lines
938 B
JavaScript

// routes/monthlyStatusRoutes.js
// 월별 작업자 상태 집계 라우트
const express = require('express');
const router = express.Router();
const MonthlyStatusController = require('../controllers/monthlyStatusController');
const { verifyToken } = require('../middlewares/auth');
// 모든 라우트에 인증 미들웨어 적용 (임시로 주석 처리 - 테스트용)
// router.use(verifyToken);
// 월별 캘린더 데이터 조회 (캘린더 페이지용)
router.get('/calendar', MonthlyStatusController.getMonthlyCalendarData);
// 특정 날짜의 작업자별 상세 상태 조회 (모달용)
router.get('/daily-details', MonthlyStatusController.getDailyWorkerDetails);
// 월별 집계 재계산 (관리자용)
router.post('/recalculate', MonthlyStatusController.recalculateMonth);
// 집계 테이블 상태 확인 (관리자용)
router.get('/status', MonthlyStatusController.getStatusInfo);
module.exports = router;