Răsfoiți Sursa

Merge branch 'dev/v1.1.18.2_wh' of BaseService/jyMicroservices into hotfix/v1.1.18.2

王浩 2 ani în urmă
părinte
comite
55316ac46c
1 a modificat fișierele cu 8 adăugiri și 4 ștergeri
  1. 8 4
      jyBXSubscribe/api/internal/logic/subscribeListLogic.go

+ 8 - 4
jyBXSubscribe/api/internal/logic/subscribeListLogic.go

@@ -3,13 +3,13 @@ package logic
 import (
 	"app.yhyue.com/moapp/jybase/common"
 	"context"
+	"github.com/gogf/gf/v2/util/gconv"
+	"github.com/zeromicro/go-zero/core/logx"
 	"jyBXSubscribe/api/internal/svc"
 	"jyBXSubscribe/api/internal/types"
 	"jyBXSubscribe/rpc/type/bxsubscribe"
 	"net/http"
 	"strings"
-
-	"github.com/zeromicro/go-zero/core/logx"
 )
 
 type SubscribeListLogic struct {
@@ -38,10 +38,14 @@ func (l *SubscribeListLogic) SubscribeList(req *types.SubscribeReq) (resp *types
 	matchkeys := ""
 	if req.IsEnt {
 		for k, v := range req.Item {
-			if common.InterfaceToStr(v) == "" {
+			//类型换换
+			keyArr := gconv.Strings(v)
+			if len(keyArr) == 0 {
 				matchitemsArr = append(matchitemsArr, common.InterfaceToStr(k))
 			} else {
-				matchkeysArr = append(matchkeysArr, common.InterfaceToStr(v))
+				for _, s := range keyArr {
+					matchkeysArr = append(matchkeysArr, s)
+				}
 			}
 		}
 		if len(matchitemsArr) == 0 {