fix
This commit is contained in:
parent
a9bec4c4fd
commit
0c3e93bba6
|
@ -51,12 +51,12 @@ func (l *GetTagProductListLogic) GetTagProductList(req *types.GetTagProductListR
|
|||
Level: 2, //等级是2的
|
||||
}
|
||||
//传入分类id
|
||||
if req.Cid > 0 {
|
||||
if req.BasicTagId > 0 {
|
||||
//获取该类行的levelprefix
|
||||
tagData, err := l.svcCtx.AllModels.FsTags.FindOne(l.ctx, req.Cid)
|
||||
tagData, err := l.svcCtx.AllModels.FsTags.FindOne(l.ctx, req.BasicTagId)
|
||||
if err != nil {
|
||||
if errors.Is(err, gorm.ErrRecordNotFound) {
|
||||
return resp.SetStatusWithMessage(basic.CodeDbRecordNotFoundErr, "param cid is invalid:record not found")
|
||||
return resp.SetStatusWithMessage(basic.CodeDbRecordNotFoundErr, "param BasicTagId is invalid:record not found")
|
||||
}
|
||||
logx.Error(err)
|
||||
return resp.SetStatusWithMessage(basic.CodeDbSqlErr, "failed to get tag info")
|
||||
|
|
|
@ -29,7 +29,7 @@ type GetRecommandProductListRsp struct {
|
|||
}
|
||||
|
||||
type GetTagProductListReq struct {
|
||||
Cid int64 `form:"cid,optional"` //分类id
|
||||
BasicTagId int64 `form:"basic_tag_id,optional"` //传入则以该分类为最高层分类查询
|
||||
MerchantType int64 `form:"merchant_type,optional"` //商户类型
|
||||
TemplateTag string `form:"template_tag,optional"` //模板标签
|
||||
WithProduct bool `form:"with_product,optional"` //是否携带分类下的产品
|
||||
|
|
|
@ -72,7 +72,7 @@ type GetRecommandProductListRsp {
|
|||
}
|
||||
//获取分类产品列表
|
||||
type GetTagProductListReq {
|
||||
Cid int64 `form:"cid,optional"` //分类id
|
||||
BasicTagId int64 `form:"basic_tag_id,optional"` //传入则以该分类为最高层分类查询
|
||||
MerchantType int64 `form:"merchant_type,optional"` //商户类型
|
||||
TemplateTag string `form:"template_tag,optional"` //模板标签
|
||||
WithProduct bool `form:"with_product,optional"` //是否携带分类下的产品
|
||||
|
|
Loading…
Reference in New Issue
Block a user