we have fixtures ladies and gentleman
This commit is contained in:
@@ -10,13 +10,13 @@ import (
|
||||
type League struct {
|
||||
bun.BaseModel `bun:"table:leagues,alias:l"`
|
||||
|
||||
ID int `bun:"id,pk,autoincrement"`
|
||||
Name string `bun:"name,unique,notnull"`
|
||||
ShortName string `bun:"short_name,unique,notnull"`
|
||||
Description string `bun:"description"`
|
||||
ID int `bun:"id,pk,autoincrement" json:"id"`
|
||||
Name string `bun:"name,unique,notnull" json:"name"`
|
||||
ShortName string `bun:"short_name,unique,notnull" json:"short_name"`
|
||||
Description string `bun:"description" json:"description"`
|
||||
|
||||
Seasons []Season `bun:"m2m:season_leagues,join:League=Season"`
|
||||
Teams []Team `bun:"m2m:team_participations,join:League=Team"`
|
||||
Seasons []Season `bun:"m2m:season_leagues,join:League=Season" json:"-"`
|
||||
Teams []Team `bun:"m2m:team_participations,join:League=Team" json:"-"`
|
||||
}
|
||||
|
||||
func GetLeagues(ctx context.Context, tx bun.Tx) ([]*League, error) {
|
||||
|
||||
Reference in New Issue
Block a user