Rewriting database and API to transform to a ticket shop
This commit is contained in:
11
software/backend/routes/show.routes.ts
Normal file
11
software/backend/routes/show.routes.ts
Normal file
@@ -0,0 +1,11 @@
|
||||
import { Show } from "../models/show.model";
|
||||
import { Request, Response, Router } from "express";
|
||||
|
||||
export const show = Router()
|
||||
|
||||
show.get("/", (req: Request, res: Response) => {
|
||||
Show.findAll()
|
||||
.then(shows => {
|
||||
res.status(200).json(shows)
|
||||
})
|
||||
})
|
||||
Reference in New Issue
Block a user