|
@@ -38,17 +38,8 @@ public class IndexStatisticsController {
|
|
type = 0;
|
|
type = 0;
|
|
}
|
|
}
|
|
|
|
|
|
- if(0 == type){
|
|
|
|
- analysisPreviewDTO = redisCache.getCacheObject(StatisticsRedisConstant.DATA_OVERVIEW_DEALER_ANALYSISPREVIEW_TODAY);
|
|
|
|
- } else if(1 == type){
|
|
|
|
- analysisPreviewDTO = redisCache.getCacheObject(StatisticsRedisConstant.DATA_OVERVIEW_DEALER_ANALYSISPREVIEW_YESTODAY);
|
|
|
|
- } else if(2 == type) {
|
|
|
|
- analysisPreviewDTO = redisCache.getCacheObject(StatisticsRedisConstant.DATA_OVERVIEW_DEALER_ANALYSISPREVIEW_THIS_WEEEK);
|
|
|
|
- } else if(3 == type) {
|
|
|
|
- analysisPreviewDTO = redisCache.getCacheObject(StatisticsRedisConstant.DATA_OVERVIEW_DEALER_ANALYSISPREVIEW_THIS_MONTH);
|
|
|
|
- } else if(4 == type) {
|
|
|
|
- analysisPreviewDTO = redisCache.getCacheObject(StatisticsRedisConstant.DATA_OVERVIEW_DEALER_ANALYSISPREVIEW_BEFORE_MONTH);
|
|
|
|
- }
|
|
|
|
|
|
+ analysisPreviewDTO = redisCache.getCacheObject(String.format("%s:%d",DATA_OVERVIEW_DEALER_ANALYSISPREVIEW,type));
|
|
|
|
+
|
|
return R.ok().put("data",analysisPreviewDTO);
|
|
return R.ok().put("data",analysisPreviewDTO);
|
|
}
|
|
}
|
|
|
|
|
|
@@ -67,7 +58,7 @@ public class IndexStatisticsController {
|
|
*/
|
|
*/
|
|
@PostMapping("/watchEndPlayTrend")
|
|
@PostMapping("/watchEndPlayTrend")
|
|
public R watchEndPlayTrend(@RequestBody AnalysisPreviewQueryDTO param){
|
|
public R watchEndPlayTrend(@RequestBody AnalysisPreviewQueryDTO param){
|
|
- String key = String.format("%s::%d", DATA_OVERVIEW_DEALER_CHARTS, param.getType());
|
|
|
|
|
|
+ String key = String.format("%s:%d", DATA_OVERVIEW_DEALER_CHARTS, param.getType());
|
|
List<DeaMemberTopTenDTO> deaMemberTopTenDTOS = redisCache.getCacheObject(key);
|
|
List<DeaMemberTopTenDTO> deaMemberTopTenDTOS = redisCache.getCacheObject(key);
|
|
return R.ok().put("data", deaMemberTopTenDTOS);
|
|
return R.ok().put("data", deaMemberTopTenDTOS);
|
|
}
|
|
}
|
|
@@ -80,7 +71,7 @@ public class IndexStatisticsController {
|
|
Integer type = param.getType();
|
|
Integer type = param.getType();
|
|
Integer statisticalType = param.getStatisticalType();
|
|
Integer statisticalType = param.getStatisticalType();
|
|
|
|
|
|
- List<DeaMemberTopTenDTO> deaMemberTopTenDTOS = redisCache.getCacheObject(String.format("%s::%d::%d", CHARTS_MEMBER_TOP_TEN_WATCH, type, statisticalType));
|
|
|
|
|
|
+ List<DeaMemberTopTenDTO> deaMemberTopTenDTOS = redisCache.getCacheObject(String.format("%s:%d:%d", CHARTS_MEMBER_TOP_TEN_WATCH, type, statisticalType));
|
|
if(deaMemberTopTenDTOS == null){
|
|
if(deaMemberTopTenDTOS == null){
|
|
deaMemberTopTenDTOS = new ArrayList<>();
|
|
deaMemberTopTenDTOS = new ArrayList<>();
|
|
}
|
|
}
|
|
@@ -94,7 +85,7 @@ public class IndexStatisticsController {
|
|
public R rewardMoneyTopTen(@RequestBody AnalysisPreviewQueryDTO param){
|
|
public R rewardMoneyTopTen(@RequestBody AnalysisPreviewQueryDTO param){
|
|
Integer type = param.getType();
|
|
Integer type = param.getType();
|
|
Integer dataType = param.getDataType();
|
|
Integer dataType = param.getDataType();
|
|
- List<RewardMoneyTopTenDTO> rewardMoneyTopTenDTOS = redisCache.getCacheObject( String.format("%s::%d::%d", CHARTS_REWARD_MONEY_TOP_TEN, type,dataType));
|
|
|
|
|
|
+ List<RewardMoneyTopTenDTO> rewardMoneyTopTenDTOS = redisCache.getCacheObject( String.format("%s:%d:%d", CHARTS_REWARD_MONEY_TOP_TEN, type,dataType));
|
|
return R.ok().put("data", rewardMoneyTopTenDTOS);
|
|
return R.ok().put("data", rewardMoneyTopTenDTOS);
|
|
}
|
|
}
|
|
|
|
|
|
@@ -104,7 +95,7 @@ public class IndexStatisticsController {
|
|
@PostMapping("/rewardMoneyTrend")
|
|
@PostMapping("/rewardMoneyTrend")
|
|
public R rewardMoneyTrend(@RequestBody AnalysisPreviewQueryDTO param){
|
|
public R rewardMoneyTrend(@RequestBody AnalysisPreviewQueryDTO param){
|
|
Integer type = param.getType();
|
|
Integer type = param.getType();
|
|
- List<RewardMoneyTrendDTO> rewardMoneyTrendDTOS = redisCache.getCacheObject( String.format("%s::%d", CHARTS_REWARD_MONEY_TREND, type));
|
|
|
|
|
|
+ List<RewardMoneyTrendDTO> rewardMoneyTrendDTOS = redisCache.getCacheObject( String.format("%s:%d", CHARTS_REWARD_MONEY_TREND, type));
|
|
return R.ok().put("data", rewardMoneyTrendDTOS);
|
|
return R.ok().put("data", rewardMoneyTrendDTOS);
|
|
}
|
|
}
|
|
|
|
|
|
@@ -116,7 +107,7 @@ public class IndexStatisticsController {
|
|
Integer type = param.getType();
|
|
Integer type = param.getType();
|
|
String sort = param.getSort();
|
|
String sort = param.getSort();
|
|
Integer statisticalType = param.getStatisticalType();
|
|
Integer statisticalType = param.getStatisticalType();
|
|
- List<CourseStatsDTO> courseStatsDTOS = redisCache.getCacheObject(String.format("%s::%d::%d::%s", CHARTS_WATCH_TOP_TEN, type,statisticalType,sort));
|
|
|
|
|
|
+ List<CourseStatsDTO> courseStatsDTOS = redisCache.getCacheObject(String.format("%s:%d:%d:%s", CHARTS_WATCH_TOP_TEN, type,statisticalType,sort));
|
|
return R.ok().put("data", courseStatsDTOS);
|
|
return R.ok().put("data", courseStatsDTOS);
|
|
}
|
|
}
|
|
|
|
|