const express = require('express');
const router = express.Router();

const departmentController = require('../controllers/departmentController');
const { authMiddleware } = require('../middleware/authMiddleware');

router.post('/', authMiddleware, departmentController.createDepartment);
router.get('/', authMiddleware, departmentController.getAllDepartments);
router.put('/:id', authMiddleware, departmentController.updateDepartment);
router.delete('/:id', authMiddleware, departmentController.deleteDepartment);

module.exports = router;

