|
@@ -27,6 +27,14 @@ func NewSupplySearchLogic(ctx context.Context, svcCtx *svc.ServiceContext) *Supp
|
|
|
}
|
|
|
|
|
|
func (l *SupplySearchLogic) SupplySearch(req *types.PubSupplyInfoReq) (resp *types.CommonRes, err error) {
|
|
|
+ //默认每页五十条
|
|
|
+ if req.PageSize == 0 {
|
|
|
+ req.PageSize = 50
|
|
|
+ }
|
|
|
+ //默认第一页
|
|
|
+ if req.PageIndex == 0 {
|
|
|
+ req.PageIndex = 1
|
|
|
+ }
|
|
|
supplySearch, err0 := l.svcCtx.Consumer.SupplyInfoSearch(l.ctx, &consumer.SupplyInfoSearchReq{
|
|
|
Keywords: req.Keywords,
|
|
|
SearchType: req.SearchType,
|