웹타입 컴포넌트 분리작업
This commit is contained in:
30
backend-node/src/routes/buttonActionStandardRoutes.ts
Normal file
30
backend-node/src/routes/buttonActionStandardRoutes.ts
Normal file
@@ -0,0 +1,30 @@
|
||||
import express from "express";
|
||||
import { ButtonActionStandardController } from "../controllers/buttonActionStandardController";
|
||||
import { authenticateToken } from "../middleware/authMiddleware";
|
||||
|
||||
const router = express.Router();
|
||||
|
||||
// 모든 라우트에 인증 미들웨어 적용
|
||||
router.use(authenticateToken);
|
||||
|
||||
// 버튼 액션 표준 관리 라우트
|
||||
router.get("/", ButtonActionStandardController.getButtonActions);
|
||||
router.get(
|
||||
"/categories",
|
||||
ButtonActionStandardController.getButtonActionCategories
|
||||
);
|
||||
router.get("/:actionType", ButtonActionStandardController.getButtonAction);
|
||||
router.post("/", ButtonActionStandardController.createButtonAction);
|
||||
router.put("/:actionType", ButtonActionStandardController.updateButtonAction);
|
||||
router.delete(
|
||||
"/:actionType",
|
||||
ButtonActionStandardController.deleteButtonAction
|
||||
);
|
||||
router.put(
|
||||
"/sort-order/bulk",
|
||||
ButtonActionStandardController.updateButtonActionSortOrder
|
||||
);
|
||||
|
||||
export default router;
|
||||
|
||||
|
||||
25
backend-node/src/routes/screenStandardRoutes.ts
Normal file
25
backend-node/src/routes/screenStandardRoutes.ts
Normal file
@@ -0,0 +1,25 @@
|
||||
import express from "express";
|
||||
import { WebTypeStandardController } from "../controllers/webTypeStandardController";
|
||||
import { ButtonActionStandardController } from "../controllers/buttonActionStandardController";
|
||||
import { authenticateToken } from "../middleware/authMiddleware";
|
||||
|
||||
const router = express.Router();
|
||||
|
||||
// 모든 라우트에 인증 미들웨어 적용
|
||||
router.use(authenticateToken);
|
||||
|
||||
// 화면관리에서 사용할 조회 전용 API
|
||||
router.get("/web-types", WebTypeStandardController.getWebTypes);
|
||||
router.get(
|
||||
"/web-types/categories",
|
||||
WebTypeStandardController.getWebTypeCategories
|
||||
);
|
||||
router.get("/button-actions", ButtonActionStandardController.getButtonActions);
|
||||
router.get(
|
||||
"/button-actions/categories",
|
||||
ButtonActionStandardController.getButtonActionCategories
|
||||
);
|
||||
|
||||
export default router;
|
||||
|
||||
|
||||
24
backend-node/src/routes/webTypeStandardRoutes.ts
Normal file
24
backend-node/src/routes/webTypeStandardRoutes.ts
Normal file
@@ -0,0 +1,24 @@
|
||||
import express from "express";
|
||||
import { WebTypeStandardController } from "../controllers/webTypeStandardController";
|
||||
import { authenticateToken } from "../middleware/authMiddleware";
|
||||
|
||||
const router = express.Router();
|
||||
|
||||
// 모든 라우트에 인증 미들웨어 적용
|
||||
router.use(authenticateToken);
|
||||
|
||||
// 웹타입 표준 관리 라우트
|
||||
router.get("/", WebTypeStandardController.getWebTypes);
|
||||
router.get("/categories", WebTypeStandardController.getWebTypeCategories);
|
||||
router.get("/:webType", WebTypeStandardController.getWebType);
|
||||
router.post("/", WebTypeStandardController.createWebType);
|
||||
router.put("/:webType", WebTypeStandardController.updateWebType);
|
||||
router.delete("/:webType", WebTypeStandardController.deleteWebType);
|
||||
router.put(
|
||||
"/sort-order/bulk",
|
||||
WebTypeStandardController.updateWebTypeSortOrder
|
||||
);
|
||||
|
||||
export default router;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user