Add composers
This commit is contained in:
17
src/models/composer.go
Normal file
17
src/models/composer.go
Normal file
@@ -0,0 +1,17 @@
|
||||
package models
|
||||
|
||||
import (
|
||||
"time"
|
||||
|
||||
"github.com/google/uuid"
|
||||
"gorm.io/gorm"
|
||||
)
|
||||
|
||||
type Composer struct {
|
||||
Uuid uuid.UUID `json:"uuid" gorm:"type:uuid;primaryKey"`
|
||||
Name string `json:"name" gorm:"not null"`
|
||||
Bio string `json:"bio"`
|
||||
CreatedAt time.Time `json:"created_at"`
|
||||
UpdatedAt time.Time `json:"updated_at"`
|
||||
DeletedAt gorm.DeletedAt `json:"-" gorm:"index"`
|
||||
}
|
||||
@@ -8,7 +8,7 @@ import (
|
||||
)
|
||||
|
||||
type Sheet struct {
|
||||
Uuid uuid.UUID `json:"uuid" gorm:"primaryKey"`
|
||||
Uuid uuid.UUID `json:"uuid" gorm:"type:uuid;primaryKey"`
|
||||
Title string `json:"title" gorm:"not null"`
|
||||
Composer string `json:"composer"`
|
||||
Description string `json:"description"`
|
||||
|
||||
Reference in New Issue
Block a user