5 лет назад
Родитель
Сommit
c2f15c57c7

BIN
fullproject/src_dev5.zip


+ 1 - 0
fullproject/src_dev5/main.go

@@ -21,6 +21,7 @@ func main() {
 	//udp强制拆分  项目id,信息id1,id2          qzcf
 	//udp重新合并  信息id1,id2,id3             cxhb
 	P_QL.loadData(0)
+	P_QL.taskQl(map[string]interface{}{})
 	time.Sleep(99999 * time.Hour)
 }
 

+ 7 - 5
fullproject/src_dev5/project.go

@@ -362,17 +362,19 @@ func (p *ProjectTask) compareBCTABB(info *Info, cp *ProjectInfo, diffTime int64,
 		compareBudget = "A"
 		score += 1
 		score2 += 1
-	} else if info.Budget == 0 && cp.Budget == 0 {
-		compareBudget = "B"
 	}
+	//	else if info.Budget == 0 && cp.Budget == 0 {
+	//		compareBudget = "B"
+	//	}
 	compareBidmount = "C"
 	if info.Bidamount > 0 && (info.Bidamount == cp.Bidamount || (cp.Budget > 0 && cp.Budget > info.Bidamount && (cp.Budget-info.Bidamount) < 0.1*cp.Budget)) {
 		compareBidmount = "A"
 		score += 1
 		score2 += 1
-	} else if info.Bidamount == 0 && cp.Bidamount == 0 {
-		compareBidmount = "B"
 	}
+	//	else if info.Bidamount == 0 && cp.Bidamount == 0 {
+	//		compareBidmount = "B"
+	//	}
 
 	cp.score = score
 	return
@@ -693,7 +695,7 @@ func (p *ProjectTask) UpdateProject(tmp map[string]interface{}, thisinfo *Info,
 	//保留原数据吧
 	push := p.PushListInfo(tmp)
 	push["compareStr"] = comStr
-	push["resVal"] = pInfo.pjVal
+	push["resVal"] = pInfo.resVal
 	push["pjVal"] = pInfo.pjVal
 	update["$push"] = map[string]interface{}{
 		"list": push,

+ 2 - 1
fullproject/src_dev5/task.go

@@ -47,6 +47,7 @@ type ProjectTask struct {
 	currentTime int64
 	//保存长度
 	saveSize int
+	pici     int64
 }
 
 func NewPT() *ProjectTask {
@@ -197,7 +198,7 @@ func (p *ProjectTask) taskQl(udpInfo map[string]interface{}) {
 	//		log.Println("publishtime_1索引不存在")
 	//	}
 	//	MongoTool.DestoryMongoConn(sess)
-	thread := util.IntAllDef(udpInfo["thread"], 3)
+	thread := util.IntAllDef(udpInfo["thread"], 5)
 	if thread > 0 {
 		p.thread = thread
 	}