Forráskód Böngészése

Merge branch 'dev/v1.1.49_wjh' of BaseService/jyMicroservices into feature/v1.1.49

wangjianghan 1 éve
szülő
commit
6a34170add
1 módosított fájl, 6 hozzáadás és 10 törlés
  1. 6 10
      jyBXSubscribe/rpc/model/push.go

+ 6 - 10
jyBXSubscribe/rpc/model/push.go

@@ -1503,11 +1503,9 @@ func (s *subscribePush) getFreeDatasSQL(bsp *ViewCondition, startTime, endTime i
 	boolsNum := 0 //should
 	if len(bsp.Keyword) > 0 {
 		boolsNum = 1
-		stype := ""
-		if len(bsp.SelectType) == 1 {
-			stype = bsp.SelectType[0]
-		} else {
-			stype = strings.Join(bsp.SelectType, "\",\"")
+		stype := strings.Join(bsp.SelectType, "\",\"")
+		if strings.Contains(stype, "projectname/purchasing") {
+			stype = strings.Replace(stype, "projectname/purchasing", "projectname,\",\"purchasing", -1)
 		}
 		multi_match = fmt.Sprintf(multi_match, "%s", "\""+stype+"\"")
 		for _, v := range bsp.Keyword {
@@ -1629,11 +1627,9 @@ func (s *subscribePush) getDefaultDatasSQL(bsp *ViewCondition) (str string) {
 	boolsNum := 0 //should
 	if len(bsp.Keyword) > 0 {
 		boolsNum = 1
-		stype := ""
-		if len(bsp.SelectType) == 1 {
-			stype = bsp.SelectType[0]
-		} else {
-			stype = strings.Join(bsp.SelectType, "\",\"")
+		stype := strings.Join(bsp.SelectType, "\",\"")
+		if strings.Contains(stype, "projectname/purchasing") {
+			stype = strings.Replace(stype, "projectname/purchasing", "projectname,\",\"purchasing", -1)
 		}
 		multi_match = fmt.Sprintf(multi_match, "%s", "\""+stype+"\"")
 		for _, v := range bsp.Keyword {