diff --git a/software/backend/data/bands.json b/software/backend/data/bands.json
index 4e3f29b..d2f45d5 100644
--- a/software/backend/data/bands.json
+++ b/software/backend/data/bands.json
@@ -426,6 +426,59 @@
"bandId": 6
}
]
+ },
+ {
+ "id": 7,
+ "name": "Muse",
+ "foundingYear": 1994,
+ "descriptionEn": "Muse are an English rock band from Teignmouth, Devon, formed in 1994. The band consists of Matt Bellamy (lead vocals, guitar, keyboards), Chris Wolstenholme (bass guitar, backing vocals), and Dominic Howard (drums, percussion).",
+ "descriptionDe": "Muse ist eine britische Rockband, die 1994 in Teignmouth, England gegründet wurde. Die Band besteht aus Matthew Bellamy (Gesang, Gitarre, Klavier und Synthesizers), Chris Wolstenholme (E-Bass, Gesang, Synthesizer) und Dominic Howard (Schlagzeug und Perkussion). Muse verbindet stilistisch Alternative, Hard und Progressive Rock sowie Electronica mit Elementen klassischer Musik zu Rockballaden und wird dem Subgenre New Prog zugeordnet.",
+ "images": [
+ "muse-1.jpg",
+ "muse-2.jpg",
+ "muse-3.jpg"
+ ],
+ "imageMembers": "muse-members.jpg",
+ "logo": "muse-logo.jpg",
+ "genreId": [
+ 2,
+ 15,
+ 16
+ ],
+ "members": [
+ {
+ "name": "Matthew Bellamy",
+ "bandId": 7,
+ "image": "matthew-bellamy.jpg"
+ },
+ {
+ "name": "Dominic Howard",
+ "bandId": 7,
+ "image": "dominic-howard.jpg"
+ },
+ {
+ "name": "Chris Wolstenholme",
+ "bandId": 7,
+ "image": "christ-wolstenholme.jpg"
+ }
+ ],
+ "ratings": [
+ {
+ "accountId": 0,
+ "rating": 5,
+ "bandId": 7
+ },
+ {
+ "accountId": 1,
+ "rating": 4,
+ "bandId": 7
+ },
+ {
+ "accountId": 2,
+ "rating": 4,
+ "bandId": 7
+ }
+ ]
}
]
}
\ No newline at end of file
diff --git a/software/backend/data/cities.json b/software/backend/data/cities.json
index be2eb6d..160f976 100644
--- a/software/backend/data/cities.json
+++ b/software/backend/data/cities.json
@@ -4,7 +4,6 @@
"id": 0,
"name": "Hannover",
"country": "Germany",
- "image": "hannover.jpg",
"locations": [
{
"id": 0,
@@ -40,7 +39,6 @@
"id": 1,
"name": "München",
"country": "Germany",
- "image": "munich.jpg",
"locations": [
{
"id": 4,
@@ -69,7 +67,6 @@
"id": 2,
"name": "Hamburg",
"country": "Germany",
- "image": "hamburg.jpg",
"locations": [
{
"id": 7,
@@ -105,7 +102,6 @@
"id": 3,
"name": "Berlin",
"country": "Germany",
- "image": "berlin.jpg",
"locations": [
{
"id": 11,
diff --git a/software/backend/data/genres.json b/software/backend/data/genres.json
index 2cc9a75..54023b7 100644
--- a/software/backend/data/genres.json
+++ b/software/backend/data/genres.json
@@ -59,6 +59,14 @@
{
"id": 14,
"name": "Bluesrock"
+ },
+ {
+ "id": 15,
+ "name": "New Prog"
+ },
+ {
+ "id": 16,
+ "name": "Hard Rock"
}
]
}
\ No newline at end of file
diff --git a/software/backend/data/tours.json b/software/backend/data/tours.json
index f15ec81..4320f38 100644
--- a/software/backend/data/tours.json
+++ b/software/backend/data/tours.json
@@ -11,12 +11,20 @@
"id": 0,
"date": "2024-10-18",
"price": 92,
- "inStock": 930,
+ "inStock": 0,
"locationId": 0,
"tourId": 0
},
{
"id": 1,
+ "date": "2024-10-19",
+ "price": 92,
+ "inStock": 170,
+ "locationId": 0,
+ "tourId": 0
+ },
+ {
+ "id": 2,
"date": "2024-10-23",
"price": 119.90,
"inStock": 8736,
@@ -24,7 +32,7 @@
"tourId": 0
},
{
- "id": 2,
+ "id": 3,
"date": "2024-10-26",
"price": 114.90,
"inStock": 2793,
@@ -32,7 +40,7 @@
"tourId": 0
},
{
- "id": 3,
+ "id": 4,
"date": "2024-11-02",
"price": 124.90,
"inStock": 3079,
@@ -49,7 +57,7 @@
"image": "the-bends-tour.jpg",
"concerts": [
{
- "id": 4,
+ "id": 5,
"date": "2024-11-30",
"price": 108,
"inStock": 1200,
@@ -57,7 +65,7 @@
"tourId": 1
},
{
- "id": 5,
+ "id": 6,
"date": "2024-12-01",
"price": 104,
"inStock": 1800,
@@ -65,7 +73,7 @@
"tourId": 1
},
{
- "id": 6,
+ "id": 7,
"date": "2024-12-07",
"price": 99.90,
"inStock": 2438,
@@ -82,7 +90,7 @@
"image": "european-tour-arctic-monkeys.jpg",
"concerts": [
{
- "id": 7,
+ "id": 8,
"date": "2025-01-21",
"price": 67.90,
"inStock": 994,
@@ -90,7 +98,7 @@
"tourId": 2
},
{
- "id": 8,
+ "id": 9,
"date": "2024-11-15",
"price": 79.90,
"inStock": 1073,
@@ -107,7 +115,7 @@
"image": "music-of-the-spheres.png",
"concerts": [
{
- "id": 9,
+ "id": 10,
"date": "2024-12-07",
"price": 124.90,
"inStock": 765,
@@ -115,7 +123,7 @@
"tourId": 3
},
{
- "id": 10,
+ "id": 11,
"date": "2025-01-17",
"price": 129.90,
"inStock": 989,
@@ -123,7 +131,7 @@
"tourId": 3
},
{
- "id": 11,
+ "id": 12,
"date": "2025-02-01",
"price": 134.90,
"inStock": 827,
@@ -140,7 +148,7 @@
"image": "but-here-we-are.jpg",
"concerts": [
{
- "id": 12,
+ "id": 13,
"date": "2024-12-05",
"price": 80,
"inStock": 99,
@@ -157,7 +165,7 @@
"image": "crisis-of-faith-tour.jpg",
"concerts": [
{
- "id": 13,
+ "id": 14,
"date": "2025-01-12",
"price": 81.90,
"inStock": 173,
@@ -165,7 +173,7 @@
"tourId": 5
},
{
- "id": 14,
+ "id": 15,
"date": "2025-02-01",
"price": 84.90,
"inStock": 192,
@@ -182,7 +190,7 @@
"image": "back-to-the-water-below.jpg",
"concerts": [
{
- "id": 15,
+ "id": 16,
"date": "2025-02-27",
"price": 67.90,
"inStock": 847,
@@ -190,7 +198,7 @@
"tourId": 6
},
{
- "id": 16,
+ "id": 17,
"date": "2025-03-06",
"price": 64.90,
"inStock": 245,
@@ -198,6 +206,47 @@
"tourId": 6
}
]
+ },
+ {
+ "id": 7,
+ "name": "Will of the People Tour",
+ "bandId": 7,
+ "offered": true,
+ "image": "will-of-the-people-tour.jpg",
+ "concerts": [
+ {
+ "id": 18,
+ "date": "2025-01-15",
+ "price": 67.90,
+ "inStock": 847,
+ "locationId": 2,
+ "tourId": 7
+ },
+ {
+ "id": 19,
+ "date": "2025-01-23",
+ "price": 64.90,
+ "inStock": 245,
+ "locationId": 10,
+ "tourId": 7
+ },
+ {
+ "id": 20,
+ "date": "2025-02-02",
+ "price": 64.90,
+ "inStock": 245,
+ "locationId": 13,
+ "tourId": 7
+ },
+ {
+ "id": 21,
+ "date": "2025-02-05",
+ "price": 64.90,
+ "inStock": 245,
+ "locationId": 13,
+ "tourId": 7
+ }
+ ]
}
]
}
\ No newline at end of file
diff --git a/software/backend/images/bands/muse-1.jpg b/software/backend/images/bands/muse-1.jpg
new file mode 100644
index 0000000..5687fb1
Binary files /dev/null and b/software/backend/images/bands/muse-1.jpg differ
diff --git a/software/backend/images/bands/muse-2.jpg b/software/backend/images/bands/muse-2.jpg
new file mode 100644
index 0000000..ebd9c13
Binary files /dev/null and b/software/backend/images/bands/muse-2.jpg differ
diff --git a/software/backend/images/bands/muse-3.jpg b/software/backend/images/bands/muse-3.jpg
new file mode 100644
index 0000000..646267f
Binary files /dev/null and b/software/backend/images/bands/muse-3.jpg differ
diff --git a/software/backend/images/bands/muse-logo.jpg b/software/backend/images/bands/muse-logo.jpg
new file mode 100644
index 0000000..2fcb537
Binary files /dev/null and b/software/backend/images/bands/muse-logo.jpg differ
diff --git a/software/backend/images/bands/muse-members.jpg b/software/backend/images/bands/muse-members.jpg
new file mode 100644
index 0000000..ac533fd
Binary files /dev/null and b/software/backend/images/bands/muse-members.jpg differ
diff --git a/software/backend/images/cities/berlin.jpg b/software/backend/images/cities/berlin.jpg
deleted file mode 100644
index 4637812..0000000
Binary files a/software/backend/images/cities/berlin.jpg and /dev/null differ
diff --git a/software/backend/images/cities/hamburg.jpg b/software/backend/images/cities/hamburg.jpg
deleted file mode 100644
index 13982ca..0000000
Binary files a/software/backend/images/cities/hamburg.jpg and /dev/null differ
diff --git a/software/backend/images/cities/hannover.jpg b/software/backend/images/cities/hannover.jpg
deleted file mode 100644
index 7a0bc93..0000000
Binary files a/software/backend/images/cities/hannover.jpg and /dev/null differ
diff --git a/software/backend/images/cities/munich.jpg b/software/backend/images/cities/munich.jpg
deleted file mode 100644
index 85f398a..0000000
Binary files a/software/backend/images/cities/munich.jpg and /dev/null differ
diff --git a/software/backend/images/tours/will-of-the-people-tour.jpg b/software/backend/images/tours/will-of-the-people-tour.jpg
new file mode 100644
index 0000000..a784102
Binary files /dev/null and b/software/backend/images/tours/will-of-the-people-tour.jpg differ
diff --git a/software/backend/models/acts/city.model.ts b/software/backend/models/acts/city.model.ts
index c4a71bc..fe574d8 100644
--- a/software/backend/models/acts/city.model.ts
+++ b/software/backend/models/acts/city.model.ts
@@ -9,9 +9,6 @@ export class City extends Model {
@Column
country: String
- @Column
- image: String
-
// Relations
diff --git a/software/backend/models/acts/location.model.ts b/software/backend/models/acts/location.model.ts
index 71df8ee..2cbf405 100644
--- a/software/backend/models/acts/location.model.ts
+++ b/software/backend/models/acts/location.model.ts
@@ -21,7 +21,7 @@ export class Location extends Model {
// Relations
@HasMany(() => Concert)
- shows: Concert[]
+ concerts: Concert[]
@BelongsTo(() => City)
city: City
diff --git a/software/backend/routes/city.routes.ts b/software/backend/routes/city.routes.ts
index 2cf3400..00db191 100644
--- a/software/backend/routes/city.routes.ts
+++ b/software/backend/routes/city.routes.ts
@@ -1,14 +1,26 @@
import { Location } from "../models/acts/location.model";
import { City } from "../models/acts/city.model";
import { Request, Response, Router } from "express";
+import { Concert } from "../models/acts/concert.model";
export const city = Router()
city.get("/", (req: Request, res: Response) => {
City.findAll({
- include: [ Location ]
+ include: [
+ {
+ model: Location,
+ include: [ Concert ]
+ }
+ ]
})
.then(cities => {
+ for (let city of cities) {
+ for (let location of city.dataValues.locations) {
+ location.dataValues.nrOfConcerts = location.dataValues.concerts.length
+ delete location.dataValues.concerts
+ }
+ }
res.status(200).json(cities)
})
})
\ No newline at end of file
diff --git a/software/backend/routes/location.routes.ts b/software/backend/routes/location.routes.ts
index 56077b6..0b7bb9e 100644
--- a/software/backend/routes/location.routes.ts
+++ b/software/backend/routes/location.routes.ts
@@ -1,17 +1,41 @@
+import { Concert } from "../models/acts/concert.model";
import { City } from "../models/acts/city.model";
import { Location } from "../models/acts/location.model";
import { Request, Response, Router } from "express";
+import { Tour } from "../models/acts/tour.model";
+import { Band } from "../models/acts/band.model";
export const location = Router()
location.get("/", (req: Request, res: Response) => {
Location.findAll({
- include: [ City ],
+ include: [
+ City,
+ {
+ model: Concert,
+ include: [ Tour ],
+ attributes: {
+ exclude: [ "locationId", "tourId" ]
+ }
+ }
+ ],
attributes: {
exclude: [ "cityId" ]
}
})
- .then(locations => {
+ .then(async locations => {
+ for (let location of locations) {
+ for (let concert of location.dataValues.concerts) {
+ let tour = concert.dataValues.tour
+
+ await Band.findByPk(tour.dataValues.bandId)
+ .then(band => {
+ tour.dataValues.bandName = band.dataValues.name
+ delete tour.dataValues.bandId
+ })
+ }
+ }
+
res.status(200).json(locations)
})
})
\ No newline at end of file
diff --git a/software/src/components/navigation/navigationPrependItems.vue b/software/src/components/navigation/navigationPrependItems.vue
index 1c8527c..9a4464d 100644
--- a/software/src/components/navigation/navigationPrependItems.vue
+++ b/software/src/components/navigation/navigationPrependItems.vue
@@ -10,12 +10,12 @@
{{ location.name }} {{ location.address }} {{ location.city.name }} {{ band.name }} {{ band.descriptionDe }}