Browse Source

阳光采购

xuzhiheng 9 months ago
parent
commit
d3ea631dcd
1 changed files with 6 additions and 1 deletions
  1. 6 1
      field_sync/task.go

+ 6 - 1
field_sync/task.go

@@ -372,8 +372,9 @@ func doIndex(infos []map[string]interface{}, bkey, stype string) int {
 		//阳光采购
 		spidercode := util.ObjToString(tmp["spidercode"])
 		site := util.ObjToString(tmp["site"])
-		infoAttribute := util.ObjToString(tmp["infoAttribute"])
+		infoAttribute := util.ObjToString(tmp["infoattribute"])
 		if infoAttribute != "" {
+			update["public_type"] = "用户发布"
 			MgoE.Save("bidding_yg", map[string]interface{}{"id": tid, "source": "user"})
 		} else {
 			for _, v := range ygsiteArr {
@@ -381,8 +382,12 @@ func doIndex(infos []map[string]interface{}, bkey, stype string) int {
 				sites := util.ObjToString(v["site"])
 				datatype := util.ObjToString(v["datatype"])
 				if datatype == "1" && spidercodes == spidercode {
+					update["infoattribute"] = "zc_cgxx"
+					update["public_type"] = "平台发布"
 					MgoE.Save("bidding_yg", map[string]interface{}{"id": tid, "source": "spidercode"})
 				} else if datatype == "2" && site == sites {
+					update["infoattribute"] = "zc_cgxx"
+					update["public_type"] = "平台发布"
 					MgoE.Save("bidding_yg", map[string]interface{}{"id": tid, "source": "site"})
 				}
 			}