mirror of
https://github.com/GithubOrgProjectPiza/server.git
synced 2026-09-04 23:33:59 +02:00
Add routers
This commit is contained in:
+10
-1
@@ -1,9 +1,18 @@
|
||||
import express from "express";
|
||||
const app = express();
|
||||
|
||||
let testRoutes = require("./routes/testrouter.route");
|
||||
const testRoutes = require("./routes/testrouter.route");
|
||||
const ordersRoutes = require("./routes/orders.route");
|
||||
const organizationsRoutes = require("./routes/organisations.route");
|
||||
const pizzasRoutes = require("./routes/pizzas.route");
|
||||
const restaurantsRoutes = require("./routes/restaurants.route");
|
||||
|
||||
app.use(express.json());
|
||||
app.use("/tests", testRoutes);
|
||||
app.use("/order", ordersRoutes);
|
||||
app.use("/organization", organizationsRoutes);
|
||||
app.use("/pizza", pizzasRoutes);
|
||||
app.use("/restaurant", restaurantsRoutes);
|
||||
|
||||
async function main() {
|
||||
app.get("/", (req, res) => {
|
||||
|
||||
Reference in New Issue
Block a user