|
@@ -174,7 +174,7 @@ func GetData(propertyForm []string, bid string) (result1, result2 []map[string]i
|
|
|
if len(m1Buckets.Buckets) > 0 {
|
|
|
for _, v := range m1Buckets.Buckets {
|
|
|
if v.Key != "" {
|
|
|
- m1[v.Key] = map[string]interface{}{"name": v.Key, "amount": v.Amount_all.Value, "count": v.Doc_count}
|
|
|
+ m1[v.Key] = map[string]interface{}{"name": v.Key, "amount": v.Amount_all.Value, "count": v.Doc_count, "nameId": v.EntId.Buckets[0].Key}
|
|
|
}
|
|
|
}
|
|
|
}
|
|
@@ -185,6 +185,7 @@ func GetData(propertyForm []string, bid string) (result1, result2 []map[string]i
|
|
|
v1 := v.(map[string]interface{})
|
|
|
tmp := make(map[string]interface{})
|
|
|
tmp["name"] = k
|
|
|
+ tmp["nameId"] = v1["nameId"]
|
|
|
tmp["coop_size"] = v1["count"]
|
|
|
tmp["coop_amount"] = v1["amount"]
|
|
|
result1 = append(result1, tmp)
|
|
@@ -206,7 +207,7 @@ func GetData(propertyForm []string, bid string) (result1, result2 []map[string]i
|
|
|
if len(m2Buckets.Buckets) > 0 {
|
|
|
for _, v := range m2Buckets.Buckets {
|
|
|
if v.Key != "" {
|
|
|
- m2[v.Key] = map[string]interface{}{"name": v.Key, "amount": v.Amount_all.Value, "count": v.Doc_count}
|
|
|
+ m2[v.Key] = map[string]interface{}{"name": v.Key, "amount": v.Amount_all.Value, "count": v.Doc_count, "nameId": v.EntId.Buckets[0].Key}
|
|
|
}
|
|
|
}
|
|
|
}
|
|
@@ -217,6 +218,7 @@ func GetData(propertyForm []string, bid string) (result1, result2 []map[string]i
|
|
|
v1 := v.(map[string]interface{})
|
|
|
tmp := make(map[string]interface{})
|
|
|
tmp["name"] = k
|
|
|
+ tmp["nameId"] = v1["nameId"]
|
|
|
tmp["coop_size"] = v1["count"]
|
|
|
tmp["coop_amount"] = v1["amount"]
|
|
|
result2 = append(result2, tmp)
|