const express = require('express');
const router = express.Router();
const { protect } = require('../middleware/auth');
const { addSalary, getSalaries, getSalaryById, updateSalary, deleteSalary } = require('../controllers/salaryController');

router.use(protect);
router.post('/add', addSalary);
router.get('/list', getSalaries);
router.get('/:id', getSalaryById);
router.put('/update/:id', updateSalary);
router.delete('/delete/:id', deleteSalary);

module.exports = router;
