modified: main_dc/yalarba/api_yal/internal/models/base.go
modified: "main_dc/yalarba/api_yal/internal/models/\320\276bject.go" delete UpdateHistory from base struct
This commit is contained in:
@@ -10,5 +10,4 @@ type Base struct {
|
|||||||
CreatedAt time.Time `json:"created_at,omitempty"`
|
CreatedAt time.Time `json:"created_at,omitempty"`
|
||||||
UpdatedAt time.Time `json:"updated_at,omitempty"`
|
UpdatedAt time.Time `json:"updated_at,omitempty"`
|
||||||
DeletedAt gorm.DeletedAt `gorm:"index" json:"-"`
|
DeletedAt gorm.DeletedAt `gorm:"index" json:"-"`
|
||||||
UpdateHistories []UpdateHistory `gorm:"polymorphic:Model" json:"-"`
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -7,11 +7,12 @@ type Object struct {
|
|||||||
Base Base `gorm:"embedded"`
|
Base Base `gorm:"embedded"`
|
||||||
|
|
||||||
// owner account ID
|
// owner account ID
|
||||||
Owner Account `gorm:"foreignKey:OwnerID" json:"owner"`
|
Owner Account `gorm:"foreignKey:OwnerID" json:"owner"`
|
||||||
|
AccountID uint `gorm:"not null" json:"account_id"`
|
||||||
|
|
||||||
// Основная информация
|
// Основная информация
|
||||||
Short_Name string `gorm:"not null" json:"name"`
|
ShortName string `gorm:"not null" json:"short_name"`
|
||||||
Long_Name string `json:"long_name"`
|
LongName string `json:"long_name"`
|
||||||
Type string `json:"type"`
|
Type string `json:"type"`
|
||||||
Phone string `json:"phone"`
|
Phone string `json:"phone"`
|
||||||
Email string `json:"email"`
|
Email string `json:"email"`
|
||||||
|
|||||||
Reference in New Issue
Block a user