바코드 기능 커밋밋
This commit is contained in:
41
backend-node/src/routes/barcodeLabelRoutes.ts
Normal file
41
backend-node/src/routes/barcodeLabelRoutes.ts
Normal file
@@ -0,0 +1,41 @@
|
||||
import { Router } from "express";
|
||||
import barcodeLabelController from "../controllers/barcodeLabelController";
|
||||
import { authenticateToken } from "../middleware/authMiddleware";
|
||||
|
||||
const router = Router();
|
||||
|
||||
router.use(authenticateToken);
|
||||
|
||||
router.get("/", (req, res, next) =>
|
||||
barcodeLabelController.getLabels(req, res, next)
|
||||
);
|
||||
router.get("/templates", (req, res, next) =>
|
||||
barcodeLabelController.getTemplates(req, res, next)
|
||||
);
|
||||
router.get("/templates/:templateId", (req, res, next) =>
|
||||
barcodeLabelController.getTemplateById(req, res, next)
|
||||
);
|
||||
router.post("/", (req, res, next) =>
|
||||
barcodeLabelController.createLabel(req, res, next)
|
||||
);
|
||||
|
||||
router.get("/:labelId", (req, res, next) =>
|
||||
barcodeLabelController.getLabelById(req, res, next)
|
||||
);
|
||||
router.get("/:labelId/layout", (req, res, next) =>
|
||||
barcodeLabelController.getLayout(req, res, next)
|
||||
);
|
||||
router.put("/:labelId", (req, res, next) =>
|
||||
barcodeLabelController.updateLabel(req, res, next)
|
||||
);
|
||||
router.put("/:labelId/layout", (req, res, next) =>
|
||||
barcodeLabelController.saveLayout(req, res, next)
|
||||
);
|
||||
router.delete("/:labelId", (req, res, next) =>
|
||||
barcodeLabelController.deleteLabel(req, res, next)
|
||||
);
|
||||
router.post("/:labelId/copy", (req, res, next) =>
|
||||
barcodeLabelController.copyLabel(req, res, next)
|
||||
);
|
||||
|
||||
export default router;
|
||||
Reference in New Issue
Block a user