mirror of
https://github.com/amigan/aim-oscar-server.git
synced 2024-11-21 20:19:47 -05:00
13 lines
337 B
Go
13 lines
337 B
Go
|
package models
|
||
|
|
||
|
import "github.com/uptrace/bun"
|
||
|
|
||
|
type Buddy struct {
|
||
|
bun.BaseModel `bun:"table:buddies"`
|
||
|
ID int `bun:",pk"`
|
||
|
SourceUIN int64 `bun:",notnull"`
|
||
|
Source *User `bun:"rel:has-one,join:source_uin=uin"`
|
||
|
WithUIN int64 `bun:",notnull"`
|
||
|
Target *User `bun:"rel:has-one,join:with_uin=uin"`
|
||
|
}
|