15 lines
243 B
Go
15 lines
243 B
Go
|
// course
|
||
|
package models
|
||
|
|
||
|
type Course struct {
|
||
|
Id int
|
||
|
Name string
|
||
|
}
|
||
|
|
||
|
type CourseRepository interface {
|
||
|
FindByName(name string) (Course, error)
|
||
|
GetAll() ([]Course, error)
|
||
|
FindById(id int) (Course, error)
|
||
|
GetActive() ([]Course, error)
|
||
|
}
|