Parcourir la source

feat:p618调整

fuwencai il y a 7 mois
Parent
commit
1a7dadbfb3

+ 10 - 5
jyBXSubscribe/rpc/internal/logic/getsubsomeinfologic.go

@@ -144,16 +144,16 @@ func (l *GetSubSomeInfoLogic) GetSubSomeInfo(in *bxsubscribe.SomeInfoReq) (*bxsu
 					if o_buyset != nil {
 						resp.Data.Subsetinfo.Areacount = common.Int64All((*o_buyset)["areacount"])
 					}
-					resp.Data.Subsetinfo.Key = freegetsubKey(subinfo)
+					resp.Data.Subsetinfo.Key = paygetsubKey(subinfo)
 				case MemberFlag:
 					resp.Data.Subsetinfo.Areacount = -1
 					if common.Int64All(subinfo["i_areacount"]) > 0 {
 						resp.Data.Subsetinfo.Areacount = common.Int64All(subinfo["i_areacount"]) // 单省版大会员
 					}
-					resp.Data.Subsetinfo.Key = freegetsubKey(subinfo)
+					resp.Data.Subsetinfo.Key = paygetsubKey(subinfo)
 				case EntnicheFlag:
 					resp.Data.Subsetinfo.Areacount = -1
-					resp.Data.Subsetinfo.Key = freegetsubKey(subinfo)
+					resp.Data.Subsetinfo.Key = paygetsubKey(subinfo)
 				}
 			}
 			registedate := common.Int64All((*data)["l_registedate"])
@@ -199,8 +199,13 @@ func paygetsubKey(subinfo map[string]interface{}) (arr []string) {
 	for i := 0; i < len(a_key); i++ {
 		a_keyi := common.ObjToMap(a_key[i])
 		if a_keyi != nil {
-			a_keyiarr := (*a_keyi)["key"].([]interface{})
-			arr = append(arr, strings.Join(common.ObjArrToStringArr(a_keyiarr), " "))
+			if a_keyiarr, ok := (*a_keyi)["key"].([]interface{}); ok {
+				s := strings.Join(common.ObjArrToStringArr(a_keyiarr), " ")
+				if a_appendkeyiarr, ok := (*a_keyi)["appendkey"].([]interface{}); ok {
+					s += " " + strings.Join(common.ObjArrToStringArr(a_appendkeyiarr), " ")
+				}
+				arr = append(arr, s)
+			}
 		}
 	}
 	return

+ 25 - 0
jyBXSubscribe/test/618.http

@@ -2,6 +2,20 @@ POST https://jybx3-webtest.jydev.jianyu360.com/jyapi/jybx/subscribe/fType/someIn
 Content-Type: application/json
 Cookie: SESSIONID=5696788f98bb1cc7e24b9d2e6c4ba58c0ee38ddd
 
+###
+POST https://jybx3-webtest.jydev.jianyu360.com/jyapi/jybx/subscribe/mType/someInfo
+Content-Type: application/json
+Cookie: SESSIONID=5696788f98bb1cc7e24b9d2e6c4ba58c0ee38ddd
+
+###
+POST https://jybx3-webtest.jydev.jianyu360.com/jyapi/jybx/subscribe/vType/someInfo
+Content-Type: application/json
+Cookie: SESSIONID=5696788f98bb1cc7e24b9d2e6c4ba58c0ee38ddd
+
+###
+POST https://jybx3-webtest.jydev.jianyu360.com/jyapi/jybx/subscribe/eType/someInfo
+Content-Type: application/json
+Cookie: SESSIONID=5696788f98bb1cc7e24b9d2e6c4ba58c0ee38ddd
 
 ###
 POST https://jybx3-webtest.jydev.jianyu360.com/jyapi/jybx/subscribe/fType/saveTSGuide
@@ -14,3 +28,14 @@ Cookie: SESSIONID=5696788f98bb1cc7e24b9d2e6c4ba58c0ee38ddd
 }
 
 
+###
+POST https://jybx3-webtest.jydev.jianyu360.com/jyapi/jybx/subscribe/mType/saveTSGuide
+Content-Type: application/json
+Cookie: SESSIONID=5696788f98bb1cc7e24b9d2e6c4ba58c0ee38ddd
+
+{
+  "area": "{\"福建\" : [\"福州市\",\"厦门市\"],\"河南\" : []}",
+  "keywords": ["设备"]
+}
+
+