add new handlers for event and responsible tables

This commit is contained in:
Adrian Zürcher
2025-10-17 15:41:13 +02:00
parent 521896510d
commit 5d0496f1db
13 changed files with 989 additions and 556 deletions

View File

@@ -1,6 +0,0 @@
package models
type Attendees struct {
FirstName int `json:"firstName"`
LastName string `json:"lastName"`
}

View File

@@ -1,9 +1,9 @@
package models
type Event struct {
Id int `json:"id"`
Name string `json:"name"`
Date string `json:"date"`
Attendees []Attendees `json:"attendees"`
Count int `json:"count"`
Id int `json:"id"`
Name string `json:"name"`
Date string `json:"date"`
Attendees []Person `json:"attendees"`
Count int `json:"count"`
}

7
models/person.go Normal file
View File

@@ -0,0 +1,7 @@
package models
type Person struct {
Id int `json:"id,omitEmpty"`
FirstName string `json:"firstName"`
LastName string `json:"lastName"`
}