9 lines
346 B
JavaScript
9 lines
346 B
JavaScript
module.exports = app => {
|
|
const cohort = require("../controllers/cohort.controller.js");
|
|
var router = require("express").Router();
|
|
router.get("/:id", cohort.getCohortForId);
|
|
router.delete("/:id", cohort.deleteCohort);
|
|
router.put("/:id", cohort.updateCohort);
|
|
router.post("/all", cohort.getAllCohorts);
|
|
app.use('/cohort', router);
|
|
}; |