fix: unique entity
This commit is contained in:
@@ -19,7 +19,7 @@ type Subscribe struct {
|
||||
|
||||
type SubscribePlan struct {
|
||||
ID string `gorm:"primaryKey" json:"id"`
|
||||
Code string `gorm:"not null" json:"code"`
|
||||
Code string `gorm:"not null;unique" json:"code"`
|
||||
Name string `gorm:"not null" json:"name"`
|
||||
CreatedAt time.Time `gorm:"default:CURRENT_TIMESTAMP"`
|
||||
UpdatedAt time.Time `gorm:"default:CURRENT_TIMESTAMP"`
|
||||
|
||||
Reference in New Issue
Block a user