Initial API and entities for link sharing

Signed-off-by: Michael Mayer <michael@liquidbytes.net>
This commit is contained in:
Michael Mayer
2020-04-08 13:24:06 +02:00
parent f1e2d86e7c
commit a8c48ab40e
24 changed files with 419 additions and 82 deletions

View File

@@ -22,6 +22,7 @@ type Label struct {
LabelDescription string `gorm:"type:text;"`
LabelNotes string `gorm:"type:text;"`
LabelCategories []*Label `gorm:"many2many:categories;association_jointable_foreignkey:category_id"`
Links []Link `gorm:"foreignkey:ShareUUID;association_foreignkey:LabelUUID"`
CreatedAt time.Time
UpdatedAt time.Time
DeletedAt *time.Time `sql:"index"`