Jianghan 9 сар өмнө
parent
commit
84fa7f1487

+ 3 - 3
jy_forecast/main.go

@@ -30,10 +30,10 @@ func init() {
 	MongoTool.InitPool()
 	MongoTool.InitPool()
 
 
 	Es = &elastic.Elastic{
 	Es = &elastic.Elastic{
-		S_esurl:  "http://172.17.162.27:19805", //http://172.17.4.184:19800
+		S_esurl:  "http://172.17.162.27:19908", //http://172.17.4.184:19800
 		I_size:   10,
 		I_size:   10,
-		Username: "es_all",
-		Password: "TopJkO2E_d1x",
+		Username: "dataGr_appli",
+		Password: "L2ds90Ha4e5#",
 	}
 	}
 	Es.InitElasticSize()
 	Es.InitElasticSize()
 
 

+ 10 - 0
jy_forecast/task.go

@@ -134,6 +134,16 @@ func taskInfoA(searchResult *es.SearchResult, wg *sync.WaitGroup, countDocs *int
 					arr = append(arr, p)
 					arr = append(arr, p)
 				}
 				}
 				tpmp["p_projects"] = arr
 				tpmp["p_projects"] = arr
+				if tmp["bidamount"] != nil {
+					save["sortprice"] = tmp["bidamount"]
+					save["bidamount"] = tmp["bidamount"]
+					if save["budget"] != nil {
+						save["budget"] = tmp["budget"]
+					}
+				} else if tmp["budget"] != nil {
+					save["sortprice"] = tmp["budget"]
+					save["budget"] = tmp["budget"]
+				}
 				delete(save, "buyerperson")
 				delete(save, "buyerperson")
 				delete(save, "buyertel")
 				delete(save, "buyertel")
 				save["results"] = append([]map[string]interface{}{}, tpmp)
 				save["results"] = append([]map[string]interface{}{}, tpmp)

+ 2 - 1
jy_member/service.go

@@ -43,12 +43,13 @@ type FcResponse struct {
 }
 }
 
 
 func (j *JyService) Download(req AtRequest, res *AtResponse) error {
 func (j *JyService) Download(req AtRequest, res *AtResponse) error {
-	//util.Debug("Download----infoid:", req.InfoId)
+	util.Debug("Download----infoid:", req.InfoId)
 	if req.InfoId == "" {
 	if req.InfoId == "" {
 		return fmt.Errorf(" _id error")
 		return fmt.Errorf(" _id error")
 	}
 	}
 	var err error
 	var err error
 	res.Rep, err = Method(req.InfoId)
 	res.Rep, err = Method(req.InfoId)
+	util.Debug(res.Rep)
 	return err
 	return err
 }
 }