added frontent authentication,backend ticket service, frontend ticket creation

This commit is contained in:
QkoSad
2022-12-10 11:15:53 +02:00
parent 8fd0b86492
commit 885cdfa7fe
34 changed files with 31084 additions and 1 deletions
+21
View File
@@ -0,0 +1,21 @@
const express = require("express");
const router = express.Router();
const {
getTicket,
getTickets,
createTicket,
deleteTicket,
updateTicket,
} = require("../controllers/ticketController");
const protect = require("../middleware/authMiddleware");
router.route("/").get(protect, getTickets).post(protect, createTicket);
router
.route("/:id")
.get(protect, getTicket)
.delete(protect, deleteTicket)
.put(protect, updateTicket);
module.exports = router;