Adding Seat plan component and database tables
This commit is contained in:
16
software/src/data/models/locations/cityModel.ts
Normal file
16
software/src/data/models/locations/cityModel.ts
Normal file
@@ -0,0 +1,16 @@
|
||||
/**
|
||||
* Replica of the API endpoint /cities
|
||||
*/
|
||||
export class CityModel {
|
||||
id: number
|
||||
name: string
|
||||
country: string
|
||||
image: string
|
||||
locations: Array<{
|
||||
id: number
|
||||
name: string
|
||||
address: string
|
||||
image: string
|
||||
nrOfConcerts: number
|
||||
}>
|
||||
}
|
||||
29
software/src/data/models/locations/locationModel.ts
Normal file
29
software/src/data/models/locations/locationModel.ts
Normal file
@@ -0,0 +1,29 @@
|
||||
import { SeatGroupModel } from "./seatGroupModel"
|
||||
|
||||
/**
|
||||
* Replica of the API endpoint /locations
|
||||
*/
|
||||
export class LocationModel {
|
||||
id: number
|
||||
name: string
|
||||
address: string
|
||||
image: string
|
||||
seatSchema: string
|
||||
city: {
|
||||
name: string
|
||||
country: string
|
||||
}
|
||||
concerts: Array<{
|
||||
id: number
|
||||
date: string
|
||||
price: number
|
||||
inStock: number
|
||||
tour: {
|
||||
name: string
|
||||
offered: boolean
|
||||
image: string
|
||||
bandName: string
|
||||
}
|
||||
}>
|
||||
seatGroups: Array<SeatGroupModel>
|
||||
}
|
||||
9
software/src/data/models/locations/seatGroupModel.ts
Normal file
9
software/src/data/models/locations/seatGroupModel.ts
Normal file
@@ -0,0 +1,9 @@
|
||||
import { SeatRowModel } from "./seatRowModel"
|
||||
|
||||
export class SeatGroupModel {
|
||||
name: string
|
||||
surcharge: number
|
||||
standingArea: Boolean
|
||||
capacity: number
|
||||
seatRows: Array<SeatRowModel>
|
||||
}
|
||||
4
software/src/data/models/locations/seatModel.ts
Normal file
4
software/src/data/models/locations/seatModel.ts
Normal file
@@ -0,0 +1,4 @@
|
||||
export class SeatModel {
|
||||
id: number
|
||||
seatNr: string
|
||||
}
|
||||
6
software/src/data/models/locations/seatRowModel.ts
Normal file
6
software/src/data/models/locations/seatRowModel.ts
Normal file
@@ -0,0 +1,6 @@
|
||||
import { SeatModel } from "./seatModel"
|
||||
|
||||
export class SeatRowModel {
|
||||
row: number
|
||||
seats: Array<SeatModel>
|
||||
}
|
||||
Reference in New Issue
Block a user