|
|
@@ -957,18 +957,44 @@ public class StatisticsServiceImpl extends BaseService implements StatisticsServ
|
|
|
obj.setQueryType(2);
|
|
|
List<StatisticsBean> t_mthList = getPersonalScoreInfo(obj);
|
|
|
Map<Integer, StatisticsBean> t_map = new HashMap<>();
|
|
|
+
|
|
|
+ int seq =0 ;
|
|
|
+
|
|
|
for (int i = 0; i < t_mthList.size(); i++) {
|
|
|
- t_mthList.get(i).setRanking(i);
|
|
|
+ if( i == 0 ){
|
|
|
+ seq = 0 ;
|
|
|
+ }else{
|
|
|
+ if(t_mthList.get(i).compare2To(t_mthList.get(i-1)) == 0){
|
|
|
+ ;
|
|
|
+ }else{
|
|
|
+ seq = i ;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ t_mthList.get(i).setRanking(seq);
|
|
|
t_map.put(t_mthList.get(i).getUser().getId(), t_mthList.get(i));
|
|
|
}
|
|
|
+
|
|
|
+ seq = 0 ;
|
|
|
// 查询上一个月
|
|
|
obj.setMth(obj.getPrev_mth());
|
|
|
List<StatisticsBean> prev_mthList = getPersonalScoreInfo(obj);
|
|
|
for (int i = 0; i < prev_mthList.size(); i++) {
|
|
|
Integer uid = prev_mthList.get(i).getUser().getId();
|
|
|
+ if(i == 0 ){
|
|
|
+ ;
|
|
|
+ }else{
|
|
|
+ if(prev_mthList.get(i).compare2To(prev_mthList.get(i-1))==0){
|
|
|
+ ;
|
|
|
+ }else{
|
|
|
+ seq = i ;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
if (t_map.containsKey(uid)) {
|
|
|
- t_map.get(uid).setRanking_change(i - t_map.get(uid).getRanking());
|
|
|
+ t_map.get(uid).setRanking_change(seq - t_map.get(uid).getRanking());
|
|
|
}
|
|
|
+
|
|
|
+
|
|
|
}
|
|
|
|
|
|
// 这边按照名词变化进行排名
|