|
@@ -2,8 +2,6 @@ package main
|
|
|
|
|
|
import (
|
|
|
"strconv"
|
|
|
- "strings"
|
|
|
-
|
|
|
//"fmt"
|
|
|
"log"
|
|
|
"qfw/util"
|
|
@@ -108,12 +106,14 @@ func projectTask(data []byte, project, mapInfo map[string]interface{}) {
|
|
|
}
|
|
|
if topscopeclass, ok := tmp["topscopeclass"].([]interface{}); ok {
|
|
|
tc := []string{}
|
|
|
+ m2 := map[string]bool{}
|
|
|
for _, v := range topscopeclass {
|
|
|
str := util.ObjToString(v)
|
|
|
- str = strings.ReplaceAll(str, "t", "")
|
|
|
- str = strings.ReplaceAll(str, "d", "")
|
|
|
- str = strings.ReplaceAll(str, "p", "")
|
|
|
- tc = append(tc, str)
|
|
|
+ str = reg_letter.ReplaceAllString(str, "") // 去除字母
|
|
|
+ if !m2[str] {
|
|
|
+ m2[str] = true
|
|
|
+ tc = append(tc, str)
|
|
|
+ }
|
|
|
}
|
|
|
tmp["topscopeclass"] = tc
|
|
|
}
|
|
@@ -124,8 +124,9 @@ func projectTask(data []byte, project, mapInfo map[string]interface{}) {
|
|
|
list := tmp["list"].([]interface{})
|
|
|
for _, m := range list {
|
|
|
tmpM := m.(map[string]interface{})
|
|
|
- //删除purchasing
|
|
|
+ //删除purchasing,review_experts
|
|
|
delete(tmpM, "purchasing")
|
|
|
+ delete(tmpM, "review_experts")
|
|
|
if bidamount, ok := tmpM["bidamount"].(string); ok && len(bidamount) > 0 { //bidamount为string类型,转成float
|
|
|
tmpB := util.Float64All(tmpM["bidamount"])
|
|
|
tmpM["bidamount"] = tmpB
|