modified: main_dc/yalarba/api_yal/internal/models/account.go

modified:   "main_dc/yalarba/api_yal/internal/models/\320\276bject.go"
fix bag with updatfind object into account
This commit is contained in:
2026-02-11 06:51:36 +05:00
parent 9ae4eeb33f
commit 4014249d64
2 changed files with 1 additions and 2 deletions
@@ -29,5 +29,5 @@ type Account struct {
// Связь: один Account имеет много Objects // Связь: один Account имеет много Objects
Objects []Оbject `json:"objects"` // Обратная связь Objects []Object `gorm:"foreignKey:OwnerID" json:"objects,omitempty"`
} }
@@ -8,7 +8,6 @@ type Object struct {
// 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"`
// Основная информация // Основная информация
ShortName string `gorm:"not null" json:"short_name"` ShortName string `gorm:"not null" json:"short_name"`