fix (subspecialist): change source, wrong query
This commit is contained in:
@@ -13,7 +13,7 @@ import (
|
|||||||
"gorm.io/gorm"
|
"gorm.io/gorm"
|
||||||
)
|
)
|
||||||
|
|
||||||
const source = "specialist"
|
const source = "subspecialist"
|
||||||
|
|
||||||
func Create(input e.CreateDto) (*d.Data, error) {
|
func Create(input e.CreateDto) (*d.Data, error) {
|
||||||
data := e.Subspecialist{}
|
data := e.Subspecialist{}
|
||||||
|
|||||||
@@ -90,7 +90,7 @@ func ReadDetailData(input e.ReadDetailDto, event *pl.Event, dbx ...*gorm.DB) (*e
|
|||||||
|
|
||||||
if err := tx.
|
if err := tx.
|
||||||
Scopes(gh.Preload(input.Includes)).
|
Scopes(gh.Preload(input.Includes)).
|
||||||
First(&data, input.Id).Error; err != nil {
|
First(&data).Error; err != nil {
|
||||||
if processedErr := pu.HandleReadError(err, event, source, input.Id, data); processedErr != nil {
|
if processedErr := pu.HandleReadError(err, event, source, input.Id, data); processedErr != nil {
|
||||||
return nil, processedErr
|
return nil, processedErr
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user