1
This commit is contained in:
parent
d4b6ef5d7c
commit
b03f87c919
|
@ -56,7 +56,7 @@ func (l *HomePageRecommendProductListLogic) HomePageRecommendProductList(req *ty
|
|||
merchantInfo, err = l.svcCtx.AllModels.FsMerchantCategory.FindOne(l.ctx, req.MerchantType)
|
||||
if err != nil {
|
||||
if errors.Is(err, gorm.ErrRecordNotFound) {
|
||||
return resp.SetStatusWithMessage(basic.CodeDbRecordNotFoundErr, "the merchant category is not exists")
|
||||
return resp.SetStatusWithMessage(basic.CodeOK, "the merchant category is not exists", []interface{}{})
|
||||
}
|
||||
logx.Error(err)
|
||||
return resp.SetStatusWithMessage(basic.CodeDbSqlErr, "failed to get merchant category")
|
||||
|
@ -66,7 +66,7 @@ func (l *HomePageRecommendProductListLogic) HomePageRecommendProductList(req *ty
|
|||
merchantInfo, err = l.svcCtx.AllModels.FsMerchantCategory.FindDefualtOne(l.ctx)
|
||||
if err != nil {
|
||||
if errors.Is(err, gorm.ErrRecordNotFound) {
|
||||
return resp.SetStatusWithMessage(basic.CodeDbRecordNotFoundErr, "the default merchant category is not exists")
|
||||
return resp.SetStatusWithMessage(basic.CodeOK, "the default merchant category is not exists", []interface{}{})
|
||||
}
|
||||
logx.Error(err)
|
||||
return resp.SetStatusWithMessage(basic.CodeDbSqlErr, "failed to get default merchant category")
|
||||
|
|
Loading…
Reference in New Issue
Block a user