fix
This commit is contained in:
parent
01cc115a60
commit
f7992279e2
|
@ -59,7 +59,10 @@ func (l *GetSizeByPidLogic) GetSizeByPid(req *types.GetSizeByPidReq, userinfo *a
|
|||
} else {
|
||||
//根据模板找到模型sizeId
|
||||
defaultModel3d, err := l.svcCtx.AllModels.FsProductModel3d.FindOne(l.ctx, *defaultTemplate.ModelId, "size_id")
|
||||
if err != nil && !errors.Is(err, gorm.ErrRecordNotFound) {
|
||||
if err != nil {
|
||||
if errors.Is(err, gorm.ErrRecordNotFound) {
|
||||
return resp.SetStatusWithMessage(basic.CodeDbSqlErr, "the template`s model is not exists ")
|
||||
}
|
||||
logx.Error(err)
|
||||
return resp.SetStatusWithMessage(basic.CodeDbSqlErr, "failed to get default model ")
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user