mirror of
https://gitlab.dit.htwk-leipzig.de/htwk-software/htwkalender.git
synced 2025-08-03 02:09:15 +02:00
refactor:#16 event saving shortened
This commit is contained in:
@@ -1,8 +1,11 @@
|
||||
package model
|
||||
|
||||
import "github.com/pocketbase/pocketbase/models"
|
||||
|
||||
type Events []*Event
|
||||
|
||||
type Event struct {
|
||||
UUID string `db:"UUID" json:"uuid"`
|
||||
Day string `db:"Day" json:"day"`
|
||||
Week string `db:"Week" json:"week"`
|
||||
Start string `db:"Start" json:"start"`
|
||||
@@ -15,4 +18,9 @@ type Event struct {
|
||||
BookedAt string `db:"BookedAt" json:"bookedAt"`
|
||||
Course string `db:"course" json:"course"`
|
||||
Semester string `db:"semester" json:"semester"`
|
||||
models.BaseModel
|
||||
}
|
||||
|
||||
func (m *Event) TableName() string {
|
||||
return "events"
|
||||
}
|
||||
|
Reference in New Issue
Block a user