const express = require('express');
const router = express.Router();
const {
  createOrUpdateMonthlyExpense,
  getMonthlyExpenses,getMonthlyAllBranchExpenses
} = require('../controllers/monthlyExpenseController');

// Route to get a specific monthly expense based on companyId and branchId
router.get('/', getMonthlyExpenses);
router.get('/all', getMonthlyAllBranchExpenses);

// Route to create or update a monthly expense
router.post('/', createOrUpdateMonthlyExpense);

module.exports = router;
