feat (unit, division-position): add preload
This commit is contained in:
No files matched your search
@@ -40,6 +40,7 @@ func ReadListData(input e.ReadListDto, dbx ...*gorm.DB) ([]e.DivisionPosition, *
|
||||
Model(&e.DivisionPosition{}).
|
||||
// Joins("Patient"). // if needed
|
||||
// Preload("Patient"). // if needed
|
||||
Preload("Division"). // if needed
|
||||
Scopes(gh.Filter(input)).
|
||||
Count(&count).
|
||||
Scopes(gh.Paginate(input, &pagination)).
|
||||
|
||||
@@ -40,6 +40,7 @@ func ReadListData(input e.ReadListDto, dbx ...*gorm.DB) ([]e.Unit, *e.MetaDto, e
|
||||
Model(&e.Unit{}).
|
||||
// Joins("Patient"). // if needed
|
||||
// Preload("Patient"). // if needed
|
||||
Preload("Installation"). // if needed
|
||||
Scopes(gh.Filter(input)).
|
||||
Count(&count).
|
||||
Scopes(gh.Paginate(input, &pagination)).
|
||||
|
||||
Reference in New Issue
Block a user