Datenbanken, erster Versuch

This commit is contained in:
Gonne 2022-08-29 22:58:19 +02:00
parent b26544756a
commit 766aedf22d
21 changed files with 678 additions and 320 deletions

23
models/officeHour.go Normal file
View file

@ -0,0 +1,23 @@
// officeHour
package models
type OfficeHour struct {
Id int
Tutor Tutor
Week int
Date
Room Room
Course Course
Info string
Active bool
Duration int
}
type OfficeHourRepository interface {
FindById(id int) (OfficeHour, error)
FindByCourse(course Course) ([]OfficeHour, error)
FindByRoom(room Room) ([]OfficeHour, error)
GetAll() ([]OfficeHour, error)
Delete(officeHour OfficeHour) error
Add(officeHour OfficeHour) error
}