const express = require("express");
const router = express.Router();
const {
  ambilSemua,
  ambilDetail,
  tambahOrder,
  hapusOrder,
} = require("./controller.js");
const { verifyToken } = require("../Middleware/token.js");

router.get("/", ambilSemua);
router.get("/detail/:id", ambilDetail);
router.post("/tambah", verifyToken, tambahOrder);
router.delete("/delete/:id", hapusOrder);

module.exports = router;
