|
@@ -252,6 +252,7 @@ public class DataStaticService extends Ops {
|
|
|
List<String> userList = new ArrayList<>();
|
|
|
List<String> usermcList = new ArrayList<>();
|
|
|
List<String> userAllList = new ArrayList<>();
|
|
|
+ Map<String,Integer>countMap=new HashMap<>();
|
|
|
for (DataMap map : newList) {
|
|
|
String jythm = String.valueOf(map.get("交易主体户名"));
|
|
|
String jydszh = String.valueOf(map.get("交易对手账号"));
|
|
@@ -312,6 +313,19 @@ public class DataStaticService extends Ops {
|
|
|
String two = String.valueOf(dataMaps2.get(0).get("_id"));
|
|
|
party2.put("id", two);
|
|
|
party2.put("name", dataMaps2.get(0).get("账号"));
|
|
|
+ Integer integer = countMap.get(one);
|
|
|
+ if(integer==null){
|
|
|
+ countMap.put(one,1);
|
|
|
+ }else {
|
|
|
+ countMap.put(one,++integer);
|
|
|
+ }
|
|
|
+
|
|
|
+ Integer integer1 = countMap.get(two);
|
|
|
+ if(integer1==null){
|
|
|
+ countMap.put(two,1);
|
|
|
+ }else {
|
|
|
+ countMap.put(two,++integer1);
|
|
|
+ }
|
|
|
userAllId = one + "-" + two;
|
|
|
}
|
|
|
|
|
@@ -326,6 +340,20 @@ public class DataStaticService extends Ops {
|
|
|
String one = String.valueOf(dataMaps2.get(0).get("_id"));
|
|
|
party1.put("id", String.valueOf(dataMaps2.get(0).get("_id")));
|
|
|
party1.put("name", dataMaps2.get(0).get("账号"));
|
|
|
+
|
|
|
+ Integer integer = countMap.get(one);
|
|
|
+ if(integer==null){
|
|
|
+ countMap.put(one,1);
|
|
|
+ }else {
|
|
|
+ countMap.put(one,++integer);
|
|
|
+ }
|
|
|
+
|
|
|
+ Integer integer1 = countMap.get(two);
|
|
|
+ if(integer1==null){
|
|
|
+ countMap.put(two,1);
|
|
|
+ }else {
|
|
|
+ countMap.put(two,++integer1);
|
|
|
+ }
|
|
|
userAllId = one + "-" + two;
|
|
|
}
|
|
|
}
|
|
@@ -384,18 +412,13 @@ public class DataStaticService extends Ops {
|
|
|
|
|
|
}
|
|
|
|
|
|
- /* Map<String,String>aa=new HashMap<>();
|
|
|
List<Map<String, Object>> partyDataListnew = new ArrayList<>();
|
|
|
for (Map<String, Object> stringObjectMap : partyDataList) {
|
|
|
String id =String.valueOf(stringObjectMap.get("id"));
|
|
|
- String name =String.valueOf(stringObjectMap.get("name"));
|
|
|
- if(aa.containsKey(id+name)){
|
|
|
- continue;
|
|
|
- }
|
|
|
- aa.put(id+name,id+name);
|
|
|
+ stringObjectMap.put("relationCount",countMap.get(id));
|
|
|
partyDataListnew.add(stringObjectMap);
|
|
|
- }*/
|
|
|
- dataMap.put("partyData", partyDataList);
|
|
|
+ }
|
|
|
+ dataMap.put("partyData", partyDataListnew);
|
|
|
dataMap.put("relationshipGraph", relationshipGraphListnew);
|
|
|
Mapped mapped = Mapped.OK();
|
|
|
mapped.put("result", dataMap);
|