import express from "express";
import { getMonitorings, getMonitoringById,monitoringStudentsProgress, monitoringStudentProgressById, getMonitoringByTopicId, monitoringFeedback } from "../../controllers/monitoringControllers/monitoring.js";
import { verifyLoginUser, adminOrTeacherOnly } from "../../middlewares/User/authUser.js";

const router = express.Router();

router.get("/monitoring", verifyLoginUser, getMonitorings);

router.get("/monitoring/progress", verifyLoginUser, adminOrTeacherOnly, monitoringStudentsProgress);

router.get("/monitoring/:id", verifyLoginUser, getMonitoringById);

router.get("/monitoring/topic/:topicId", verifyLoginUser, getMonitoringByTopicId);

router.get("/monitoring/progress/:id", verifyLoginUser, adminOrTeacherOnly, monitoringStudentProgressById);

router.post("/monitoring/feedback/:id", verifyLoginUser, adminOrTeacherOnly, monitoringFeedback);

export default router