瀏覽代碼

Merge branch 'package' of GameCenter/game-center into dev

zhimo 1 年之前
父節點
當前提交
93c4e4a6e2
共有 23 個文件被更改,包括 3872 次插入674 次删除
  1. 3 2
      game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/controller/AdsPromotionDayController.java
  2. 4 4
      game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/controller/GameDataController.java
  3. 11 0
      game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/dto/PromotionDayDTO.java
  4. 130 0
      game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/dto/PromotionDayTotalDTO.java
  5. 373 19
      game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/entity/AdsAccountAgentDay.java
  6. 6 0
      game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/entity/AdsEverydayWater.java
  7. 72 6
      game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/entity/AdsGameDay.java
  8. 24 6
      game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/vo/GameDataDayTotalVO.java
  9. 267 132
      game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/vo/GameDataDayVO.java
  10. 235 0
      game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/vo/GamePromoteDayTotalVO.java
  11. 235 0
      game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/vo/GamePromoteDayVO.java
  12. 295 0
      game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/vo/GamePromoteTotalSumVO.java
  13. 295 0
      game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/vo/GamePromoteTotalVO.java
  14. 6 0
      game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/vo/PlayerTemplateVO.java
  15. 788 1
      game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/vo/PromotionDayTotalVO.java
  16. 2 3
      game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/vo/PromotionDayVO.java
  17. 3 0
      game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/vo/RechargeTrendVO.java
  18. 440 154
      game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/service/impl/AccountAgentDayServiceImpl.java
  19. 151 286
      game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/service/impl/GameDataServiceImpl.java
  20. 3 39
      game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/service/impl/OverallSummaryServiceImpl.java
  21. 518 21
      game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/service/impl/PromotionDayServiceImpl.java
  22. 1 1
      game-module/game-module-sdk/src/main/java/com/zanxiang/game/module/sdk/SDKApplication.java
  23. 10 0
      game-module/game-module-sdk/src/main/java/com/zanxiang/game/module/sdk/service/impl/UserTokenServiceImpl.java

+ 3 - 2
game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/controller/AdsPromotionDayController.java

@@ -1,5 +1,6 @@
 package com.zanxiang.game.data.serve.controller;
 
+import com.zanxiang.erp.security.annotation.PreAuthorize;
 import com.zanxiang.game.data.serve.pojo.dto.PromotionDayDTO;
 import com.zanxiang.game.data.serve.pojo.dto.PromotionDayTotalDTO;
 import com.zanxiang.game.data.serve.pojo.vo.PromotionDayTotalVO;
@@ -31,14 +32,14 @@ public class AdsPromotionDayController {
     private IAdsPromotionDayService adsPromotionDayService;
 
     @ApiOperation(value = "广告监控数据")
-    //@PreAuthorize(permissionKey = "promotionData:adsPromotionDay:day")
+    @PreAuthorize(permissionKey = "promotionData:adsPromotionDay:day")
     @PostMapping("/day")
     public ResultVO<Page<PromotionDayVO>> getPromotionDayData(@RequestBody PromotionDayDTO dto){
         return ResultVO.ok(adsPromotionDayService.getPromotionDayData(dto));
     }
 
     @ApiOperation(value = "广告监控数据总计")
-    //@PreAuthorize(permissionKey = "promotionData:adsPromotionDay:total")
+    @PreAuthorize(permissionKey = "promotionData:adsPromotionDay:total")
     @PostMapping("/total")
     public ResultVO<PromotionDayTotalVO> getPromotionDayTotalData(@RequestBody PromotionDayTotalDTO dto) {
         return ResultVO.ok(adsPromotionDayService.getPromotionDayTotalData(dto));

+ 4 - 4
game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/controller/GameDataController.java

@@ -36,7 +36,7 @@ public class GameDataController {
     private IGameDataService gameDataService;
 
     @ApiOperation(value = "游戏每日数据")
-    @PreAuthorize(permissionKey = "gameData:adsGameDay:day")
+    //@PreAuthorize(permissionKey = "gameData:adsGameDay:day")
     @PostMapping("/day")
     @ApiResponses(value = {@ApiResponse(code = 200, message = "成功", response = GameDataDayVO.class)})
     public ResultVO<Page<GameDataDayVO>> getGameDataDay(@RequestBody GameDataDayDTO dto) {
@@ -44,7 +44,7 @@ public class GameDataController {
     }
 
     @ApiOperation(value = "游戏每日数据总计")
-    @PreAuthorize(permissionKey = "gameData:adsGameDay:dayTotal")
+    //@PreAuthorize(permissionKey = "gameData:adsGameDay:dayTotal")
     @PostMapping("/day/total")
     @ApiResponses(value = {@ApiResponse(code = 200, message = "成功", response = GameDataDayVO.class)})
     public ResultVO<GameDataDayTotalVO> getGameDataDay(@RequestBody GameDataDayTotalDTO dto) {
@@ -58,7 +58,7 @@ public class GameDataController {
         return ResultVO.ok(gameDataService.getH5Recharge(dto));
     }
     @ApiOperation(value = "游戏总数据")
-    @PreAuthorize(permissionKey = "gameData:adsGameDay:total")
+    //@PreAuthorize(permissionKey = "gameData:adsGameDay:total")
     @PostMapping("/total")
     @ApiResponses(value = {@ApiResponse(code = 200, message = "成功", response = GameDataTotalVO.class)})
     public ResultVO<Page<GameDataTotalVO>> getGameDataTotal(@RequestBody GameDataTotalDTO dto) {
@@ -73,7 +73,7 @@ public class GameDataController {
     }
 
     @ApiOperation(value = "游戏每日复充数据")
-    @PreAuthorize(permissionKey = "gameData:adsGameDay:again")
+    //@PreAuthorize(permissionKey = "gameData:adsGameDay:again")
     @PostMapping("/again")
     public ResultVO<Map<LocalDate, List<GameDataAgainDayVO>>> getGameDataAgainDay(@RequestBody GameDataAgainDayDTO dto) throws Exception {
         return ResultVO.ok(gameDataService.getGameDataAgainDay(dto));

+ 11 - 0
game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/dto/PromotionDayDTO.java

@@ -140,5 +140,16 @@ public class PromotionDayDTO extends BasePage {
     @ApiModelProperty(value = "游戏应用类型")
     private Long classify;
 
+    /**
+     * 排序字段
+     */
+    @ApiModelProperty(notes = "排序字段")
+    private String sortFiled;
+
+    /**
+     * 排序方式:升序asc;降序desc
+     */
+    @ApiModelProperty(notes = "排序方式:升序asc;降序desc")
+    private String sortType;
 
 }

+ 130 - 0
game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/dto/PromotionDayTotalDTO.java

@@ -1,12 +1,142 @@
 package com.zanxiang.game.data.serve.pojo.dto;
 
+import io.swagger.annotations.ApiModelProperty;
+import lombok.AllArgsConstructor;
+import lombok.Builder;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+
+import java.time.LocalDate;
+
 /**
  * @author tianhua
  * @time 2023/7/27
  * @Description 前端传递的查询参数实体
  **/
+@Data
+@NoArgsConstructor
+@AllArgsConstructor
+@Builder
 public class PromotionDayTotalDTO {
 
+    /**
+     * 消耗开始日期
+     */
+    @ApiModelProperty(value = "消耗开始时间")
+    private LocalDate costBeginDate;
+
+    /**
+     * 消耗结束日期
+     */
+    @ApiModelProperty(value = "消耗结束时间")
+    private LocalDate costEndDate;
+
+    /**
+     * SDK来源
+     */
+    @ApiModelProperty(value = "SDK来源")
+    private String sourceSystem;
+
+    /**
+     * 广告ID
+     */
+    @ApiModelProperty(value = "广告ID")
+    private Long promotionId;
+
+    /**
+     * 广告名称
+     */
+    @ApiModelProperty(value = "广告名称")
+    private String promotionName;
+
+    /**
+     * 广告状态
+     */
+    @ApiModelProperty(value = "广告状态")
+    private String status;
+
+    /**
+     * 计划ID
+     */
+    @ApiModelProperty(value = "计划ID")
+    private Long projectId;
+
+    /**
+     * 计划名称
+     */
+    @ApiModelProperty(value = "计划名称")
+    private String projectName;
+
+    /**
+     * 推广账号名称
+     */
+    @ApiModelProperty(value = "推广账号名称")
+    private String accountName;
+
+    /**
+     * 推广账号ID
+     */
+    @ApiModelProperty(value = "推广账号ID")
+    private Long accountId;
+
+    /**
+     * 投放媒体
+     */
+    @ApiModelProperty(value = "投放媒体")
+    private String accountType;
+
+    /**
+     * 投手ID
+     */
+    @ApiModelProperty(value = "投手ID")
+    private Long pitcherId;
+
+    /**
+     * 投手名称
+     */
+    @ApiModelProperty(value = "投手名称")
+    private String pitcherName;
+
+    /**
+     * 渠道ID
+     */
+    @ApiModelProperty(value = "渠道ID")
+    private Long agentId;
+
+    /**
+     * 渠道名称
+     */
+    @ApiModelProperty(value = "渠道名称")
+    private String agentName;
+
+    /**
+     * 渠道标识
+     */
+    @ApiModelProperty(value = "渠道标识")
+    private String agentKey;
+
+    /**
+     * cp名称
+     */
+    @ApiModelProperty(value = "CP名称")
+    private String cpName;
+
+    /**
+     * 游戏ID
+     */
+    @ApiModelProperty(value = "游戏ID")
+    private Long gameId;
+
+    /**
+     * 游戏名称
+     */
+    @ApiModelProperty(value = "游戏名称")
+    private String gameName;
 
+    /**
+     * 游戏应用类型
+     */
+    @ApiModelProperty(value = "游戏应用类型")
+    private Long classify;
 
 }

+ 373 - 19
game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/entity/AdsAccountAgentDay.java

@@ -18,8 +18,8 @@ import java.time.LocalDateTime;
  * 推广渠道每日数据
  * </p>
  *
- * @author
- * @since 2023-06-30
+ * @author auto
+ * @since 2023-07-28
  */
 @Data
 @NoArgsConstructor
@@ -36,6 +36,9 @@ public class AdsAccountAgentDay implements Serializable {
      */
     private LocalDate dt;
 
+    /**
+     * SDK来源
+     */
     private String sourceSystem;
 
     /**
@@ -79,13 +82,16 @@ public class AdsAccountAgentDay implements Serializable {
     private String gameCp;
 
     /**
-     * 推广游戏名称
+     * 推广游戏ID
      */
     @Column
-    private String gameName;
+    private Long gameId;
 
+    /**
+     * 推广游戏名称
+     */
     @Column
-    private Long gameId;
+    private String gameName;
 
     /**
      * 推广游戏类型
@@ -297,6 +303,24 @@ public class AdsAccountAgentDay implements Serializable {
     @Column
     private BigDecimal amount;
 
+    /**
+     * 老用户充值次数(每日)
+     */
+    @Column
+    private Long oldAmountCount;
+
+    /**
+     * 老用户充值人数(每日)
+     */
+    @Column
+    private Long oldAmountNum;
+
+    /**
+     * 老用户充值金额(每日)
+     */
+    @Column
+    private BigDecimal oldAmount;
+
     /**
      * 至今充值次数
      */
@@ -340,31 +364,181 @@ public class AdsAccountAgentDay implements Serializable {
     private BigDecimal grossProfit;
 
     /**
-     * 3日ROI
+     * 1日roi
+     */
+    @Column
+    private BigDecimal roi1;
+
+    /**
+     * 2日roi
+     */
+    @Column
+    private BigDecimal roi2;
+
+    /**
+     * 3日roi
      */
     @Column
     private BigDecimal roi3;
 
     /**
-     * 5日ROI
+     * 4日roi
+     */
+    @Column
+    private BigDecimal roi4;
+
+    /**
+     * 5日roi
      */
     @Column
     private BigDecimal roi5;
 
     /**
-     * 7日ROI
+     * 6日roi
+     */
+    @Column
+    private BigDecimal roi6;
+
+    /**
+     * 7日roi
      */
     @Column
     private BigDecimal roi7;
 
     /**
-     * 15日ROI
+     * 8日roi
+     */
+    @Column
+    private BigDecimal roi8;
+
+    /**
+     * 9日roi
+     */
+    @Column
+    private BigDecimal roi9;
+
+    /**
+     * 10日roi
+     */
+    @Column
+    private BigDecimal roi10;
+
+    /**
+     * 11日roi
+     */
+    @Column
+    private BigDecimal roi11;
+
+    /**
+     * 12日roi
+     */
+    @Column
+    private BigDecimal roi12;
+
+    /**
+     * 13日roi
+     */
+    @Column
+    private BigDecimal roi13;
+
+    /**
+     * 14日roi
+     */
+    @Column
+    private BigDecimal roi14;
+
+    /**
+     * 15日roi
      */
     @Column
     private BigDecimal roi15;
 
     /**
-     * 30日ROI
+     * 16日roi
+     */
+    @Column
+    private BigDecimal roi16;
+
+    /**
+     * 17日roi
+     */
+    @Column
+    private BigDecimal roi17;
+
+    /**
+     * 18日roi
+     */
+    @Column
+    private BigDecimal roi18;
+
+    /**
+     * 19日roi
+     */
+    @Column
+    private BigDecimal roi19;
+
+    /**
+     * 20日roi
+     */
+    @Column
+    private BigDecimal roi20;
+
+    /**
+     * 21日roi
+     */
+    @Column
+    private BigDecimal roi21;
+
+    /**
+     * 22日roi
+     */
+    @Column
+    private BigDecimal roi22;
+
+    /**
+     * 23日roi
+     */
+    @Column
+    private BigDecimal roi23;
+
+    /**
+     * 24日roi
+     */
+    @Column
+    private BigDecimal roi24;
+
+    /**
+     * 25日roi
+     */
+    @Column
+    private BigDecimal roi25;
+
+    /**
+     * 26日roi
+     */
+    @Column
+    private BigDecimal roi26;
+
+    /**
+     * 27日roi
+     */
+    @Column
+    private BigDecimal roi27;
+
+    /**
+     * 28日roi
+     */
+    @Column
+    private BigDecimal roi28;
+
+    /**
+     * 29日roi
+     */
+    @Column
+    private BigDecimal roi29;
+
+    /**
+     * 30日roi
      */
     @Column
     private BigDecimal roi30;
@@ -375,6 +549,12 @@ public class AdsAccountAgentDay implements Serializable {
     @Column
     private BigDecimal roi60;
 
+    /**
+     * 90日ROI
+     */
+    @Column
+    private BigDecimal roi90;
+
     /**
      * 180日ROI
      */
@@ -484,59 +664,209 @@ public class AdsAccountAgentDay implements Serializable {
     private BigDecimal paperArpu;
 
     /**
-     * 付费趋势第一天总:增/回/倍
+     * 付费趋势第1日总:金额/人数/增/回/倍
      */
     @Column
     private String amountD1;
 
     /**
-     * 付费趋势第三天总:增/回/倍
+     * 付费趋势第2日总:金额/人数/增/回/倍
+     */
+    @Column
+    private String amountD2;
+
+    /**
+     * 付费趋势第3日总:金额/人数/增/回/倍
      */
     @Column
     private String amountD3;
 
     /**
-     * 付费趋势第五天总:增/回/倍
+     * 付费趋势第4日总:金额/人数/增/回/倍
+     */
+    @Column
+    private String amountD4;
+
+    /**
+     * 付费趋势第5日总:金额/人数/增/回/倍
      */
     @Column
     private String amountD5;
 
     /**
-     * 付费趋势第七天总:增/回/倍
+     * 付费趋势第6日总:金额/人数/增/回/倍
+     */
+    @Column
+    private String amountD6;
+
+    /**
+     * 付费趋势第7日总:金额/人数/增/回/倍
      */
     @Column
     private String amountD7;
 
     /**
-     * 付费趋势第十五天总:增/回/倍
+     * 付费趋势第8日总:金额/人数/增/回/倍
+     */
+    @Column
+    private String amountD8;
+
+    /**
+     * 付费趋势第9日总:金额/人数/增/回/倍
+     */
+    @Column
+    private String amountD9;
+
+    /**
+     * 付费趋势第10日总:金额/人数/增/回/倍
+     */
+    @Column
+    private String amountD10;
+
+    /**
+     * 付费趋势第11日总:金额/人数/增/回/倍
+     */
+    @Column
+    private String amountD11;
+
+    /**
+     * 付费趋势第12日总:金额/人数/增/回/倍
+     */
+    @Column
+    private String amountD12;
+
+    /**
+     * 付费趋势第13日总:金额/人数/增/回/倍
+     */
+    @Column
+    private String amountD13;
+
+    /**
+     * 付费趋势第14日总:金额/人数/增/回/倍
+     */
+    @Column
+    private String amountD14;
+
+    /**
+     * 付费趋势第15日总:金额/人数/增/回/倍
      */
     @Column
     private String amountD15;
 
     /**
-     * 付费趋势第一月总:增/回/倍
+     * 付费趋势第16日总:金额/人数/增/回/倍
+     */
+    @Column
+    private String amountD16;
+
+    /**
+     * 付费趋势第17日总:金额/人数/增/回/倍
+     */
+    @Column
+    private String amountD17;
+
+    /**
+     * 付费趋势第18日总:金额/人数/增/回/倍
+     */
+    @Column
+    private String amountD18;
+
+    /**
+     * 付费趋势第19日总:金额/人数/增/回/倍
+     */
+    @Column
+    private String amountD19;
+
+    /**
+     * 付费趋势第20日总:金额/人数/增/回/倍
+     */
+    @Column
+    private String amountD20;
+
+    /**
+     * 付费趋势第21日总:金额/人数/增/回/倍
+     */
+    @Column
+    private String amountD21;
+
+    /**
+     * 付费趋势第22日总:金额/人数/增/回/倍
+     */
+    @Column
+    private String amountD22;
+
+    /**
+     * 付费趋势第23日总:金额/人数/增/回/倍
+     */
+    @Column
+    private String amountD23;
+
+    /**
+     * 付费趋势第24日总:金额/人数/增/回/倍
+     */
+    @Column
+    private String amountD24;
+
+    /**
+     * 付费趋势第25日总:金额/人数/增/回/倍
+     */
+    @Column
+    private String amountD25;
+
+    /**
+     * 付费趋势第26日总:金额/人数/增/回/倍
+     */
+    @Column
+    private String amountD26;
+
+    /**
+     * 付费趋势第27日总:金额/人数/增/回/倍
+     */
+    @Column
+    private String amountD27;
+
+    /**
+     * 付费趋势第28日总:金额/人数/增/回/倍
+     */
+    @Column
+    private String amountD28;
+
+    /**
+     * 付费趋势第29日总:金额/人数/增/回/倍
+     */
+    @Column
+    private String amountD29;
+
+    /**
+     * 付费趋势第30日总:金额/人数/增/回/倍
      */
     @Column
     private String amountM1;
 
     /**
-     * 付费趋势第二月总:增/回/倍
+     * 付费趋势第二月总:金额/人数/增/回/倍
      */
     @Column
     private String amountM2;
 
     /**
-     * 付费趋势第三月总:增/回/倍
+     * 付费趋势第三月总:金额/人数/增/回/倍
      */
     @Column
     private String amountM3;
 
     /**
-     * 付费趋势第六月总:增/回/倍
+     * 付费趋势六月总:金额/人数/增/回/倍
      */
     @Column
     private String amountM6;
 
+    /**
+     * 付费趋势一年总:金额/人数/增/回/倍
+     */
+    @Column
+    private String amountY1;
+
     /**
      * 付费趋势总:增/回/倍
      */
@@ -555,5 +885,29 @@ public class AdsAccountAgentDay implements Serializable {
     @Column
     private BigDecimal hundredUserNumCost;
 
+    /**
+     * 买量新用户累计充值金额
+     */
+    @Column
+    private BigDecimal buyNewUserTotalAmount;
+
+    /**
+     * 买量新用户累计充值人数
+     */
+    @Column
+    private Long buyNewUserTotalAmountNum;
+
+    /**
+     * 买量新用户累计充值次数
+     */
+    @Column
+    private Long buyNewUserTotalAmountCount;
+
+    /**
+     * 复充人数
+     */
+    @Column
+    private Long regOrderUserAgain;
+
 
 }

+ 6 - 0
game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/entity/AdsEverydayWater.java

@@ -126,5 +126,11 @@ public class AdsEverydayWater implements Serializable {
     @Column
     private BigDecimal proportion;
 
+    @Column
+    private String roleName;
+
+    @Column
+    private String serverName;
+
 
 }

+ 72 - 6
game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/entity/AdsGameDay.java

@@ -147,16 +147,22 @@ public class AdsGameDay implements Serializable {
     private BigDecimal newUserTotalAmount;
 
     /**
-     * 首日付费率(总)
+     * 首日ROI(总)
      */
     @Column
     private BigDecimal firstRoi;
 
+    /**
+     * 首日付费率(总)
+     */
+    @Column
+    private BigDecimal firstAmountRate;
+
     /**
      * 当天付费率(总)
      */
     @Column
-    private BigDecimal todayRoi;
+    private BigDecimal todayAmountRate;
 
     /**
      * 新用户付费比(总)
@@ -224,24 +230,72 @@ public class AdsGameDay implements Serializable {
     @Column
     private String amountD1;
 
+    /**
+     * 付费趋势第2天总:金额/人数/增/回/倍(总量)
+     */
+    @Column
+    private String amountD2;
+
     /**
      * 付费趋势第三天总:金额/人数/增/回/倍(总量)
      */
     @Column
     private String amountD3;
 
+    /**
+     * 付费趋势第4天总:金额/人数/增/回/倍(总量)
+     */
+    @Column
+    private String amountD4;
+
     /**
      * 付费趋势第五天总:金额/人数/增/回/倍(总量)
      */
     @Column
     private String amountD5;
 
+    /**
+     * 付费趋势第6天总:金额/人数/增/回/倍(总量)
+     */
+    @Column
+    private String amountD6;
+
     /**
      * 付费趋势第七天总:金额/人数/增/回/倍(总量)
      */
     @Column
     private String amountD7;
 
+    /**
+     * 付费趋势第8天总:金额/人数/增/回/倍(总量)
+     */
+    @Column
+    private String amountD8;
+
+    /**
+     * 付费趋势第9天总:金额/人数/增/回/倍(总量)
+     */
+    @Column
+    private String amountD9;
+
+    /**
+     * 付费趋势第10天总:金额/人数/增/回/倍(总量)
+     */
+    @Column
+    private String amountD10;
+
+    /**
+     * 付费趋势第11天总:金额/人数/增/回/倍(总量)
+     */
+    @Column
+    private String amountD11;
+
+    /**
+     * 付费趋势第12天总:金额/人数/增/回/倍(总量)
+     */
+    @Column
+    private String amountD12;
+
     /**
      * 付费趋势第十五天总:金额/人数/增/回/倍(总量)
      */
@@ -357,16 +411,22 @@ public class AdsGameDay implements Serializable {
     private BigDecimal buyNewUserTotalAmount;
 
     /**
-     * 首日付费率(买量)
+     * 首日ROI(买量)
      */
     @Column
     private BigDecimal buyFirstRoi;
 
+    /**
+     * 首日付费率(买量)
+     */
+    @Column
+    private BigDecimal buyFirstAmountRate;
+
     /**
      * 当天付费率(买量)
      */
     @Column
-    private BigDecimal buyTodayRoi;
+    private BigDecimal buyTodayAmountRate;
 
     /**
      * 新用户付费比(买量)
@@ -567,16 +627,22 @@ public class AdsGameDay implements Serializable {
     private BigDecimal natureNewUserTotalAmount;
 
     /**
-     * 首日付费率(自然量)
+     * 首日ROI(自然量)
      */
     @Column
     private BigDecimal natureFirstRoi;
 
+    /**
+     * 首日付费率(自然量)
+     */
+    @Column
+    private BigDecimal natureFirstAmountRate;
+
     /**
      * 当天付费率(自然量)
      */
     @Column
-    private BigDecimal natureTodayRoi;
+    private BigDecimal natureTodayAmountRate;
 
     /**
      * 新用户付费比(自然量)

+ 24 - 6
game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/vo/GameDataDayTotalVO.java

@@ -115,17 +115,23 @@ public class GameDataDayTotalVO {
     @ApiModelProperty(value = "新用户累计充值金额(买量)")
     private BigDecimal buyNewUserTotalAmount;
 
+    /**
+     * 首日ROI(买量)
+     */
+    @ApiModelProperty(value = "首日ROI(买量)")
+    private BigDecimal buyFirstRoi;
+
     /**
      * 首日付费率(买量)
      */
     @ApiModelProperty(value = "首日付费率(买量)")
-    private BigDecimal buyFirstRoi;
+    private BigDecimal buyFirstAmountRate;
 
     /**
      * 当天付费率(买量)
      */
     @ApiModelProperty(value = "当天付费率(买量)")
-    private BigDecimal buyTodayRoi;
+    private BigDecimal buyTodayAmountRate;
 
     /**
      * 新用户付费比(买量)
@@ -253,17 +259,23 @@ public class GameDataDayTotalVO {
     @ApiModelProperty(value = "新用户累计充值金额(自然量)")
     private BigDecimal natureNewUserTotalAmount;
 
+    /**
+     * 首日ROI(自然量)
+     */
+    @ApiModelProperty(value = "首日ROI(自然量)")
+    private BigDecimal natureFirstRoi;
+
     /**
      * 首日付费率(自然量)
      */
     @ApiModelProperty(value = "首日付费率(自然量)")
-    private BigDecimal natureFirstRoi;
+    private BigDecimal natureFirstAmountRate;
 
     /**
      * 当天付费率(自然量)
      */
     @ApiModelProperty(value = "当天付费率(自然量)")
-    private BigDecimal natureTodayRoi;
+    private BigDecimal natureTodayAmountRate;
 
     /**
      * 新用户付费比(自然量)
@@ -391,17 +403,23 @@ public class GameDataDayTotalVO {
     @ApiModelProperty(value = "新用户累计充值金额(总量)")
     private BigDecimal newUserTotalAmount;
 
+    /**
+     * 首日ROI(总量)
+     */
+    @ApiModelProperty(value = "首日ROI(总量)")
+    private BigDecimal firstRoi;
+
     /**
      * 首日付费率(总量)
      */
     @ApiModelProperty(value = "首日付费率(总量)")
-    private BigDecimal firstRoi;
+    private BigDecimal firstAmountRate;
 
     /**
      * 当天付费率(总量)
      */
     @ApiModelProperty(value = "当天付费率(总量)")
-    private BigDecimal todayRoi;
+    private BigDecimal todayAmountRate;
 
     /**
      * 新用户付费比(总量)

+ 267 - 132
game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/vo/GameDataDayVO.java

@@ -1,10 +1,7 @@
 package com.zanxiang.game.data.serve.pojo.vo;
 
 import io.swagger.annotations.ApiModelProperty;
-import lombok.AllArgsConstructor;
-import lombok.Builder;
 import lombok.Data;
-import lombok.NoArgsConstructor;
 
 import java.math.BigDecimal;
 
@@ -16,9 +13,6 @@ import java.time.LocalDate;
  * @Description 返回给前端的游戏每日数据实体
  **/
 @Data
-@NoArgsConstructor
-@AllArgsConstructor
-@Builder
 public class GameDataDayVO {
 
     /**
@@ -148,16 +142,16 @@ public class GameDataDayVO {
     private BigDecimal buyNewUserTotalAmount;
 
     /**
-     * 首日付费率(买量)
+     * 首日ROI(买量)
      */
-    @ApiModelProperty(value = "首日付费率(买量)")
+    @ApiModelProperty(value = "首日ROI(买量)")
     private BigDecimal buyFirstRoi;
 
-    /**
-     * 当天付费率(买量)
-     */
+    @ApiModelProperty(value = "首日付费率(买量)")
+    private BigDecimal buyFirstAmountRate;
+
     @ApiModelProperty(value = "当天付费率(买量)")
-    private BigDecimal buyTodayRoi;
+    private BigDecimal buyTodayAmountRate;
 
     /**
      * 新用户付费比(买量)
@@ -286,16 +280,16 @@ public class GameDataDayVO {
     private BigDecimal natureNewUserTotalAmount;
 
     /**
-     * 首日付费率(自然量)
+     * 首日roi(自然量)
      */
-    @ApiModelProperty(value = "首日付费率(自然量)")
+    @ApiModelProperty(value = "首日roi(自然量)")
     private BigDecimal natureFirstRoi;
 
-    /**
-     * 当天付费率(自然量)
-     */
+    @ApiModelProperty(value = "首日付费率(自然量)")
+    private BigDecimal natureFirstAmountRate;
+
     @ApiModelProperty(value = "当天付费率(自然量)")
-    private BigDecimal natureTodayRoi;
+    private BigDecimal natureTodayAmountRate;
 
     /**
      * 新用户付费比(自然量)
@@ -424,16 +418,16 @@ public class GameDataDayVO {
     private BigDecimal newUserTotalAmount;
 
     /**
-     * 首日付费率(总量)
+     * 首日Roi(总量)
      */
-    @ApiModelProperty(value = "首日付费率(总量)")
+    @ApiModelProperty(value = "首日Roi(总量)")
     private BigDecimal firstRoi;
 
-    /**
-     * 当天付费率(总量)
-     */
-    @ApiModelProperty(value = "当天付费率(总)")
-    private BigDecimal todayRoi;
+    @ApiModelProperty(value = "首日付费率(总)")
+    private BigDecimal firstAmountRate;
+
+    @ApiModelProperty(value = "当天付费率(总)")
+    private BigDecimal todayAmountRate;
 
     /**
      * 新用户付费比(总量)
@@ -687,6 +681,9 @@ public class GameDataDayVO {
     @ApiModelProperty(value = "(不展示)付费趋势:6个月(买量)金额/人数/增/回/倍")
     private String buyAmountM6;
 
+    @ApiModelProperty(value = "付费趋势总:金额/人数/增/回/倍(买量)")
+    private String buyAmountY1;
+
     /**
      * 付费趋势:总(买量)金额/人数/增/回/倍(不展示)
      */
@@ -885,12 +882,12 @@ public class GameDataDayVO {
     @ApiModelProperty(value = "(不展示)付费趋势:3个月(自然量)金额/人数/增/回/倍")
     private String natureAmountM3;
 
-    /**
-     * 付费趋势:6个月(自然量)金额/人数/增/回/倍(不展示)
-     */
     @ApiModelProperty(value = "(不展示)付费趋势:6个月(自然量)金额/人数/增/回/倍")
     private String natureAmountM6;
 
+    @ApiModelProperty(value = "(不展示)付费趋势:1年(自然量)金额/人数/增/回/倍")
+    private String natureAmountY1;
+
     /**
      * 付费趋势:总(自然量)金额/人数/增/回/倍(不展示)
      */
@@ -1089,195 +1086,333 @@ public class GameDataDayVO {
     @ApiModelProperty(value = "(不展示)付费趋势:3个月(总量)金额/人数/增/回/倍")
     private String amountM3;
 
-    /**
-     * 付费趋势:6个月(总量)金额/人数/增/回/倍(不展示)
-     */
     @ApiModelProperty(value = "(不展示)付费趋势:6个月(总量)金额/人数/增/回/倍")
     private String amountM6;
 
+    @ApiModelProperty(value = "(不展示)付费趋势:1年(总量)金额/人数/增/回/倍")
+    private String amountY1;
+
     /**
      * 付费趋势:总(总量)金额/人数/增/回/倍(不展示)
      */
     @ApiModelProperty(value = "(不展示)付费趋势:总(总量)金额/人数/增/回/倍")
     private String amountSum;
 
-    /**
-     * 付费趋势:1天(买量)金额/人数/增/回/倍(展示数据)
-     */
-    @ApiModelProperty(value = "付费趋势:1天(买量)金额/人数/增/回/倍")
+    @ApiModelProperty(value = "付费趋势:1~29天(买量)金额/人数/增/回/倍")
     private RechargeTrendVO buyAmountD1Trend;
 
-    /**
-     * 付费趋势:3天(买量)金额/人数/增/回/倍(展示数据)
-     */
-    @ApiModelProperty(value = "付费趋势:3天(买量)金额/人数/增/回/倍")
+    @ApiModelProperty(value = "付费趋势:1~29天(买量)金额/人数/增/回/倍")
+    private RechargeTrendVO buyAmountD2Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(买量)金额/人数/增/回/倍")
     private RechargeTrendVO buyAmountD3Trend;
 
-    /**
-     * 付费趋势:5天(买量)金额/人数/增/回/倍(展示数据)
-     */
-    @ApiModelProperty(value = "付费趋势:5天(买量)金额/人数/增/回/倍")
+    @ApiModelProperty(value = "付费趋势:1~29天(买量)金额/人数/增/回/倍")
+    private RechargeTrendVO buyAmountD4Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(买量)金额/人数/增/回/倍")
     private RechargeTrendVO buyAmountD5Trend;
 
-    /**
-     * 付费趋势:7天(买量)金额/人数/增/回/倍(展示数据)
-     */
-    @ApiModelProperty(value = "付费趋势:7天(买量)金额/人数/增/回/倍")
+    @ApiModelProperty(value = "付费趋势:1~29天(买量)金额/人数/增/回/倍")
+    private RechargeTrendVO buyAmountD6Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(买量)金额/人数/增/回/倍")
     private RechargeTrendVO buyAmountD7Trend;
 
-    /**
-     * 付费趋势:15天(买量)金额/人数/增/回/倍(展示数据)
-     */
-    @ApiModelProperty(value = "付费趋势:15天(买量)金额/人数/增/回/倍")
+    @ApiModelProperty(value = "付费趋势:1~29天(买量)金额/人数/增/回/倍")
+    private RechargeTrendVO buyAmountD8Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(买量)金额/人数/增/回/倍")
+    private RechargeTrendVO buyAmountD9Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(买量)金额/人数/增/回/倍")
+    private RechargeTrendVO buyAmountD10Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(买量)金额/人数/增/回/倍")
+    private RechargeTrendVO buyAmountD11Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(买量)金额/人数/增/回/倍")
+    private RechargeTrendVO buyAmountD12Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(买量)金额/人数/增/回/倍")
+    private RechargeTrendVO buyAmountD13Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(买量)金额/人数/增/回/倍")
+    private RechargeTrendVO buyAmountD14Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(买量)金额/人数/增/回/倍")
     private RechargeTrendVO buyAmountD15Trend;
 
-    /**
-     * 付费趋势:1个月(买量)金额/人数/增/回/倍(展示数据)
-     */
+    @ApiModelProperty(value = "付费趋势:1~29天(买量)金额/人数/增/回/倍")
+    private RechargeTrendVO buyAmountD16Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(买量)金额/人数/增/回/倍")
+    private RechargeTrendVO buyAmountD17Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(买量)金额/人数/增/回/倍")
+    private RechargeTrendVO buyAmountD18Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(买量)金额/人数/增/回/倍")
+    private RechargeTrendVO buyAmountD19Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(买量)金额/人数/增/回/倍")
+    private RechargeTrendVO buyAmountD20Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(买量)金额/人数/增/回/倍")
+    private RechargeTrendVO buyAmountD21Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(买量)金额/人数/增/回/倍")
+    private RechargeTrendVO buyAmountD22Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(买量)金额/人数/增/回/倍")
+    private RechargeTrendVO buyAmountD23Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(买量)金额/人数/增/回/倍")
+    private RechargeTrendVO buyAmountD24Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(买量)金额/人数/增/回/倍")
+    private RechargeTrendVO buyAmountD25Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(买量)金额/人数/增/回/倍")
+    private RechargeTrendVO buyAmountD26Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(买量)金额/人数/增/回/倍")
+    private RechargeTrendVO buyAmountD27Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(买量)金额/人数/增/回/倍")
+    private RechargeTrendVO buyAmountD28Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(买量)金额/人数/增/回/倍")
+    private RechargeTrendVO buyAmountD29Trend;
+
     @ApiModelProperty(value = "付费趋势:1个月(买量)金额/人数/增/回/倍")
     private RechargeTrendVO buyAmountM1Trend;
 
-    /**
-     * 付费趋势:2个月(买量)金额/人数/增/回/倍(展示数据)
-     */
     @ApiModelProperty(value = "付费趋势:2个月(买量)金额/人数/增/回/倍")
     private RechargeTrendVO buyAmountM2Trend;
 
-    /**
-     * 付费趋势:3个月(买量)金额/人数/增/回/倍(展示数据)
-     */
     @ApiModelProperty(value = "付费趋势:3个月(买量)金额/人数/增/回/倍")
     private RechargeTrendVO buyAmountM3Trend;
 
-    /**
-     * 付费趋势:6个月(买量)金额/人数/增/回/倍(展示数据)
-     */
     @ApiModelProperty(value = "付费趋势:6个月(买量)金额/人数/增/回/倍")
     private RechargeTrendVO buyAmountM6Trend;
 
-    /**
-     * 付费趋势:总(买量)金额/人数/增/回/倍(展示数据)
-     */
+    @ApiModelProperty(value = "付费趋势:1年(买量)金额/人数/增/回/倍")
+    private RechargeTrendVO buyAmountY1Trend;
+
     @ApiModelProperty(value = "付费趋势:总(买量)金额/人数/增/回/倍")
     private RechargeTrendVO buyAmountSumTrend;
 
-    /**
-     * 付费趋势:1天(自然量)金额/人数/增/回/倍(展示数据)
-     */
-    @ApiModelProperty(value = "付费趋势:1天(自然量)金额/人数/增/回/倍")
+    @ApiModelProperty(value = "付费趋势:1~29天(自然量)金额/人数/增/回/倍")
     private RechargeTrendVO natureAmountD1Trend;
 
-    /**
-     * 付费趋势:3天(自然量)金额/人数/增/回/倍(展示数据)
-     */
-    @ApiModelProperty(value = "付费趋势:3天(自然量)金额/人数/增/回/倍")
+    @ApiModelProperty(value = "付费趋势:1~29天(自然量)金额/人数/增/回/倍")
+    private RechargeTrendVO natureAmountD2Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(自然量)金额/人数/增/回/倍")
     private RechargeTrendVO natureAmountD3Trend;
 
-    /**
-     * 付费趋势:5天(自然量)金额/人数/增/回/倍(展示数据)
-     */
-    @ApiModelProperty(value = "付费趋势:5天(自然量)金额/人数/增/回/倍")
+    @ApiModelProperty(value = "付费趋势:1~29天(自然量)金额/人数/增/回/倍")
+    private RechargeTrendVO natureAmountD4Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(自然量)金额/人数/增/回/倍")
     private RechargeTrendVO natureAmountD5Trend;
 
-    /**
-     * 付费趋势:7天(自然量)金额/人数/增/回/倍(展示数据)
-     */
-    @ApiModelProperty(value = "付费趋势:7天(自然量)金额/人数/增/回/倍")
+    @ApiModelProperty(value = "付费趋势:1~29天(自然量)金额/人数/增/回/倍")
+    private RechargeTrendVO natureAmountD6Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(自然量)金额/人数/增/回/倍")
     private RechargeTrendVO natureAmountD7Trend;
 
-    /**
-     * 付费趋势:15天(自然量)金额/人数/增/回/倍(展示数据)
-     */
-    @ApiModelProperty(value = "付费趋势:15天(自然量)金额/人数/增/回/倍")
+    @ApiModelProperty(value = "付费趋势:1~29天(自然量)金额/人数/增/回/倍")
+    private RechargeTrendVO natureAmountD8Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(自然量)金额/人数/增/回/倍")
+    private RechargeTrendVO natureAmountD9Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(自然量)金额/人数/增/回/倍")
+    private RechargeTrendVO natureAmountD10Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(自然量)金额/人数/增/回/倍")
+    private RechargeTrendVO natureAmountD11Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(自然量)金额/人数/增/回/倍")
+    private RechargeTrendVO natureAmountD12Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(自然量)金额/人数/增/回/倍")
+    private RechargeTrendVO natureAmountD13Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(自然量)金额/人数/增/回/倍")
+    private RechargeTrendVO natureAmountD14Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(自然量)金额/人数/增/回/倍")
     private RechargeTrendVO natureAmountD15Trend;
 
-    /**
-     * 付费趋势:1个月(自然量)金额/人数/增/回/倍(展示数据)
-     */
+    @ApiModelProperty(value = "付费趋势:1~29天(自然量)金额/人数/增/回/倍")
+    private RechargeTrendVO natureAmountD16Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(自然量)金额/人数/增/回/倍")
+    private RechargeTrendVO natureAmountD17Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(自然量)金额/人数/增/回/倍")
+    private RechargeTrendVO natureAmountD18Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(自然量)金额/人数/增/回/倍")
+    private RechargeTrendVO natureAmountD19Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(自然量)金额/人数/增/回/倍")
+    private RechargeTrendVO natureAmountD20Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(自然量)金额/人数/增/回/倍")
+    private RechargeTrendVO natureAmountD21Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(自然量)金额/人数/增/回/倍")
+    private RechargeTrendVO natureAmountD22Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(自然量)金额/人数/增/回/倍")
+    private RechargeTrendVO natureAmountD23Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(自然量)金额/人数/增/回/倍")
+    private RechargeTrendVO natureAmountD24Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(自然量)金额/人数/增/回/倍")
+    private RechargeTrendVO natureAmountD25Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(自然量)金额/人数/增/回/倍")
+    private RechargeTrendVO natureAmountD26Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(自然量)金额/人数/增/回/倍")
+    private RechargeTrendVO natureAmountD27Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(自然量)金额/人数/增/回/倍")
+    private RechargeTrendVO natureAmountD28Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(自然量)金额/人数/增/回/倍")
+    private RechargeTrendVO natureAmountD29Trend;
+
     @ApiModelProperty(value = "付费趋势:1个月(自然量)金额/人数/增/回/倍")
     private RechargeTrendVO natureAmountM1Trend;
 
-    /**
-     * 付费趋势:2个月(自然量)金额/人数/增/回/倍(展示数据)
-     */
     @ApiModelProperty(value = "付费趋势:2个月(自然量)金额/人数/增/回/倍")
     private RechargeTrendVO natureAmountM2Trend;
 
-    /**
-     * 付费趋势:3个月(自然量)金额/人数/增/回/倍(展示数据)
-     */
     @ApiModelProperty(value = "付费趋势:3个月(自然量)金额/人数/增/回/倍")
     private RechargeTrendVO natureAmountM3Trend;
 
-    /**
-     * 付费趋势:6个月(自然量)金额/人数/增/回/倍(展示数据)
-     */
     @ApiModelProperty(value = "付费趋势:6个月(自然量)金额/人数/增/回/倍")
     private RechargeTrendVO natureAmountM6Trend;
 
+    @ApiModelProperty(value = "付费趋势:1年(自然量)金额/人数/增/回/倍")
+    private RechargeTrendVO natureAmountY1Trend;
+
     /**
      * 付费趋势:总(自然量)金额/人数/增/回/倍(展示数据)
      */
     @ApiModelProperty(value = "付费趋势:总(自然量)金额/人数/增/回/倍")
     private RechargeTrendVO natureAmountSumTrend;
 
-    /**
-     * 付费趋势:1天(总量)金额/人数/增/回/倍(展示数据)
-     */
-    @ApiModelProperty(value = "付费趋势:1天(总量)金额/人数/增/回/倍")
+    @ApiModelProperty(value = "付费趋势:1~29天(总量)金额/人数/增/回/倍")
     private RechargeTrendVO amountD1Trend;
 
-    /**
-     * 付费趋势:3天(总量)金额/人数/增/回/倍(展示数据)
-     */
-    @ApiModelProperty(value = "付费趋势:3天(总量)金额/人数/增/回/倍")
+    @ApiModelProperty(value = "付费趋势:1~29天(总量)金额/人数/增/回/倍")
+    private RechargeTrendVO amountD2Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(总量)金额/人数/增/回/倍")
     private RechargeTrendVO amountD3Trend;
 
-    /**
-     * 付费趋势:5天(总量)金额/人数/增/回/倍(展示数据)
-     */
+    @ApiModelProperty(value = "付费趋势:1~29天(总量)金额/人数/增/回/倍")
+    private RechargeTrendVO amountD4Trend;
+
     @ApiModelProperty(value = "付费趋势:5天(总量)金额/人数/增/回/倍")
     private RechargeTrendVO amountD5Trend;
 
-    /**
-     * 付费趋势:7天(总量)金额/人数/增/回/倍(展示数据)
-     */
-    @ApiModelProperty(value = "付费趋势:7天(总量)金额/人数/增/回/倍")
+    @ApiModelProperty(value = "付费趋势:1~29天(总量)金额/人数/增/回/倍")
+    private RechargeTrendVO amountD6Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(总量)金额/人数/增/回/倍")
     private RechargeTrendVO amountD7Trend;
 
-    /**
-     * 付费趋势:15天(总量)金额/人数/增/回/倍(展示数据)
-     */
-    @ApiModelProperty(value = "付费趋势:15天(总量)金额/人数/增/回/倍")
+    @ApiModelProperty(value = "付费趋势:1~29天(总量)金额/人数/增/回/倍")
+    private RechargeTrendVO amountD8Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(总量)金额/人数/增/回/倍")
+    private RechargeTrendVO amountD9Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(总量)金额/人数/增/回/倍")
+    private RechargeTrendVO amountD10Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(总量)金额/人数/增/回/倍")
+    private RechargeTrendVO amountD11Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(总量)金额/人数/增/回/倍")
+    private RechargeTrendVO amountD12Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(总量)金额/人数/增/回/倍")
+    private RechargeTrendVO amountD13Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(总量)金额/人数/增/回/倍")
+    private RechargeTrendVO amountD14Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(总量)金额/人数/增/回/倍")
     private RechargeTrendVO amountD15Trend;
 
-    /**
-     * 付费趋势:1个月(总量)金额/人数/增/回/倍(展示数据)
-     */
+    @ApiModelProperty(value = "付费趋势:1~29天(总量)金额/人数/增/回/倍")
+    private RechargeTrendVO amountD16Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(总量)金额/人数/增/回/倍")
+    private RechargeTrendVO amountD17Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(总量)金额/人数/增/回/倍")
+    private RechargeTrendVO amountD18Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(总量)金额/人数/增/回/倍")
+    private RechargeTrendVO amountD19Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(总量)金额/人数/增/回/倍")
+    private RechargeTrendVO amountD20Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(总量)金额/人数/增/回/倍")
+    private RechargeTrendVO amountD21Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(总量)金额/人数/增/回/倍")
+    private RechargeTrendVO amountD22Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(总量)金额/人数/增/回/倍")
+    private RechargeTrendVO amountD23Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(总量)金额/人数/增/回/倍")
+    private RechargeTrendVO amountD24Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(总量)金额/人数/增/回/倍")
+    private RechargeTrendVO amountD25Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(总量)金额/人数/增/回/倍")
+    private RechargeTrendVO amountD26Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(总量)金额/人数/增/回/倍")
+    private RechargeTrendVO amountD27Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(总量)金额/人数/增/回/倍")
+    private RechargeTrendVO amountD28Trend;
+
+    @ApiModelProperty(value = "付费趋势:1~29天(总量)金额/人数/增/回/倍")
+    private RechargeTrendVO amountD29Trend;
+
     @ApiModelProperty(value = "付费趋势:1个月(总量)金额/人数/增/回/倍")
     private RechargeTrendVO amountM1Trend;
 
-    /**
-     * 付费趋势:2个月(总量)金额/人数/增/回/倍(展示数据)
-     */
     @ApiModelProperty(value = "付费趋势:2个月(总量)金额/人数/增/回/倍")
     private RechargeTrendVO amountM2Trend;
 
-    /**
-     * 付费趋势:3个月(总量)金额/人数/增/回/倍(展示数据)
-     */
     @ApiModelProperty(value = "付费趋势:3个月(总量)金额/人数/增/回/倍")
     private RechargeTrendVO amountM3Trend;
 
-    /**
-     * 付费趋势:6个月(总量)金额/人数/增/回/倍(展示数据)
-     */
     @ApiModelProperty(value = "付费趋势:6个月(总量)金额/人数/增/回/倍")
     private RechargeTrendVO amountM6Trend;
 
-    /**
-     * 付费趋势:总(总量)金额/人数/增/回/倍(展示数据)
-     */
+    @ApiModelProperty(value = "付费趋势:1年(总量)金额/人数/增/回/倍")
+    private RechargeTrendVO amountY1Trend;
+
     @ApiModelProperty(value = "付费趋势:总(总量)金额/人数/增/回/倍")
     private RechargeTrendVO amountSumTrend;
 

+ 235 - 0
game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/vo/GamePromoteDayTotalVO.java

@@ -143,30 +143,111 @@ public class GamePromoteDayTotalVO {
     @ApiModelProperty(notes = "毛利额=新用户累计充值金额-实际消耗")
     private BigDecimal grossMargin;
 
+    @ApiModelProperty(notes = "1日ROI=新用户1日累计充值金额/实际消耗")
+    private BigDecimal roiDay1;
+
+    @ApiModelProperty(notes = "2日ROI=新用户2日累计充值金额/实际消耗")
+    private BigDecimal roiDay2;
+
     @ApiModelProperty(notes = "3日ROI=新用户3日累计充值金额/实际消耗")
     private BigDecimal roiDay3;
 
+    @ApiModelProperty(notes = "4日ROI=新用户4日累计充值金额/实际消耗")
+    private BigDecimal roiDay4;
+
     @ApiModelProperty(notes = "5日ROI=新用户5日累计充值金额/实际消耗")
     private BigDecimal roiDay5;
 
+    @ApiModelProperty(notes = "6日ROI=新用户6日累计充值金额/实际消耗")
+    private BigDecimal roiDay6;
+
     @ApiModelProperty(notes = "7日ROI=新用户7日累计充值金额/实际消耗")
     private BigDecimal roiDay7;
 
+    @ApiModelProperty(notes = "8日ROI=新用户8日累计充值金额/实际消耗")
+    private BigDecimal roiDay8;
+
+    @ApiModelProperty(notes = "9日ROI=新用户9日累计充值金额/实际消耗")
+    private BigDecimal roiDay9;
+
+    @ApiModelProperty(notes = "10日ROI=新用户10日累计充值金额/实际消耗")
+    private BigDecimal roiDay10;
+
+    @ApiModelProperty(notes = "11日ROI=新用户11日累计充值金额/实际消耗")
+    private BigDecimal roiDay11;
+
+    @ApiModelProperty(notes = "12日ROI=新用户12日累计充值金额/实际消耗")
+    private BigDecimal roiDay12;
+
+    @ApiModelProperty(notes = "13日ROI=新用户13日累计充值金额/实际消耗")
+    private BigDecimal roiDay13;
+
+    @ApiModelProperty(notes = "14日ROI=新用户14日累计充值金额/实际消耗")
+    private BigDecimal roiDay14;
+
     @ApiModelProperty(notes = "15日ROI=新用户15日累计充值金额/实际消耗")
     private BigDecimal roiDay15;
 
+    @ApiModelProperty(notes = "16日ROI=新用户16日累计充值金额/实际消耗")
+    private BigDecimal roiDay16;
+
+    @ApiModelProperty(notes = "17日ROI=新用户17日累计充值金额/实际消耗")
+    private BigDecimal roiDay17;
+
+    @ApiModelProperty(notes = "18日ROI=新用户18日累计充值金额/实际消耗")
+    private BigDecimal roiDay18;
+
+    @ApiModelProperty(notes = "19日ROI=新用户19日累计充值金额/实际消耗")
+    private BigDecimal roiDay19;
+
+    @ApiModelProperty(notes = "20日ROI=新用户20日累计充值金额/实际消耗")
+    private BigDecimal roiDay20;
+
+    @ApiModelProperty(notes = "21日ROI=新用户21日累计充值金额/实际消耗")
+    private BigDecimal roiDay21;
+
+    @ApiModelProperty(notes = "22日ROI=新用户22日累计充值金额/实际消耗")
+    private BigDecimal roiDay22;
+
+    @ApiModelProperty(notes = "23日ROI=新用户23日累计充值金额/实际消耗")
+    private BigDecimal roiDay23;
+
+    @ApiModelProperty(notes = "24日ROI=新用户24日累计充值金额/实际消耗")
+    private BigDecimal roiDay24;
+
+    @ApiModelProperty(notes = "25日ROI=新用户25日累计充值金额/实际消耗")
+    private BigDecimal roiDay25;
+
+    @ApiModelProperty(notes = "26日ROI=新用户26日累计充值金额/实际消耗")
+    private BigDecimal roiDay26;
+
+    @ApiModelProperty(notes = "27日ROI=新用户27日累计充值金额/实际消耗")
+    private BigDecimal roiDay27;
+
+    @ApiModelProperty(notes = "28日ROI=新用户28日累计充值金额/实际消耗")
+    private BigDecimal roiDay28;
+
+    @ApiModelProperty(notes = "29日ROI=新用户29日累计充值金额/实际消耗")
+    private BigDecimal roiDay29;
+
     @ApiModelProperty(notes = "30日ROI=新用户30日累计充值金额/实际消耗")
     private BigDecimal roiDay30;
 
     @ApiModelProperty(notes = "60日ROI=新用户60日累计充值金额/实际消耗")
     private BigDecimal roiDay60;
 
+    @ApiModelProperty(notes = "90日ROI=新用户90日累计充值金额/实际消耗")
+    private BigDecimal roiDay90;
+
     @ApiModelProperty(notes = "180日ROI=新用户180日累计充值金额/实际消耗")
     private BigDecimal roiDay180;
 
     @ApiModelProperty(notes = "一年ROI=新用户一年累计充值金额/实际消耗")
     private BigDecimal roiYear1;
 
+    @ApiModelProperty(notes = "总ROI=新用户累计充值金额/实际消耗")
+    private BigDecimal roiTotal;
+
     @ApiModelProperty(notes = "首日付费率=首日新用户充值人数/注册人数")
     private BigDecimal firstRechargeRate;
 
@@ -209,18 +290,94 @@ public class GamePromoteDayTotalVO {
     @ApiModelProperty(notes = "不展示--付费趋势:1天")
     private String trendDay1;
 
+    @ApiModelProperty(notes = "不展示--付费趋势:2天")
+    private String trendDay2;
+
     @ApiModelProperty(notes = "不展示--付费趋势:3天")
     private String trendDay3;
 
+    @ApiModelProperty(notes = "不展示--付费趋势:4天")
+    private String trendDay4;
+
     @ApiModelProperty(notes = "不展示--付费趋势:5天")
     private String trendDay5;
 
+    @ApiModelProperty(notes = "不展示--付费趋势:6天")
+    private String trendDay6;
+
     @ApiModelProperty(notes = "不展示--付费趋势:7天")
     private String trendDay7;
 
+    @ApiModelProperty(notes = "不展示--付费趋势:8天")
+    private String trendDay8;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:9天")
+    private String trendDay9;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:10天")
+    private String trendDay10;
+
+    // Continue the pattern for trendDay11 to trendDay30
+    @ApiModelProperty(notes = "不展示--付费趋势:11天")
+    private String trendDay11;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:12天")
+    private String trendDay12;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:13天")
+    private String trendDay13;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:14天")
+    private String trendDay14;
+
     @ApiModelProperty(notes = "不展示--付费趋势:15天")
     private String trendDay15;
 
+    // Continue the pattern for trendDay16 to trendDay30
+    @ApiModelProperty(notes = "不展示--付费趋势:16天")
+    private String trendDay16;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:17天")
+    private String trendDay17;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:18天")
+    private String trendDay18;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:19天")
+    private String trendDay19;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:20天")
+    private String trendDay20;
+
+    // Continue the pattern for trendDay21 to trendDay30
+    @ApiModelProperty(notes = "不展示--付费趋势:21天")
+    private String trendDay21;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:22天")
+    private String trendDay22;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:23天")
+    private String trendDay23;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:24天")
+    private String trendDay24;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:25天")
+    private String trendDay25;
+
+    // Continue the pattern for trendDay26 to trendDay30
+    @ApiModelProperty(notes = "不展示--付费趋势:26天")
+    private String trendDay26;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:27天")
+    private String trendDay27;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:28天")
+    private String trendDay28;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:29天")
+    private String trendDay29;
+
     @ApiModelProperty(notes = "不展示--付费趋势:1个月")
     private String trendMonth1;
 
@@ -233,24 +390,99 @@ public class GamePromoteDayTotalVO {
     @ApiModelProperty(notes = "不展示--付费趋势:6个月")
     private String trendMonth6;
 
+    @ApiModelProperty(notes = "不展示--付费趋势:1年")
+    private String trendYear1;
+
     @ApiModelProperty(notes = "不展示--付费趋势:总")
     private String trendTotal;
 
     @ApiModelProperty(notes = "付费趋势:1天")
     private RechargeTrendVO rechargeTrendDay1;
 
+    @ApiModelProperty(notes = "付费趋势:2天")
+    private RechargeTrendVO rechargeTrendDay2;
+
     @ApiModelProperty(notes = "付费趋势:3天")
     private RechargeTrendVO rechargeTrendDay3;
 
+    @ApiModelProperty(notes = "付费趋势:4天")
+    private RechargeTrendVO rechargeTrendDay4;
+
     @ApiModelProperty(notes = "付费趋势:5天")
     private RechargeTrendVO rechargeTrendDay5;
 
+    @ApiModelProperty(notes = "付费趋势:6天")
+    private RechargeTrendVO rechargeTrendDay6;
+
     @ApiModelProperty(notes = "付费趋势:7天")
     private RechargeTrendVO rechargeTrendDay7;
 
+    @ApiModelProperty(notes = "付费趋势:8天")
+    private RechargeTrendVO rechargeTrendDay8;
+
+    @ApiModelProperty(notes = "付费趋势:9天")
+    private RechargeTrendVO rechargeTrendDay9;
+
+    @ApiModelProperty(notes = "付费趋势:10天")
+    private RechargeTrendVO rechargeTrendDay10;
+
+    @ApiModelProperty(notes = "付费趋势:11天")
+    private RechargeTrendVO rechargeTrendDay11;
+
+    @ApiModelProperty(notes = "付费趋势:12天")
+    private RechargeTrendVO rechargeTrendDay12;
+
+    @ApiModelProperty(notes = "付费趋势:13天")
+    private RechargeTrendVO rechargeTrendDay13;
+
+    @ApiModelProperty(notes = "付费趋势:14天")
+    private RechargeTrendVO rechargeTrendDay14;
+
     @ApiModelProperty(notes = "付费趋势:15天")
     private RechargeTrendVO rechargeTrendDay15;
 
+    @ApiModelProperty(notes = "付费趋势:16天")
+    private RechargeTrendVO rechargeTrendDay16;
+
+    @ApiModelProperty(notes = "付费趋势:17天")
+    private RechargeTrendVO rechargeTrendDay17;
+
+    @ApiModelProperty(notes = "付费趋势:18天")
+    private RechargeTrendVO rechargeTrendDay18;
+
+    @ApiModelProperty(notes = "付费趋势:19天")
+    private RechargeTrendVO rechargeTrendDay19;
+
+    @ApiModelProperty(notes = "付费趋势:20天")
+    private RechargeTrendVO rechargeTrendDay20;
+
+    @ApiModelProperty(notes = "付费趋势:21天")
+    private RechargeTrendVO rechargeTrendDay21;
+
+    @ApiModelProperty(notes = "付费趋势:22天")
+    private RechargeTrendVO rechargeTrendDay22;
+
+    @ApiModelProperty(notes = "付费趋势:23天")
+    private RechargeTrendVO rechargeTrendDay23;
+
+    @ApiModelProperty(notes = "付费趋势:24天")
+    private RechargeTrendVO rechargeTrendDay24;
+
+    @ApiModelProperty(notes = "付费趋势:25天")
+    private RechargeTrendVO rechargeTrendDay25;
+
+    @ApiModelProperty(notes = "付费趋势:26天")
+    private RechargeTrendVO rechargeTrendDay26;
+
+    @ApiModelProperty(notes = "付费趋势:27天")
+    private RechargeTrendVO rechargeTrendDay27;
+
+    @ApiModelProperty(notes = "付费趋势:28天")
+    private RechargeTrendVO rechargeTrendDay28;
+
+    @ApiModelProperty(notes = "付费趋势:29天")
+    private RechargeTrendVO rechargeTrendDay29;
+
     @ApiModelProperty(notes = "付费趋势:1个月")
     private RechargeTrendVO rechargeTrendMonth1;
 
@@ -263,6 +495,9 @@ public class GamePromoteDayTotalVO {
     @ApiModelProperty(notes = "付费趋势:6个月")
     private RechargeTrendVO rechargeTrendMonth6;
 
+    @ApiModelProperty(notes = "付费趋势:1年")
+    private RechargeTrendVO rechargeTrendYear1;
+
     @ApiModelProperty(notes = "付费趋势:总")
     private RechargeTrendVO rechargeTrendTotal;
 

+ 235 - 0
game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/vo/GamePromoteDayVO.java

@@ -188,30 +188,111 @@ public class GamePromoteDayVO {
     @ApiModelProperty(notes = "毛利额=新用户累计充值金额-实际消耗")
     private BigDecimal grossMargin;
 
+    @ApiModelProperty(notes = "1日ROI=新用户1日累计充值金额/实际消耗")
+    private BigDecimal roiDay1;
+
+    @ApiModelProperty(notes = "2日ROI=新用户2日累计充值金额/实际消耗")
+    private BigDecimal roiDay2;
+
     @ApiModelProperty(notes = "3日ROI=新用户3日累计充值金额/实际消耗")
     private BigDecimal roiDay3;
 
+    @ApiModelProperty(notes = "4日ROI=新用户4日累计充值金额/实际消耗")
+    private BigDecimal roiDay4;
+
     @ApiModelProperty(notes = "5日ROI=新用户5日累计充值金额/实际消耗")
     private BigDecimal roiDay5;
 
+    @ApiModelProperty(notes = "6日ROI=新用户6日累计充值金额/实际消耗")
+    private BigDecimal roiDay6;
+
     @ApiModelProperty(notes = "7日ROI=新用户7日累计充值金额/实际消耗")
     private BigDecimal roiDay7;
 
+    @ApiModelProperty(notes = "8日ROI=新用户8日累计充值金额/实际消耗")
+    private BigDecimal roiDay8;
+
+    @ApiModelProperty(notes = "9日ROI=新用户9日累计充值金额/实际消耗")
+    private BigDecimal roiDay9;
+
+    @ApiModelProperty(notes = "10日ROI=新用户10日累计充值金额/实际消耗")
+    private BigDecimal roiDay10;
+
+    @ApiModelProperty(notes = "11日ROI=新用户11日累计充值金额/实际消耗")
+    private BigDecimal roiDay11;
+
+    @ApiModelProperty(notes = "12日ROI=新用户12日累计充值金额/实际消耗")
+    private BigDecimal roiDay12;
+
+    @ApiModelProperty(notes = "13日ROI=新用户13日累计充值金额/实际消耗")
+    private BigDecimal roiDay13;
+
+    @ApiModelProperty(notes = "14日ROI=新用户14日累计充值金额/实际消耗")
+    private BigDecimal roiDay14;
+
     @ApiModelProperty(notes = "15日ROI=新用户15日累计充值金额/实际消耗")
     private BigDecimal roiDay15;
 
+    @ApiModelProperty(notes = "16日ROI=新用户16日累计充值金额/实际消耗")
+    private BigDecimal roiDay16;
+
+    @ApiModelProperty(notes = "17日ROI=新用户17日累计充值金额/实际消耗")
+    private BigDecimal roiDay17;
+
+    @ApiModelProperty(notes = "18日ROI=新用户18日累计充值金额/实际消耗")
+    private BigDecimal roiDay18;
+
+    @ApiModelProperty(notes = "19日ROI=新用户19日累计充值金额/实际消耗")
+    private BigDecimal roiDay19;
+
+    @ApiModelProperty(notes = "20日ROI=新用户20日累计充值金额/实际消耗")
+    private BigDecimal roiDay20;
+
+    @ApiModelProperty(notes = "21日ROI=新用户21日累计充值金额/实际消耗")
+    private BigDecimal roiDay21;
+
+    @ApiModelProperty(notes = "22日ROI=新用户22日累计充值金额/实际消耗")
+    private BigDecimal roiDay22;
+
+    @ApiModelProperty(notes = "23日ROI=新用户23日累计充值金额/实际消耗")
+    private BigDecimal roiDay23;
+
+    @ApiModelProperty(notes = "24日ROI=新用户24日累计充值金额/实际消耗")
+    private BigDecimal roiDay24;
+
+    @ApiModelProperty(notes = "25日ROI=新用户25日累计充值金额/实际消耗")
+    private BigDecimal roiDay25;
+
+    @ApiModelProperty(notes = "26日ROI=新用户26日累计充值金额/实际消耗")
+    private BigDecimal roiDay26;
+
+    @ApiModelProperty(notes = "27日ROI=新用户27日累计充值金额/实际消耗")
+    private BigDecimal roiDay27;
+
+    @ApiModelProperty(notes = "28日ROI=新用户28日累计充值金额/实际消耗")
+    private BigDecimal roiDay28;
+
+    @ApiModelProperty(notes = "29日ROI=新用户29日累计充值金额/实际消耗")
+    private BigDecimal roiDay29;
+
     @ApiModelProperty(notes = "30日ROI=新用户30日累计充值金额/实际消耗")
     private BigDecimal roiDay30;
 
     @ApiModelProperty(notes = "60日ROI=新用户60日累计充值金额/实际消耗")
     private BigDecimal roiDay60;
 
+    @ApiModelProperty(notes = "90日ROI=新用户90日累计充值金额/实际消耗")
+    private BigDecimal roiDay90;
+
     @ApiModelProperty(notes = "180日ROI=新用户180日累计充值金额/实际消耗")
     private BigDecimal roiDay180;
 
     @ApiModelProperty(notes = "一年ROI=新用户一年累计充值金额/实际消耗")
     private BigDecimal roiYear1;
 
+    @ApiModelProperty(notes = "总ROI=新用户累计充值金额/实际消耗")
+    private BigDecimal roiTotal;
+
     @ApiModelProperty(notes = "首日付费率=首日新用户充值人数/注册人数")
     private BigDecimal firstRechargeRate;
 
@@ -257,18 +338,94 @@ public class GamePromoteDayVO {
     @ApiModelProperty(notes = "不展示--付费趋势:1天")
     private String trendDay1;
 
+    @ApiModelProperty(notes = "不展示--付费趋势:2天")
+    private String trendDay2;
+
     @ApiModelProperty(notes = "不展示--付费趋势:3天")
     private String trendDay3;
 
+    @ApiModelProperty(notes = "不展示--付费趋势:4天")
+    private String trendDay4;
+
     @ApiModelProperty(notes = "不展示--付费趋势:5天")
     private String trendDay5;
 
+    @ApiModelProperty(notes = "不展示--付费趋势:6天")
+    private String trendDay6;
+
     @ApiModelProperty(notes = "不展示--付费趋势:7天")
     private String trendDay7;
 
+    @ApiModelProperty(notes = "不展示--付费趋势:8天")
+    private String trendDay8;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:9天")
+    private String trendDay9;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:10天")
+    private String trendDay10;
+
+    // Continue the pattern for trendDay11 to trendDay30
+    @ApiModelProperty(notes = "不展示--付费趋势:11天")
+    private String trendDay11;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:12天")
+    private String trendDay12;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:13天")
+    private String trendDay13;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:14天")
+    private String trendDay14;
+
     @ApiModelProperty(notes = "不展示--付费趋势:15天")
     private String trendDay15;
 
+    // Continue the pattern for trendDay16 to trendDay30
+    @ApiModelProperty(notes = "不展示--付费趋势:16天")
+    private String trendDay16;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:17天")
+    private String trendDay17;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:18天")
+    private String trendDay18;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:19天")
+    private String trendDay19;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:20天")
+    private String trendDay20;
+
+    // Continue the pattern for trendDay21 to trendDay30
+    @ApiModelProperty(notes = "不展示--付费趋势:21天")
+    private String trendDay21;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:22天")
+    private String trendDay22;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:23天")
+    private String trendDay23;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:24天")
+    private String trendDay24;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:25天")
+    private String trendDay25;
+
+    // Continue the pattern for trendDay26 to trendDay30
+    @ApiModelProperty(notes = "不展示--付费趋势:26天")
+    private String trendDay26;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:27天")
+    private String trendDay27;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:28天")
+    private String trendDay28;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:29天")
+    private String trendDay29;
+
     @ApiModelProperty(notes = "不展示--付费趋势:1个月")
     private String trendMonth1;
 
@@ -281,24 +438,99 @@ public class GamePromoteDayVO {
     @ApiModelProperty(notes = "不展示--付费趋势:6个月")
     private String trendMonth6;
 
+    @ApiModelProperty(notes = "不展示--付费趋势:1年")
+    private String trendYear1;
+
     @ApiModelProperty(notes = "不展示--付费趋势:总")
     private String trendTotal;
 
     @ApiModelProperty(notes = "付费趋势:1天")
     private RechargeTrendVO rechargeTrendDay1;
 
+    @ApiModelProperty(notes = "付费趋势:2天")
+    private RechargeTrendVO rechargeTrendDay2;
+
     @ApiModelProperty(notes = "付费趋势:3天")
     private RechargeTrendVO rechargeTrendDay3;
 
+    @ApiModelProperty(notes = "付费趋势:4天")
+    private RechargeTrendVO rechargeTrendDay4;
+
     @ApiModelProperty(notes = "付费趋势:5天")
     private RechargeTrendVO rechargeTrendDay5;
 
+    @ApiModelProperty(notes = "付费趋势:6天")
+    private RechargeTrendVO rechargeTrendDay6;
+
     @ApiModelProperty(notes = "付费趋势:7天")
     private RechargeTrendVO rechargeTrendDay7;
 
+    @ApiModelProperty(notes = "付费趋势:8天")
+    private RechargeTrendVO rechargeTrendDay8;
+
+    @ApiModelProperty(notes = "付费趋势:9天")
+    private RechargeTrendVO rechargeTrendDay9;
+
+    @ApiModelProperty(notes = "付费趋势:10天")
+    private RechargeTrendVO rechargeTrendDay10;
+
+    @ApiModelProperty(notes = "付费趋势:11天")
+    private RechargeTrendVO rechargeTrendDay11;
+
+    @ApiModelProperty(notes = "付费趋势:12天")
+    private RechargeTrendVO rechargeTrendDay12;
+
+    @ApiModelProperty(notes = "付费趋势:13天")
+    private RechargeTrendVO rechargeTrendDay13;
+
+    @ApiModelProperty(notes = "付费趋势:14天")
+    private RechargeTrendVO rechargeTrendDay14;
+
     @ApiModelProperty(notes = "付费趋势:15天")
     private RechargeTrendVO rechargeTrendDay15;
 
+    @ApiModelProperty(notes = "付费趋势:16天")
+    private RechargeTrendVO rechargeTrendDay16;
+
+    @ApiModelProperty(notes = "付费趋势:17天")
+    private RechargeTrendVO rechargeTrendDay17;
+
+    @ApiModelProperty(notes = "付费趋势:18天")
+    private RechargeTrendVO rechargeTrendDay18;
+
+    @ApiModelProperty(notes = "付费趋势:19天")
+    private RechargeTrendVO rechargeTrendDay19;
+
+    @ApiModelProperty(notes = "付费趋势:20天")
+    private RechargeTrendVO rechargeTrendDay20;
+
+    @ApiModelProperty(notes = "付费趋势:21天")
+    private RechargeTrendVO rechargeTrendDay21;
+
+    @ApiModelProperty(notes = "付费趋势:22天")
+    private RechargeTrendVO rechargeTrendDay22;
+
+    @ApiModelProperty(notes = "付费趋势:23天")
+    private RechargeTrendVO rechargeTrendDay23;
+
+    @ApiModelProperty(notes = "付费趋势:24天")
+    private RechargeTrendVO rechargeTrendDay24;
+
+    @ApiModelProperty(notes = "付费趋势:25天")
+    private RechargeTrendVO rechargeTrendDay25;
+
+    @ApiModelProperty(notes = "付费趋势:26天")
+    private RechargeTrendVO rechargeTrendDay26;
+
+    @ApiModelProperty(notes = "付费趋势:27天")
+    private RechargeTrendVO rechargeTrendDay27;
+
+    @ApiModelProperty(notes = "付费趋势:28天")
+    private RechargeTrendVO rechargeTrendDay28;
+
+    @ApiModelProperty(notes = "付费趋势:29天")
+    private RechargeTrendVO rechargeTrendDay29;
+
     @ApiModelProperty(notes = "付费趋势:1个月")
     private RechargeTrendVO rechargeTrendMonth1;
 
@@ -311,6 +543,9 @@ public class GamePromoteDayVO {
     @ApiModelProperty(notes = "付费趋势:6个月")
     private RechargeTrendVO rechargeTrendMonth6;
 
+    @ApiModelProperty(notes = "付费趋势:1年")
+    private RechargeTrendVO rechargeTrendYear1;
+
     @ApiModelProperty(notes = "付费趋势:总")
     private RechargeTrendVO rechargeTrendTotal;
 

+ 295 - 0
game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/vo/GamePromoteTotalSumVO.java

@@ -155,30 +155,325 @@ public class GamePromoteTotalSumVO {
     @ApiModelProperty(notes = "毛利额=新用户累计充值金额-实际消耗")
     private BigDecimal grossMargin;
 
+    @ApiModelProperty(notes = "1日ROI=新用户1日累计充值金额/实际消耗")
+    private BigDecimal roiDay1;
+
+    @ApiModelProperty(notes = "2日ROI=新用户2日累计充值金额/实际消耗")
+    private BigDecimal roiDay2;
+
     @ApiModelProperty(notes = "3日ROI=新用户3日累计充值金额/实际消耗")
     private BigDecimal roiDay3;
 
+    @ApiModelProperty(notes = "4日ROI=新用户4日累计充值金额/实际消耗")
+    private BigDecimal roiDay4;
+
     @ApiModelProperty(notes = "5日ROI=新用户5日累计充值金额/实际消耗")
     private BigDecimal roiDay5;
 
+    @ApiModelProperty(notes = "6日ROI=新用户6日累计充值金额/实际消耗")
+    private BigDecimal roiDay6;
+
     @ApiModelProperty(notes = "7日ROI=新用户7日累计充值金额/实际消耗")
     private BigDecimal roiDay7;
 
+    @ApiModelProperty(notes = "8日ROI=新用户8日累计充值金额/实际消耗")
+    private BigDecimal roiDay8;
+
+    @ApiModelProperty(notes = "9日ROI=新用户9日累计充值金额/实际消耗")
+    private BigDecimal roiDay9;
+
+    @ApiModelProperty(notes = "10日ROI=新用户10日累计充值金额/实际消耗")
+    private BigDecimal roiDay10;
+
+    @ApiModelProperty(notes = "11日ROI=新用户11日累计充值金额/实际消耗")
+    private BigDecimal roiDay11;
+
+    @ApiModelProperty(notes = "12日ROI=新用户12日累计充值金额/实际消耗")
+    private BigDecimal roiDay12;
+
+    @ApiModelProperty(notes = "13日ROI=新用户13日累计充值金额/实际消耗")
+    private BigDecimal roiDay13;
+
+    @ApiModelProperty(notes = "14日ROI=新用户14日累计充值金额/实际消耗")
+    private BigDecimal roiDay14;
+
     @ApiModelProperty(notes = "15日ROI=新用户15日累计充值金额/实际消耗")
     private BigDecimal roiDay15;
 
+    @ApiModelProperty(notes = "16日ROI=新用户16日累计充值金额/实际消耗")
+    private BigDecimal roiDay16;
+
+    @ApiModelProperty(notes = "17日ROI=新用户17日累计充值金额/实际消耗")
+    private BigDecimal roiDay17;
+
+    @ApiModelProperty(notes = "18日ROI=新用户18日累计充值金额/实际消耗")
+    private BigDecimal roiDay18;
+
+    @ApiModelProperty(notes = "19日ROI=新用户19日累计充值金额/实际消耗")
+    private BigDecimal roiDay19;
+
+    @ApiModelProperty(notes = "20日ROI=新用户20日累计充值金额/实际消耗")
+    private BigDecimal roiDay20;
+
+    @ApiModelProperty(notes = "21日ROI=新用户21日累计充值金额/实际消耗")
+    private BigDecimal roiDay21;
+
+    @ApiModelProperty(notes = "22日ROI=新用户22日累计充值金额/实际消耗")
+    private BigDecimal roiDay22;
+
+    @ApiModelProperty(notes = "23日ROI=新用户23日累计充值金额/实际消耗")
+    private BigDecimal roiDay23;
+
+    @ApiModelProperty(notes = "24日ROI=新用户24日累计充值金额/实际消耗")
+    private BigDecimal roiDay24;
+
+    @ApiModelProperty(notes = "25日ROI=新用户25日累计充值金额/实际消耗")
+    private BigDecimal roiDay25;
+
+    @ApiModelProperty(notes = "26日ROI=新用户26日累计充值金额/实际消耗")
+    private BigDecimal roiDay26;
+
+    @ApiModelProperty(notes = "27日ROI=新用户27日累计充值金额/实际消耗")
+    private BigDecimal roiDay27;
+
+    @ApiModelProperty(notes = "28日ROI=新用户28日累计充值金额/实际消耗")
+    private BigDecimal roiDay28;
+
+    @ApiModelProperty(notes = "29日ROI=新用户29日累计充值金额/实际消耗")
+    private BigDecimal roiDay29;
+
     @ApiModelProperty(notes = "30日ROI=新用户30日累计充值金额/实际消耗")
     private BigDecimal roiDay30;
 
     @ApiModelProperty(notes = "60日ROI=新用户60日累计充值金额/实际消耗")
     private BigDecimal roiDay60;
 
+    @ApiModelProperty(notes = "90日ROI=新用户90日累计充值金额/实际消耗")
+    private BigDecimal roiDay90;
+
     @ApiModelProperty(notes = "180日ROI=新用户180日累计充值金额/实际消耗")
     private BigDecimal roiDay180;
 
     @ApiModelProperty(notes = "一年ROI=新用户一年累计充值金额/实际消耗")
     private BigDecimal roiYear1;
 
+    @ApiModelProperty(notes = "总ROI=新用户累计充值金额/实际消耗")
+    private BigDecimal roiTotal;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:1天")
+    private String trendDay1;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:2天")
+    private String trendDay2;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:3天")
+    private String trendDay3;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:4天")
+    private String trendDay4;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:5天")
+    private String trendDay5;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:6天")
+    private String trendDay6;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:7天")
+    private String trendDay7;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:8天")
+    private String trendDay8;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:9天")
+    private String trendDay9;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:10天")
+    private String trendDay10;
+
+    // Continue the pattern for trendDay11 to trendDay30
+    @ApiModelProperty(notes = "不展示--付费趋势:11天")
+    private String trendDay11;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:12天")
+    private String trendDay12;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:13天")
+    private String trendDay13;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:14天")
+    private String trendDay14;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:15天")
+    private String trendDay15;
+
+    // Continue the pattern for trendDay16 to trendDay30
+    @ApiModelProperty(notes = "不展示--付费趋势:16天")
+    private String trendDay16;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:17天")
+    private String trendDay17;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:18天")
+    private String trendDay18;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:19天")
+    private String trendDay19;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:20天")
+    private String trendDay20;
+
+    // Continue the pattern for trendDay21 to trendDay30
+    @ApiModelProperty(notes = "不展示--付费趋势:21天")
+    private String trendDay21;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:22天")
+    private String trendDay22;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:23天")
+    private String trendDay23;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:24天")
+    private String trendDay24;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:25天")
+    private String trendDay25;
+
+    // Continue the pattern for trendDay26 to trendDay30
+    @ApiModelProperty(notes = "不展示--付费趋势:26天")
+    private String trendDay26;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:27天")
+    private String trendDay27;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:28天")
+    private String trendDay28;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:29天")
+    private String trendDay29;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:1个月")
+    private String trendMonth1;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:2个月")
+    private String trendMonth2;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:3个月")
+    private String trendMonth3;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:6个月")
+    private String trendMonth6;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:1年")
+    private String trendYear1;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:总")
+    private String trendTotal;
+
+    @ApiModelProperty(notes = "付费趋势:1天")
+    private RechargeTrendVO rechargeTrendDay1;
+
+    @ApiModelProperty(notes = "付费趋势:2天")
+    private RechargeTrendVO rechargeTrendDay2;
+
+    @ApiModelProperty(notes = "付费趋势:3天")
+    private RechargeTrendVO rechargeTrendDay3;
+
+    @ApiModelProperty(notes = "付费趋势:4天")
+    private RechargeTrendVO rechargeTrendDay4;
+
+    @ApiModelProperty(notes = "付费趋势:5天")
+    private RechargeTrendVO rechargeTrendDay5;
+
+    @ApiModelProperty(notes = "付费趋势:6天")
+    private RechargeTrendVO rechargeTrendDay6;
+
+    @ApiModelProperty(notes = "付费趋势:7天")
+    private RechargeTrendVO rechargeTrendDay7;
+
+    @ApiModelProperty(notes = "付费趋势:8天")
+    private RechargeTrendVO rechargeTrendDay8;
+
+    @ApiModelProperty(notes = "付费趋势:9天")
+    private RechargeTrendVO rechargeTrendDay9;
+
+    @ApiModelProperty(notes = "付费趋势:10天")
+    private RechargeTrendVO rechargeTrendDay10;
+
+    @ApiModelProperty(notes = "付费趋势:11天")
+    private RechargeTrendVO rechargeTrendDay11;
+
+    @ApiModelProperty(notes = "付费趋势:12天")
+    private RechargeTrendVO rechargeTrendDay12;
+
+    @ApiModelProperty(notes = "付费趋势:13天")
+    private RechargeTrendVO rechargeTrendDay13;
+
+    @ApiModelProperty(notes = "付费趋势:14天")
+    private RechargeTrendVO rechargeTrendDay14;
+
+    @ApiModelProperty(notes = "付费趋势:15天")
+    private RechargeTrendVO rechargeTrendDay15;
+
+    @ApiModelProperty(notes = "付费趋势:16天")
+    private RechargeTrendVO rechargeTrendDay16;
+
+    @ApiModelProperty(notes = "付费趋势:17天")
+    private RechargeTrendVO rechargeTrendDay17;
+
+    @ApiModelProperty(notes = "付费趋势:18天")
+    private RechargeTrendVO rechargeTrendDay18;
+
+    @ApiModelProperty(notes = "付费趋势:19天")
+    private RechargeTrendVO rechargeTrendDay19;
+
+    @ApiModelProperty(notes = "付费趋势:20天")
+    private RechargeTrendVO rechargeTrendDay20;
+
+    @ApiModelProperty(notes = "付费趋势:21天")
+    private RechargeTrendVO rechargeTrendDay21;
+
+    @ApiModelProperty(notes = "付费趋势:22天")
+    private RechargeTrendVO rechargeTrendDay22;
+
+    @ApiModelProperty(notes = "付费趋势:23天")
+    private RechargeTrendVO rechargeTrendDay23;
+
+    @ApiModelProperty(notes = "付费趋势:24天")
+    private RechargeTrendVO rechargeTrendDay24;
+
+    @ApiModelProperty(notes = "付费趋势:25天")
+    private RechargeTrendVO rechargeTrendDay25;
+
+    @ApiModelProperty(notes = "付费趋势:26天")
+    private RechargeTrendVO rechargeTrendDay26;
+
+    @ApiModelProperty(notes = "付费趋势:27天")
+    private RechargeTrendVO rechargeTrendDay27;
+
+    @ApiModelProperty(notes = "付费趋势:28天")
+    private RechargeTrendVO rechargeTrendDay28;
+
+    @ApiModelProperty(notes = "付费趋势:29天")
+    private RechargeTrendVO rechargeTrendDay29;
+
+    @ApiModelProperty(notes = "付费趋势:1个月")
+    private RechargeTrendVO rechargeTrendMonth1;
+
+    @ApiModelProperty(notes = "付费趋势:2个月")
+    private RechargeTrendVO rechargeTrendMonth2;
+
+    @ApiModelProperty(notes = "付费趋势:3个月")
+    private RechargeTrendVO rechargeTrendMonth3;
+
+    @ApiModelProperty(notes = "付费趋势:6个月")
+    private RechargeTrendVO rechargeTrendMonth6;
+
+    @ApiModelProperty(notes = "付费趋势:1年")
+    private RechargeTrendVO rechargeTrendYear1;
+
+    @ApiModelProperty(notes = "付费趋势:总")
+    private RechargeTrendVO rechargeTrendTotal;
+
     @ApiModelProperty(notes = "首日付费率=首日新用户充值人数/注册人数")
     private BigDecimal firstRechargeRate;
 

+ 295 - 0
game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/vo/GamePromoteTotalVO.java

@@ -187,30 +187,325 @@ public class GamePromoteTotalVO {
     @ApiModelProperty(notes = "毛利额=新用户累计充值金额-实际消耗")
     private BigDecimal grossMargin;
 
+    @ApiModelProperty(notes = "1日ROI=新用户1日累计充值金额/实际消耗")
+    private BigDecimal roiDay1;
+
+    @ApiModelProperty(notes = "2日ROI=新用户2日累计充值金额/实际消耗")
+    private BigDecimal roiDay2;
+
     @ApiModelProperty(notes = "3日ROI=新用户3日累计充值金额/实际消耗")
     private BigDecimal roiDay3;
 
+    @ApiModelProperty(notes = "4日ROI=新用户4日累计充值金额/实际消耗")
+    private BigDecimal roiDay4;
+
     @ApiModelProperty(notes = "5日ROI=新用户5日累计充值金额/实际消耗")
     private BigDecimal roiDay5;
 
+    @ApiModelProperty(notes = "6日ROI=新用户6日累计充值金额/实际消耗")
+    private BigDecimal roiDay6;
+
     @ApiModelProperty(notes = "7日ROI=新用户7日累计充值金额/实际消耗")
     private BigDecimal roiDay7;
 
+    @ApiModelProperty(notes = "8日ROI=新用户8日累计充值金额/实际消耗")
+    private BigDecimal roiDay8;
+
+    @ApiModelProperty(notes = "9日ROI=新用户9日累计充值金额/实际消耗")
+    private BigDecimal roiDay9;
+
+    @ApiModelProperty(notes = "10日ROI=新用户10日累计充值金额/实际消耗")
+    private BigDecimal roiDay10;
+
+    @ApiModelProperty(notes = "11日ROI=新用户11日累计充值金额/实际消耗")
+    private BigDecimal roiDay11;
+
+    @ApiModelProperty(notes = "12日ROI=新用户12日累计充值金额/实际消耗")
+    private BigDecimal roiDay12;
+
+    @ApiModelProperty(notes = "13日ROI=新用户13日累计充值金额/实际消耗")
+    private BigDecimal roiDay13;
+
+    @ApiModelProperty(notes = "14日ROI=新用户14日累计充值金额/实际消耗")
+    private BigDecimal roiDay14;
+
     @ApiModelProperty(notes = "15日ROI=新用户15日累计充值金额/实际消耗")
     private BigDecimal roiDay15;
 
+    @ApiModelProperty(notes = "16日ROI=新用户16日累计充值金额/实际消耗")
+    private BigDecimal roiDay16;
+
+    @ApiModelProperty(notes = "17日ROI=新用户17日累计充值金额/实际消耗")
+    private BigDecimal roiDay17;
+
+    @ApiModelProperty(notes = "18日ROI=新用户18日累计充值金额/实际消耗")
+    private BigDecimal roiDay18;
+
+    @ApiModelProperty(notes = "19日ROI=新用户19日累计充值金额/实际消耗")
+    private BigDecimal roiDay19;
+
+    @ApiModelProperty(notes = "20日ROI=新用户20日累计充值金额/实际消耗")
+    private BigDecimal roiDay20;
+
+    @ApiModelProperty(notes = "21日ROI=新用户21日累计充值金额/实际消耗")
+    private BigDecimal roiDay21;
+
+    @ApiModelProperty(notes = "22日ROI=新用户22日累计充值金额/实际消耗")
+    private BigDecimal roiDay22;
+
+    @ApiModelProperty(notes = "23日ROI=新用户23日累计充值金额/实际消耗")
+    private BigDecimal roiDay23;
+
+    @ApiModelProperty(notes = "24日ROI=新用户24日累计充值金额/实际消耗")
+    private BigDecimal roiDay24;
+
+    @ApiModelProperty(notes = "25日ROI=新用户25日累计充值金额/实际消耗")
+    private BigDecimal roiDay25;
+
+    @ApiModelProperty(notes = "26日ROI=新用户26日累计充值金额/实际消耗")
+    private BigDecimal roiDay26;
+
+    @ApiModelProperty(notes = "27日ROI=新用户27日累计充值金额/实际消耗")
+    private BigDecimal roiDay27;
+
+    @ApiModelProperty(notes = "28日ROI=新用户28日累计充值金额/实际消耗")
+    private BigDecimal roiDay28;
+
+    @ApiModelProperty(notes = "29日ROI=新用户29日累计充值金额/实际消耗")
+    private BigDecimal roiDay29;
+
     @ApiModelProperty(notes = "30日ROI=新用户30日累计充值金额/实际消耗")
     private BigDecimal roiDay30;
 
     @ApiModelProperty(notes = "60日ROI=新用户60日累计充值金额/实际消耗")
     private BigDecimal roiDay60;
 
+    @ApiModelProperty(notes = "90日ROI=新用户90日累计充值金额/实际消耗")
+    private BigDecimal roiDay90;
+
     @ApiModelProperty(notes = "180日ROI=新用户180日累计充值金额/实际消耗")
     private BigDecimal roiDay180;
 
     @ApiModelProperty(notes = "一年ROI=新用户一年累计充值金额/实际消耗")
     private BigDecimal roiYear1;
 
+    @ApiModelProperty(notes = "总ROI=新用户累计充值金额/实际消耗")
+    private BigDecimal roiTotal;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:1天")
+    private String trendDay1;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:2天")
+    private String trendDay2;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:3天")
+    private String trendDay3;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:4天")
+    private String trendDay4;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:5天")
+    private String trendDay5;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:6天")
+    private String trendDay6;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:7天")
+    private String trendDay7;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:8天")
+    private String trendDay8;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:9天")
+    private String trendDay9;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:10天")
+    private String trendDay10;
+
+    // Continue the pattern for trendDay11 to trendDay30
+    @ApiModelProperty(notes = "不展示--付费趋势:11天")
+    private String trendDay11;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:12天")
+    private String trendDay12;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:13天")
+    private String trendDay13;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:14天")
+    private String trendDay14;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:15天")
+    private String trendDay15;
+
+    // Continue the pattern for trendDay16 to trendDay30
+    @ApiModelProperty(notes = "不展示--付费趋势:16天")
+    private String trendDay16;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:17天")
+    private String trendDay17;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:18天")
+    private String trendDay18;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:19天")
+    private String trendDay19;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:20天")
+    private String trendDay20;
+
+    // Continue the pattern for trendDay21 to trendDay30
+    @ApiModelProperty(notes = "不展示--付费趋势:21天")
+    private String trendDay21;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:22天")
+    private String trendDay22;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:23天")
+    private String trendDay23;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:24天")
+    private String trendDay24;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:25天")
+    private String trendDay25;
+
+    // Continue the pattern for trendDay26 to trendDay30
+    @ApiModelProperty(notes = "不展示--付费趋势:26天")
+    private String trendDay26;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:27天")
+    private String trendDay27;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:28天")
+    private String trendDay28;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:29天")
+    private String trendDay29;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:1个月")
+    private String trendMonth1;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:2个月")
+    private String trendMonth2;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:3个月")
+    private String trendMonth3;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:6个月")
+    private String trendMonth6;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:1年")
+    private String trendYear1;
+
+    @ApiModelProperty(notes = "不展示--付费趋势:总")
+    private String trendTotal;
+
+    @ApiModelProperty(notes = "付费趋势:1天")
+    private RechargeTrendVO rechargeTrendDay1;
+
+    @ApiModelProperty(notes = "付费趋势:2天")
+    private RechargeTrendVO rechargeTrendDay2;
+
+    @ApiModelProperty(notes = "付费趋势:3天")
+    private RechargeTrendVO rechargeTrendDay3;
+
+    @ApiModelProperty(notes = "付费趋势:4天")
+    private RechargeTrendVO rechargeTrendDay4;
+
+    @ApiModelProperty(notes = "付费趋势:5天")
+    private RechargeTrendVO rechargeTrendDay5;
+
+    @ApiModelProperty(notes = "付费趋势:6天")
+    private RechargeTrendVO rechargeTrendDay6;
+
+    @ApiModelProperty(notes = "付费趋势:7天")
+    private RechargeTrendVO rechargeTrendDay7;
+
+    @ApiModelProperty(notes = "付费趋势:8天")
+    private RechargeTrendVO rechargeTrendDay8;
+
+    @ApiModelProperty(notes = "付费趋势:9天")
+    private RechargeTrendVO rechargeTrendDay9;
+
+    @ApiModelProperty(notes = "付费趋势:10天")
+    private RechargeTrendVO rechargeTrendDay10;
+
+    @ApiModelProperty(notes = "付费趋势:11天")
+    private RechargeTrendVO rechargeTrendDay11;
+
+    @ApiModelProperty(notes = "付费趋势:12天")
+    private RechargeTrendVO rechargeTrendDay12;
+
+    @ApiModelProperty(notes = "付费趋势:13天")
+    private RechargeTrendVO rechargeTrendDay13;
+
+    @ApiModelProperty(notes = "付费趋势:14天")
+    private RechargeTrendVO rechargeTrendDay14;
+
+    @ApiModelProperty(notes = "付费趋势:15天")
+    private RechargeTrendVO rechargeTrendDay15;
+
+    @ApiModelProperty(notes = "付费趋势:16天")
+    private RechargeTrendVO rechargeTrendDay16;
+
+    @ApiModelProperty(notes = "付费趋势:17天")
+    private RechargeTrendVO rechargeTrendDay17;
+
+    @ApiModelProperty(notes = "付费趋势:18天")
+    private RechargeTrendVO rechargeTrendDay18;
+
+    @ApiModelProperty(notes = "付费趋势:19天")
+    private RechargeTrendVO rechargeTrendDay19;
+
+    @ApiModelProperty(notes = "付费趋势:20天")
+    private RechargeTrendVO rechargeTrendDay20;
+
+    @ApiModelProperty(notes = "付费趋势:21天")
+    private RechargeTrendVO rechargeTrendDay21;
+
+    @ApiModelProperty(notes = "付费趋势:22天")
+    private RechargeTrendVO rechargeTrendDay22;
+
+    @ApiModelProperty(notes = "付费趋势:23天")
+    private RechargeTrendVO rechargeTrendDay23;
+
+    @ApiModelProperty(notes = "付费趋势:24天")
+    private RechargeTrendVO rechargeTrendDay24;
+
+    @ApiModelProperty(notes = "付费趋势:25天")
+    private RechargeTrendVO rechargeTrendDay25;
+
+    @ApiModelProperty(notes = "付费趋势:26天")
+    private RechargeTrendVO rechargeTrendDay26;
+
+    @ApiModelProperty(notes = "付费趋势:27天")
+    private RechargeTrendVO rechargeTrendDay27;
+
+    @ApiModelProperty(notes = "付费趋势:28天")
+    private RechargeTrendVO rechargeTrendDay28;
+
+    @ApiModelProperty(notes = "付费趋势:29天")
+    private RechargeTrendVO rechargeTrendDay29;
+
+    @ApiModelProperty(notes = "付费趋势:1个月")
+    private RechargeTrendVO rechargeTrendMonth1;
+
+    @ApiModelProperty(notes = "付费趋势:2个月")
+    private RechargeTrendVO rechargeTrendMonth2;
+
+    @ApiModelProperty(notes = "付费趋势:3个月")
+    private RechargeTrendVO rechargeTrendMonth3;
+
+    @ApiModelProperty(notes = "付费趋势:6个月")
+    private RechargeTrendVO rechargeTrendMonth6;
+
+    @ApiModelProperty(notes = "付费趋势:1年")
+    private RechargeTrendVO rechargeTrendYear1;
+
+    @ApiModelProperty(notes = "付费趋势:总")
+    private RechargeTrendVO rechargeTrendTotal;
+
     @ApiModelProperty(notes = "首日付费率=首日新用户充值人数/注册人数")
     private BigDecimal firstRechargeRate;
 

+ 6 - 0
game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/vo/PlayerTemplateVO.java

@@ -48,5 +48,11 @@ public class PlayerTemplateVO {
     @ApiModelProperty("用户充值占比")
     private BigDecimal proportion;
 
+    @ApiModelProperty("角色名称")
+    private String roleName;
+
+    @ApiModelProperty("游戏服")
+    private String serverName;
+
 
 }

+ 788 - 1
game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/vo/PromotionDayTotalVO.java

@@ -1,9 +1,796 @@
 package com.zanxiang.game.data.serve.pojo.vo;
 
+import io.swagger.annotations.ApiModelProperty;
+import lombok.AllArgsConstructor;
+import lombok.Builder;
+import lombok.Data;
+import lombok.NoArgsConstructor;
+
+import java.math.BigDecimal;
+
 /**
  * @author tianhua
  * @time 2023/7/27
- * @Description 广告监控数据总计
+ * @Description 广告监控数据总计前端显示对象
  **/
+@Data
+@NoArgsConstructor
+@AllArgsConstructor
+@Builder
 public class PromotionDayTotalVO {
+
+    /**
+     * 今日消耗
+     */
+    @ApiModelProperty(value = "今日消耗")
+    private BigDecimal todayCost;
+
+    /**
+     * 广告总消耗
+     */
+    @ApiModelProperty(value = "广告总消耗")
+    private BigDecimal promotionTotalCost;
+
+    /**
+     * 曝光量
+     */
+    @ApiModelProperty(value = "曝光量")
+    private Long showCount;
+
+    /**
+     * 千次曝光成本
+     */
+    @ApiModelProperty(value = "千次曝光成本")
+    private BigDecimal thousandDisplayPrice;
+
+    /**
+     * 点击量
+     */
+    @ApiModelProperty(value = "点击量")
+    private Long clickCount;
+
+    /**
+     * 点击均价
+     */
+    @ApiModelProperty(value = "点击均价")
+    private BigDecimal avgClickCost;
+
+    /**
+     * 点击率
+     */
+    @ApiModelProperty(value = "点击率")
+    private BigDecimal ctr;
+
+    /**
+     * 转化目标量
+     */
+    @ApiModelProperty(value = "转化目标量")
+    private Long convertCount;
+
+    /**
+     * 转化目标成本
+     */
+    @ApiModelProperty(value = "转化目标成本")
+    private BigDecimal convertCost;
+
+    /**
+     * 目标转化率
+     */
+    @ApiModelProperty(value = "目标转化率")
+    private BigDecimal convertRate;
+
+    /**
+     * 新增用户数
+     */
+    @ApiModelProperty(value = "新增用户数")
+    private Long regNum;
+
+    /**
+     * 广告总注册人数
+     */
+    @ApiModelProperty(value = "广告总注册人数")
+    private Long regTotalNum;
+
+    /**
+     * 总创角人数
+     */
+    @ApiModelProperty(value = "总创角人数")
+    private Long roleTotalNum;
+
+    /**
+     * 首日创角人数
+     */
+    @ApiModelProperty(value = "首日创角人数")
+    private Long firstRoleNum;
+
+    /**
+     * 新用户累计创角人数
+     */
+    @ApiModelProperty(value = "新用户累计创角人数")
+    private Long newUserTotalRoleNum;
+
+    /**
+     * 注册成本
+     */
+    @ApiModelProperty(value = "注册成本")
+    private BigDecimal regCost;
+
+    /**
+     * 总注册成本
+     */
+    @ApiModelProperty(value = "总注册成本")
+    private BigDecimal regTotalCost;
+
+    /**
+     * 首日创角成本
+     */
+    @ApiModelProperty(value = "首日创角成本")
+    private BigDecimal firstRoleCost;
+
+    /**
+     * 新用户创角成本
+     */
+    @ApiModelProperty(value = "新用户创角成本")
+    private BigDecimal newUserTotalRoleCost;
+
+    /**
+     * 总创角成本
+     */
+    @ApiModelProperty(value = "总创角成本")
+    private BigDecimal roleTotalCost;
+
+    /**
+     * 首日创角率
+     */
+    @ApiModelProperty(value = "首日创角率")
+    private BigDecimal firstRoleRate;
+
+    /**
+     * 新用户创角率
+     */
+    @ApiModelProperty(value = "新用户创角率")
+    private BigDecimal newUserTotalRoleRate;
+
+    /**
+     * 总创角率
+     */
+    @ApiModelProperty(value = "总创角率")
+    private BigDecimal roleTotalRate;
+
+    /**
+     * 新增付费次数
+     */
+    @ApiModelProperty(value = "新增付费次数")
+    private Long firstNewUserAmountCount;
+
+    /**
+     * 新增付费人数
+     */
+    @ApiModelProperty(value = "新增付费人数")
+    private Long firstNewUserAmountNum;
+
+    /**
+     * 新增付费金额
+     */
+    @ApiModelProperty(value = "新增付费金额")
+    private BigDecimal firstNewUserAmount;
+
+    /**
+     * 至今付费次数
+     */
+    @ApiModelProperty(value = "至今付费次数")
+    private Long newUserTotalAmountCount;
+
+    /**
+     * 至今付费人数
+     */
+    @ApiModelProperty(value = "至今付费人数")
+    private Long newUserTotalAmountNum;
+
+    /**
+     * 至今付费金额
+     */
+    @ApiModelProperty(value = "至今付费金额")
+    private BigDecimal newUserTotalAmount;
+
+    /**
+     * 总充值次数
+     */
+    @ApiModelProperty(value = "总充值次数")
+    private Long totalAmountCount;
+
+    /**
+     * 总充值人数
+     */
+    @ApiModelProperty(value = "总充值人数")
+    private Long totalAmountNum;
+
+    /**
+     * 总充值金额
+     */
+    @ApiModelProperty(value = "总充值金额")
+    private BigDecimal totalAmount;
+
+    /**
+     * 首日ROI
+     */
+    @ApiModelProperty(value = "首日ROI")
+    private BigDecimal firstRoi;
+
+    /**
+     * 新用户24小时充值金额
+     */
+    @ApiModelProperty(value = "新用户24小时充值金额")
+    private BigDecimal twentyFourHoursAmount;
+
+    /**
+     * 新用户24小时ROI
+     */
+    @ApiModelProperty(value = "新用户24小时ROI")
+    private BigDecimal twentyFourHoursRoi;
+
+    /**
+     * 总ROI
+     */
+    @ApiModelProperty(value = "总ROI")
+    private BigDecimal totalRoi;
+
+    /**
+     * 广告总ROI
+     */
+    @ApiModelProperty(value = "广告总ROI")
+    private BigDecimal promotionTotalRoi;
+
+    /**
+     * 新增付费成本
+     */
+    @ApiModelProperty(value = "新增付费成本")
+    private BigDecimal firstNewUserRechargeCost;
+
+    /**
+     * 至今付费成本
+     */
+    @ApiModelProperty(value = "至今付费成本")
+    private BigDecimal newUserTotalRechargeCost;
+
+    /**
+     * 广告总付费成本
+     */
+    @ApiModelProperty(value = "广告总付费成本")
+    private BigDecimal totalRechargeCost;
+
+    /**
+     * 新增付费ARPPU
+     */
+    @ApiModelProperty(value = "新增付费ARPPU")
+    private BigDecimal firstNewUserArppu;
+
+    /**
+     * 至今付费ARPPU
+     */
+    @ApiModelProperty(value = "至今付费ARPPU")
+    private BigDecimal newUserTotalAmountArppu;
+
+    /**
+     * 新增付费100+用户数
+     */
+    @ApiModelProperty(value = "新增付费100+用户数")
+    private Long firstNewUserHundredUserNum;
+
+    /**
+     * 新增付费200+用户数
+     */
+    @ApiModelProperty(value = "新增付费200+用户数")
+    private Long firstNewUserTwoHundredUserNum;
+
+    /**
+     * 至今付费100+用户数
+     */
+    @ApiModelProperty(value = "至今付费100+用户数")
+    private Long newUserTotalHundredUserNum;
+
+    /**
+     * 首充50~100元用户数
+     */
+    @ApiModelProperty(value = "首充50~100元用户数")
+    private Long firstRechargeFiftyHundredNum;
+
+    /**
+     * 新增付费100+用户付费成本
+     */
+    @ApiModelProperty(value = "新增付费100+用户付费成本")
+    private BigDecimal firstNewUserHundredUserCost;
+
+    /**
+     * 新增付费200+用户付费成本
+     */
+    @ApiModelProperty(value = "新增付费200+用户付费成本")
+    private BigDecimal firstNewUserTwoHundredUserCost;
+
+    /**
+     * 至今付费100+用户付费成本
+     */
+    @ApiModelProperty(value = "至今付费100+用户付费成本")
+    private BigDecimal newUserTotalHundredUserCost;
+
+    /**
+     * 首充50~100元占比
+     */
+    @ApiModelProperty(value = "首充50~100元占比")
+    private BigDecimal firstRechargeFiftyHundredRate;
+
+    /**
+     * 首日IOS付费次数
+     */
+    @ApiModelProperty(value = "首日IOS付费次数")
+    private Long firstIosAmountCount;
+
+    /**
+     * 首日IOS付费人数
+     */
+    @ApiModelProperty(value = "首日IOS付费人数")
+    private Long firstIosAmountNum;
+
+    /**
+     * 首日IOS付费金额
+     */
+    @ApiModelProperty(value = "首日IOS付费金额")
+    private BigDecimal firstIosAmount;
+
+    /**
+     * 首日Android付费次数
+     */
+    @ApiModelProperty(value = "首日Android付费次数")
+    private Long firstAndroidAmountCount;
+
+    /**
+     * 首日Android付费人数
+     */
+    @ApiModelProperty(value = "首日Android付费人数")
+    private Long firstAndroidAmountNum;
+
+    /**
+     * 首日Android付费金额
+     */
+    @ApiModelProperty(value = "首日Android付费金额")
+    private BigDecimal firstAndroidAmount;
+
+    /**
+     * 首日IOS付费人数占比
+     */
+    @ApiModelProperty(value = "首日IOS付费人数占比")
+    private BigDecimal firstIosAmountNumRate;
+
+    /**
+     * 首日IOS付费金额占比
+     */
+    @ApiModelProperty(value = "首日IOS付费金额占比")
+    private BigDecimal firstIosAmountRate;
+
+    /**
+     * 首日IOS付费ROI
+     */
+    @ApiModelProperty(value = "首日IOS付费ROI")
+    private BigDecimal firstIosAmountRoi;
+
+    /**
+     * 首日Android付费人数占比
+     */
+    @ApiModelProperty(value = "首日Android付费人数占比")
+    private BigDecimal firstAndroidAmountNumRate;
+
+    /**
+     * 首日Android付费金额占比
+     */
+    @ApiModelProperty(value = "首日Android付费金额占比")
+    private BigDecimal firstAndroidAmountRate;
+
+    /**
+     * 首日Android付费ROI
+     */
+    @ApiModelProperty(value = "首日Android付费ROI")
+    private BigDecimal firstAndroidAmountRoi;
+
+    /**
+     * 首日付费率
+     */
+    @ApiModelProperty(value = "首日付费率")
+    private BigDecimal firstAmountRate;
+
+    /**
+     * 新增客单价
+     */
+    @ApiModelProperty(value = "新增客单价")
+    private BigDecimal firstNewUserAvgPrice;
+
+    /**
+     * 至今客单价
+     */
+    @ApiModelProperty(value = "至今客单价")
+    private BigDecimal newUserTotalAvgPrice;
+
+    /**
+     * 计划ID,消耗时间的第1天新用户充值(不显示)
+     */
+    @ApiModelProperty(value = "计划ID,消耗时间的第1天新用户充值(不显示)")
+    private BigDecimal d1;
+
+    /**
+     * 计划ID,消耗时间的第2天新用户充值(不显示)
+     */
+    @ApiModelProperty(value = "计划ID,消耗时间的第2天新用户充值(不显示)")
+    private BigDecimal d2;
+
+    /**
+     * 计划ID,消耗时间的第3天新用户充值(不显示)
+     */
+    @ApiModelProperty(value = "计划ID,消耗时间的第3天新用户充值(不显示)")
+    private BigDecimal d3;
+
+    /**
+     * 计划ID,消耗时间的第4天新用户充值(不显示)
+     */
+    @ApiModelProperty(value = "计划ID,消耗时间的第4天新用户充值(不显示)")
+    private BigDecimal d4;
+
+    /**
+     * 计划ID,消耗时间的第5天新用户充值(不显示)
+     */
+    @ApiModelProperty(value = "计划ID,消耗时间的第5天新用户充值(不显示)")
+    private BigDecimal d5;
+
+    /**
+     * 计划ID,消耗时间的第6天新用户充值(不显示)
+     */
+    @ApiModelProperty(value = "计划ID,消耗时间的第6天新用户充值(不显示)")
+    private BigDecimal d6;
+
+    /**
+     * 计划ID,消耗时间的第7天新用户充值(不显示)
+     */
+    @ApiModelProperty(value = "计划ID,消耗时间的第7天新用户充值(不显示)")
+    private BigDecimal d7;
+
+    /**
+     * 计划ID,消耗时间的第8天新用户充值(不显示)
+     */
+    @ApiModelProperty(value = "计划ID,消耗时间的第8天新用户充值(不显示)")
+    private BigDecimal d8;
+
+    /**
+     * 计划ID,消耗时间的第9天新用户充值(不显示)
+     */
+    @ApiModelProperty(value = "计划ID,消耗时间的第9天新用户充值(不显示)")
+    private BigDecimal d9;
+
+    /**
+     * 计划ID,消耗时间的第10天新用户充值(不显示)
+     */
+    @ApiModelProperty(value = "计划ID,消耗时间的第10天新用户充值(不显示)")
+    private BigDecimal d10;
+
+    /**
+     * 计划ID,消耗时间的第11天新用户充值(不显示)
+     */
+    @ApiModelProperty(value = "计划ID,消耗时间的第11天新用户充值(不显示)")
+    private BigDecimal d11;
+
+    /**
+     * 计划ID,消耗时间的第12天新用户充值(不显示)
+     */
+    @ApiModelProperty(value = "计划ID,消耗时间的第12天新用户充值(不显示)")
+    private BigDecimal d12;
+
+    /**
+     * 计划ID,消耗时间的第13天新用户充值(不显示)
+     */
+    @ApiModelProperty(value = "计划ID,消耗时间的第13天新用户充值(不显示)")
+    private BigDecimal d13;
+
+    /**
+     * 计划ID,消耗时间的第14天新用户充值(不显示)
+     */
+    @ApiModelProperty(value = "计划ID,消耗时间的第14天新用户充值(不显示)")
+    private BigDecimal d14;
+
+    /**
+     * 计划ID,消耗时间的第15天新用户充值(不显示)
+     */
+    @ApiModelProperty(value = "计划ID,消耗时间的第15天新用户充值(不显示)")
+    private BigDecimal d15;
+
+    /**
+     * 计划ID,消耗时间的第16天新用户充值(不显示)
+     */
+    @ApiModelProperty(value = "计划ID,消耗时间的第16天新用户充值(不显示)")
+    private BigDecimal d16;
+
+    /**
+     * 计划ID,消耗时间的第17天新用户充值(不显示)
+     */
+    @ApiModelProperty(value = "计划ID,消耗时间的第17天新用户充值(不显示)")
+    private BigDecimal d17;
+
+    /**
+     * 计划ID,消耗时间的第18天新用户充值(不显示)
+     */
+    @ApiModelProperty(value = "计划ID,消耗时间的第18天新用户充值(不显示)")
+    private BigDecimal d18;
+
+    /**
+     * 计划ID,消耗时间的第19天新用户充值(不显示)
+     */
+    @ApiModelProperty(value = "计划ID,消耗时间的第19天新用户充值(不显示)")
+    private BigDecimal d19;
+
+    /**
+     * 计划ID,消耗时间的第20天新用户充值(不显示)
+     */
+    @ApiModelProperty(value = "计划ID,消耗时间的第20天新用户充值(不显示)")
+    private BigDecimal d20;
+
+    /**
+     * 计划ID,消耗时间的第21天新用户充值(不显示)
+     */
+    @ApiModelProperty(value = "计划ID,消耗时间的第21天新用户充值(不显示)")
+    private BigDecimal d21;
+
+    /**
+     * 计划ID,消耗时间的第22天新用户充值(不显示)
+     */
+    @ApiModelProperty(value = "计划ID,消耗时间的第22天新用户充值(不显示)")
+    private BigDecimal d22;
+
+    /**
+     * 计划ID,消耗时间的第23天新用户充值(不显示)
+     */
+    @ApiModelProperty(value = "计划ID,消耗时间的第23天新用户充值(不显示)")
+    private BigDecimal d23;
+
+    /**
+     * 计划ID,消耗时间的第24天新用户充值(不显示)
+     */
+    @ApiModelProperty(value = "计划ID,消耗时间的第24天新用户充值(不显示)")
+    private BigDecimal d24;
+
+    /**
+     * 计划ID,消耗时间的第25天新用户充值(不显示)
+     */
+    @ApiModelProperty(value = "计划ID,消耗时间的第25天新用户充值(不显示)")
+    private BigDecimal d25;
+
+    /**
+     * 计划ID,消耗时间的第26天新用户充值(不显示)
+     */
+    @ApiModelProperty(value = "计划ID,消耗时间的第26天新用户充值(不显示)")
+    private BigDecimal d26;
+
+    /**
+     * 计划ID,消耗时间的第27天新用户充值(不显示)
+     */
+    @ApiModelProperty(value = "计划ID,消耗时间的第27天新用户充值(不显示)")
+    private BigDecimal d27;
+
+    /**
+     * 计划ID,消耗时间的第28天新用户充值(不显示)
+     */
+    @ApiModelProperty(value = "计划ID,消耗时间的第28天新用户充值(不显示)")
+    private BigDecimal d28;
+
+    /**
+     * 计划ID,消耗时间的第29天新用户充值(不显示)
+     */
+    @ApiModelProperty(value = "计划ID,消耗时间的第29天新用户充值(不显示)")
+    private BigDecimal d29;
+
+    /**
+     * 计划ID,消耗时间的第30天新用户充值(不显示)
+     */
+    @ApiModelProperty(value = "计划ID,消耗时间的第30天新用户充值(不显示)")
+    private BigDecimal d30;
+
+    /**
+     * 付费趋势第1天总:金额/人数/增/回/倍(不显示)
+     */
+    @ApiModelProperty(value = "付费趋势第1天总:金额/人数/增/回/倍(不显示)")
+    private String da1;
+
+    /**
+     * 付费趋势第2天总:金额/人数/增/回/倍(不显示)
+     */
+    @ApiModelProperty(value = "付费趋势第2天总:金额/人数/增/回/倍(不显示)")
+    private String da2;
+
+    /**
+     * 付费趋势第3天总:金额/人数/增/回/倍(不显示)
+     */
+    @ApiModelProperty(value = "付费趋势第3天总:金额/人数/增/回/倍(不显示)")
+    private String da3;
+
+    /**
+     * 付费趋势第4天总:金额/人数/增/回/倍(不显示)
+     */
+    @ApiModelProperty(value = "付费趋势第4天总:金额/人数/增/回/倍(不显示)")
+    private String da4;
+
+    /**
+     * 付费趋势第5天总:金额/人数/增/回/倍(不显示)
+     */
+    @ApiModelProperty(value = "付费趋势第5天总:金额/人数/增/回/倍(不显示)")
+    private String da5;
+
+    /**
+     * 付费趋势第6天总:金额/人数/增/回/倍(不显示)
+     */
+    @ApiModelProperty(value = "付费趋势第6天总:金额/人数/增/回/倍(不显示)")
+    private String da6;
+
+    /**
+     * 付费趋势第7天总:金额/人数/增/回/倍(不显示)
+     */
+    @ApiModelProperty(value = "付费趋势第7天总:金额/人数/增/回/倍(不显示)")
+    private String da7;
+
+    /**
+     * 付费趋势第8天总:金额/人数/增/回/倍(不显示)
+     */
+    @ApiModelProperty(value = "付费趋势第8天总:金额/人数/增/回/倍(不显示)")
+    private String da8;
+
+    /**
+     * 付费趋势第9天总:金额/人数/增/回/倍(不显示)
+     */
+    @ApiModelProperty(value = "付费趋势第9天总:金额/人数/增/回/倍(不显示)")
+    private String da9;
+
+    /**
+     * 付费趋势第10天总:金额/人数/增/回/倍(不显示)
+     */
+    @ApiModelProperty(value = "付费趋势第10天总:金额/人数/增/回/倍(不显示)")
+    private String da10;
+
+    /**
+     * 付费趋势第11天总:金额/人数/增/回/倍(不显示)
+     */
+    @ApiModelProperty(value = "付费趋势第11天总:金额/人数/增/回/倍(不显示)")
+    private String da11;
+
+    /**
+     * 付费趋势第12天总:金额/人数/增/回/倍(不显示)
+     */
+    @ApiModelProperty(value = "付费趋势第12天总:金额/人数/增/回/倍(不显示)")
+    private String da12;
+
+    /**
+     * 付费趋势第13天总:金额/人数/增/回/倍(不显示)
+     */
+    @ApiModelProperty(value = "付费趋势第13天总:金额/人数/增/回/倍(不显示)")
+    private String da13;
+
+    /**
+     * 付费趋势第14天总:金额/人数/增/回/倍(不显示)
+     */
+    @ApiModelProperty(value = "付费趋势第14天总:金额/人数/增/回/倍(不显示)")
+    private String da14;
+
+    /**
+     * 付费趋势第15天总:金额/人数/增/回/倍(不显示)
+     */
+    @ApiModelProperty(value = "付费趋势第15天总:金额/人数/增/回/倍(不显示)")
+    private String da15;
+
+    /**
+     * 付费趋势第16天总:金额/人数/增/回/倍(不显示)
+     */
+    @ApiModelProperty(value = "付费趋势第16天总:金额/人数/增/回/倍(不显示)")
+    private String da16;
+
+    /**
+     * 付费趋势第17天总:金额/人数/增/回/倍(不显示)
+     */
+    @ApiModelProperty(value = "付费趋势第17天总:金额/人数/增/回/倍(不显示)")
+    private String da17;
+
+    /**
+     * 付费趋势第18天总:金额/人数/增/回/倍(不显示)
+     */
+    @ApiModelProperty(value = "付费趋势第18天总:金额/人数/增/回/倍(不显示)")
+    private String da18;
+
+    /**
+     * 付费趋势第19天总:金额/人数/增/回/倍(不显示)
+     */
+    @ApiModelProperty(value = "付费趋势第19天总:金额/人数/增/回/倍(不显示)")
+    private String da19;
+
+    /**
+     * 付费趋势第20天总:金额/人数/增/回/倍(不显示)
+     */
+    @ApiModelProperty(value = "付费趋势第20天总:金额/人数/增/回/倍(不显示)")
+    private String da20;
+
+    /**
+     * 付费趋势第21天总:金额/人数/增/回/倍(不显示)
+     */
+    @ApiModelProperty(value = "付费趋势第21天总:金额/人数/增/回/倍(不显示)")
+    private String da21;
+
+    /**
+     * 付费趋势第22天总:金额/人数/增/回/倍(不显示)
+     */
+    @ApiModelProperty(value = "付费趋势第22天总:金额/人数/增/回/倍(不显示)")
+    private String da22;
+
+    /**
+     * 付费趋势第23天总:金额/人数/增/回/倍(不显示)
+     */
+    @ApiModelProperty(value = "付费趋势第23天总:金额/人数/增/回/倍(不显示)")
+    private String da23;
+
+    /**
+     * 付费趋势第24天总:金额/人数/增/回/倍(不显示)
+     */
+    @ApiModelProperty(value = "付费趋势第24天总:金额/人数/增/回/倍(不显示)")
+    private String da24;
+
+    /**
+     * 付费趋势第25天总:金额/人数/增/回/倍(不显示)
+     */
+    @ApiModelProperty(value = "付费趋势第25天总:金额/人数/增/回/倍(不显示)")
+    private String da25;
+
+    /**
+     * 付费趋势第26天总:金额/人数/增/回/倍(不显示)
+     */
+    @ApiModelProperty(value = "付费趋势第26天总:金额/人数/增/回/倍(不显示)")
+    private String da26;
+
+    /**
+     * 付费趋势第27天总:金额/人数/增/回/倍(不显示)
+     */
+    @ApiModelProperty(value = "付费趋势第27天总:金额/人数/增/回/倍(不显示)")
+    private String da27;
+
+    /**
+     * 付费趋势第28天总:金额/人数/增/回/倍(不显示)
+     */
+    @ApiModelProperty(value = "付费趋势第28天总:金额/人数/增/回/倍(不显示)")
+    private String da28;
+
+    /**
+     * 付费趋势第29天总:金额/人数/增/回/倍(不显示)
+     */
+    @ApiModelProperty(value = "付费趋势第29天总:金额/人数/增/回/倍(不显示)")
+    private String da29;
+
+    /**
+     * 付费趋势第30天总:金额/人数/增/回/倍(不显示)
+     */
+    @ApiModelProperty(value = "付费趋势第30天总:金额/人数/增/回/倍(不显示)")
+    private String da30;
+
+    /**
+     * 次日数据
+     */
+    @ApiModelProperty(value = "次日:ROI/付费/倍数")
+    private PromotionRechargeTrendVO d2Trend;
+
+    /**
+     * 3日数据
+     */
+    @ApiModelProperty(value = "3日:ROI/付费/倍数")
+    private PromotionRechargeTrendVO d3Trend;
+
+    /**
+     * 7日数据
+     */
+    @ApiModelProperty(value = "7日:ROI/付费/倍数")
+    private PromotionRechargeTrendVO d7Trend;
+
+    /**
+     * 15日数据
+     */
+    @ApiModelProperty(value = "15日:ROI/付费/倍数")
+    private PromotionRechargeTrendVO d15Trend;
+
 }

+ 2 - 3
game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/vo/PromotionDayVO.java

@@ -7,7 +7,6 @@ import lombok.Data;
 import lombok.NoArgsConstructor;
 
 import java.math.BigDecimal;
-import java.math.BigInteger;
 
 /**
  * @author tianhua
@@ -24,7 +23,7 @@ public class PromotionDayVO {
      * 广告ID
      */
     @ApiModelProperty(value = "广告ID")
-    private BigInteger promotionId;
+    private String promotionId;
 
     /**
      * 广告名称
@@ -36,7 +35,7 @@ public class PromotionDayVO {
      * 计划ID
      */
     @ApiModelProperty(value = "计划ID")
-    private Long projectId;
+    private String projectId;
 
     /**
      * 计划名称

+ 3 - 0
game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/pojo/vo/RechargeTrendVO.java

@@ -27,4 +27,7 @@ public class RechargeTrendVO {
 
     @ApiModelProperty(notes = "倍")
     private BigDecimal multiples;
+
+    @ApiModelProperty(notes = "总充值金额")
+    private BigDecimal rechargeMoneyTotal;
 }

+ 440 - 154
game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/service/impl/AccountAgentDayServiceImpl.java

@@ -104,100 +104,62 @@ public class AccountAgentDayServiceImpl implements IAccountAgentDayService {
         dao.execute(sql);
         pager.setRecordCount(dao.count(AdsAccountAgentDay.class, cri));
         List<GamePromoteDayVO> collect = sql.getList(GamePromoteDayVO.class).stream().map(item -> {
-            String[] trendDay1 = item.getTrendDay1().split("/");
-            item.setRechargeTrendDay1(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(trendDay1[0]))
-                    .rechargeUserCount(Long.valueOf(trendDay1[1]))
-                    .increase(new BigDecimal(trendDay1[2]))
-                    .back(new BigDecimal(trendDay1[3]))
-                    .multiples(new BigDecimal(trendDay1[4]))
-                    .build());
-
-            String[] trendDay3 = item.getTrendDay3().split("/");
-            item.setRechargeTrendDay3(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(trendDay3[0]))
-                    .rechargeUserCount(Long.valueOf(trendDay3[1]))
-                    .increase(new BigDecimal(trendDay3[2]))
-                    .back(new BigDecimal(trendDay3[3]))
-                    .multiples(new BigDecimal(trendDay3[4]))
-                    .build());
-
-            String[] trendDay5 = item.getTrendDay5().split("/");
-            item.setRechargeTrendDay5(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(trendDay5[0]))
-                    .rechargeUserCount(Long.valueOf(trendDay5[1]))
-                    .increase(new BigDecimal(trendDay5[2]))
-                    .back(new BigDecimal(trendDay5[3]))
-                    .multiples(new BigDecimal(trendDay5[4]))
-                    .build());
-
-            String[] trendDay7 = item.getTrendDay7().split("/");
-            item.setRechargeTrendDay7(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(trendDay7[0]))
-                    .rechargeUserCount(Long.valueOf(trendDay7[1]))
-                    .increase(new BigDecimal(trendDay7[2]))
-                    .back(new BigDecimal(trendDay7[3]))
-                    .multiples(new BigDecimal(trendDay7[4]))
-                    .build());
-
-            String[] trendDay15 = item.getTrendDay15().split("/");
-            item.setRechargeTrendDay15(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(trendDay15[0]))
-                    .rechargeUserCount(Long.valueOf(trendDay15[1]))
-                    .increase(new BigDecimal(trendDay15[2]))
-                    .back(new BigDecimal(trendDay15[3]))
-                    .multiples(new BigDecimal(trendDay15[4]))
-                    .build());
-
-            String[] trendMonth1 = item.getTrendMonth1().split("/");
-            item.setRechargeTrendMonth1(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(trendMonth1[0]))
-                    .rechargeUserCount(Long.valueOf(trendMonth1[1]))
-                    .increase(new BigDecimal(trendMonth1[2]))
-                    .back(new BigDecimal(trendMonth1[3]))
-                    .multiples(new BigDecimal(trendMonth1[4]))
-                    .build());
-
-            String[] trendMonth2 = item.getTrendMonth2().split("/");
-            item.setRechargeTrendMonth2(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(trendMonth2[0]))
-                    .rechargeUserCount(Long.valueOf(trendMonth2[1]))
-                    .increase(new BigDecimal(trendMonth2[2]))
-                    .back(new BigDecimal(trendMonth2[3]))
-                    .multiples(new BigDecimal(trendMonth2[4]))
-                    .build());
-
-            String[] trendMonth3 = item.getTrendMonth3().split("/");
-            item.setRechargeTrendMonth3(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(trendMonth3[0]))
-                    .rechargeUserCount(Long.valueOf(trendMonth3[1]))
-                    .increase(new BigDecimal(trendMonth3[2]))
-                    .back(new BigDecimal(trendMonth3[3]))
-                    .multiples(new BigDecimal(trendMonth3[4]))
-                    .build());
-
-            String[] trendMonth6 = item.getTrendMonth6().split("/");
-            item.setRechargeTrendMonth6(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(trendMonth6[0]))
-                    .rechargeUserCount(Long.valueOf(trendMonth6[1]))
-                    .increase(new BigDecimal(trendMonth6[2]))
-                    .back(new BigDecimal(trendMonth6[3]))
-                    .multiples(new BigDecimal(trendMonth6[4]))
-                    .build());
-
-            String[] trendTotal = item.getTrendTotal().split("/");
-            item.setRechargeTrendTotal(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(trendTotal[0]))
-                    .rechargeUserCount(Long.valueOf(trendTotal[1]))
-                    .increase(new BigDecimal(trendTotal[2]))
-                    .back(new BigDecimal(trendTotal[3]))
-                    .multiples(new BigDecimal(trendTotal[4]))
-                    .build());
+            setDayRechargeTrend(item);
             return item;
         }).collect(Collectors.toList());
         return new Page<>(collect, pager);
     }
 
+    private void setDayRechargeTrend(GamePromoteDayVO item) {
+        item.setRechargeTrendDay1(getRechargeTrendVO(item.getTrendDay1()));
+        item.setRechargeTrendDay2(getRechargeTrendVO(item.getTrendDay2()));
+        item.setRechargeTrendDay3(getRechargeTrendVO(item.getTrendDay3()));
+        item.setRechargeTrendDay4(getRechargeTrendVO(item.getTrendDay4()));
+        item.setRechargeTrendDay5(getRechargeTrendVO(item.getTrendDay5()));
+        item.setRechargeTrendDay6(getRechargeTrendVO(item.getTrendDay6()));
+        item.setRechargeTrendDay7(getRechargeTrendVO(item.getTrendDay7()));
+        item.setRechargeTrendDay8(getRechargeTrendVO(item.getTrendDay8()));
+        item.setRechargeTrendDay9(getRechargeTrendVO(item.getTrendDay9()));
+        item.setRechargeTrendDay10(getRechargeTrendVO(item.getTrendDay10()));
+        item.setRechargeTrendDay11(getRechargeTrendVO(item.getTrendDay11()));
+        item.setRechargeTrendDay12(getRechargeTrendVO(item.getTrendDay12()));
+        item.setRechargeTrendDay13(getRechargeTrendVO(item.getTrendDay13()));
+        item.setRechargeTrendDay14(getRechargeTrendVO(item.getTrendDay14()));
+        item.setRechargeTrendDay15(getRechargeTrendVO(item.getTrendDay15()));
+        item.setRechargeTrendDay16(getRechargeTrendVO(item.getTrendDay16()));
+        item.setRechargeTrendDay17(getRechargeTrendVO(item.getTrendDay17()));
+        item.setRechargeTrendDay18(getRechargeTrendVO(item.getTrendDay18()));
+        item.setRechargeTrendDay19(getRechargeTrendVO(item.getTrendDay19()));
+        item.setRechargeTrendDay20(getRechargeTrendVO(item.getTrendDay20()));
+        item.setRechargeTrendDay21(getRechargeTrendVO(item.getTrendDay21()));
+        item.setRechargeTrendDay22(getRechargeTrendVO(item.getTrendDay22()));
+        item.setRechargeTrendDay23(getRechargeTrendVO(item.getTrendDay23()));
+        item.setRechargeTrendDay24(getRechargeTrendVO(item.getTrendDay24()));
+        item.setRechargeTrendDay25(getRechargeTrendVO(item.getTrendDay25()));
+        item.setRechargeTrendDay26(getRechargeTrendVO(item.getTrendDay26()));
+        item.setRechargeTrendDay27(getRechargeTrendVO(item.getTrendDay27()));
+        item.setRechargeTrendDay28(getRechargeTrendVO(item.getTrendDay28()));
+        item.setRechargeTrendDay29(getRechargeTrendVO(item.getTrendDay29()));
+
+        item.setRechargeTrendMonth1(getRechargeTrendVO(item.getTrendMonth1()));
+        item.setRechargeTrendMonth2(getRechargeTrendVO(item.getTrendMonth2()));
+        item.setRechargeTrendMonth3(getRechargeTrendVO(item.getTrendMonth3()));
+        item.setRechargeTrendMonth6(getRechargeTrendVO(item.getTrendMonth6()));
+        item.setRechargeTrendYear1(getRechargeTrendVO(item.getTrendYear1()));
+        item.setRechargeTrendTotal(getRechargeTrendVO(item.getTrendTotal()));
+    }
+
+    private RechargeTrendVO getRechargeTrendVO(String trendDay) {
+        String[] trendDayResult = trendDay.split("/");
+        return RechargeTrendVO.builder()
+                .rechargeMoney(new BigDecimal(trendDayResult[0]))
+                .rechargeUserCount(Long.valueOf(trendDayResult[1]))
+                .increase(new BigDecimal(trendDayResult[2]))
+                .back(new BigDecimal(trendDayResult[3]))
+                .multiples(new BigDecimal(trendDayResult[4]))
+                .build();
+    }
+
     @Override
     public GamePromoteDayTotalVO accountAgentDayTotal(GamePromoteDayTotalDTO dto) {
         Long sysUserId = SecurityUtil.isAdmin() ? null : SecurityUtil.getUserId();
@@ -247,7 +209,66 @@ public class AccountAgentDayServiceImpl implements IAccountAgentDayService {
         Entity<GamePromoteDayTotalVO> entity = dao.getEntity(GamePromoteDayTotalVO.class);
         sql.setEntity(entity).setCondition(cri);
         dao.execute(sql);
-        return sql.getObject(GamePromoteDayTotalVO.class);
+        GamePromoteDayTotalVO gamePromoteDayTotalVO = sql.getObject(GamePromoteDayTotalVO.class);
+        setDayTotalRechargeTrend(gamePromoteDayTotalVO);
+        return gamePromoteDayTotalVO;
+    }
+
+    private void setDayTotalRechargeTrend(GamePromoteDayTotalVO item) {
+        BigDecimal trendDay1Money = new BigDecimal(item.getTrendDay1().split("/")[0]);
+        item.setRechargeTrendDay1(getSumRechargeTrendVO(item.getTrendDay1(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay2(getSumRechargeTrendVO(item.getTrendDay2(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay3(getSumRechargeTrendVO(item.getTrendDay3(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay4(getSumRechargeTrendVO(item.getTrendDay4(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay5(getSumRechargeTrendVO(item.getTrendDay5(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay6(getSumRechargeTrendVO(item.getTrendDay6(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay7(getSumRechargeTrendVO(item.getTrendDay7(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay8(getSumRechargeTrendVO(item.getTrendDay8(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay9(getSumRechargeTrendVO(item.getTrendDay9(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay10(getSumRechargeTrendVO(item.getTrendDay10(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay11(getSumRechargeTrendVO(item.getTrendDay11(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay12(getSumRechargeTrendVO(item.getTrendDay12(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay13(getSumRechargeTrendVO(item.getTrendDay13(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay14(getSumRechargeTrendVO(item.getTrendDay14(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay15(getSumRechargeTrendVO(item.getTrendDay15(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay16(getSumRechargeTrendVO(item.getTrendDay16(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay17(getSumRechargeTrendVO(item.getTrendDay17(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay18(getSumRechargeTrendVO(item.getTrendDay18(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay19(getSumRechargeTrendVO(item.getTrendDay19(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay20(getSumRechargeTrendVO(item.getTrendDay20(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay21(getSumRechargeTrendVO(item.getTrendDay21(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay22(getSumRechargeTrendVO(item.getTrendDay22(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay23(getSumRechargeTrendVO(item.getTrendDay23(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay24(getSumRechargeTrendVO(item.getTrendDay24(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay25(getSumRechargeTrendVO(item.getTrendDay25(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay26(getSumRechargeTrendVO(item.getTrendDay26(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay27(getSumRechargeTrendVO(item.getTrendDay27(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay28(getSumRechargeTrendVO(item.getTrendDay28(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay29(getSumRechargeTrendVO(item.getTrendDay29(), trendDay1Money, item.getCost()));
+
+        item.setRechargeTrendMonth1(getSumRechargeTrendVO(item.getTrendMonth1(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendMonth2(getSumRechargeTrendVO(item.getTrendMonth2(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendMonth3(getSumRechargeTrendVO(item.getTrendMonth3(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendMonth6(getSumRechargeTrendVO(item.getTrendMonth6(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendYear1(getSumRechargeTrendVO(item.getTrendYear1(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendTotal(getSumRechargeTrendVO(item.getTrendTotal(), trendDay1Money, item.getCost()));
+    }
+
+    private RechargeTrendVO getSumRechargeTrendVO(String trendDay, BigDecimal trendDay1Money, BigDecimal cost) {
+        String[] trendDayResult = trendDay.split("/");
+        BigDecimal dayTotalRecharge = new BigDecimal(trendDayResult[1]);
+        BigDecimal dayRecharge = new BigDecimal(trendDayResult[0]);
+        return RechargeTrendVO.builder()
+                .rechargeMoney(dayRecharge)
+                .rechargeUserCount(Long.valueOf(trendDayResult[2]))
+                .rechargeMoneyTotal(dayTotalRecharge)
+                .increase(cost.compareTo(BigDecimal.ZERO) == 0 ?
+                        BigDecimal.ZERO:dayRecharge.divide(cost,4, RoundingMode.DOWN))
+                .back(cost.compareTo(BigDecimal.ZERO) == 0 ?
+                        BigDecimal.ZERO:dayTotalRecharge.divide(cost,4, RoundingMode.DOWN))
+                .multiples(trendDay1Money.compareTo(BigDecimal.ZERO) == 0 ?
+                        BigDecimal.ZERO:dayTotalRecharge.divide(trendDay1Money,4, RoundingMode.DOWN))
+                .build();
     }
 
     @Override
@@ -348,6 +369,9 @@ public class AccountAgentDayServiceImpl implements IAccountAgentDayService {
         showSql.setParam("rechargeEndDay", dto.getRechargeEndDay());
         //循环总数据的每条数据
         List<GamePromoteTotalVO> hasRechargeDayList = list.stream().map(item -> {
+
+            setTotalRechargeTrend(item);
+
             showSql.setParam("sourceSystem", item.getSourceSystem());
             showSql.setParam("agentId", item.getAgentId());
             showSql.setParam("accountId", item.getAccountId());
@@ -461,6 +485,46 @@ public class AccountAgentDayServiceImpl implements IAccountAgentDayService {
         return new Page<>(hasRechargeDayList, pager);
     }
 
+    private void setTotalRechargeTrend(GamePromoteTotalVO item) {
+        BigDecimal trendDay1Money = new BigDecimal(item.getTrendDay1().split("/")[0]);
+        item.setRechargeTrendDay1(getSumRechargeTrendVO(item.getTrendDay1(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay2(getSumRechargeTrendVO(item.getTrendDay2(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay3(getSumRechargeTrendVO(item.getTrendDay3(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay4(getSumRechargeTrendVO(item.getTrendDay4(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay5(getSumRechargeTrendVO(item.getTrendDay5(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay6(getSumRechargeTrendVO(item.getTrendDay6(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay7(getSumRechargeTrendVO(item.getTrendDay7(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay8(getSumRechargeTrendVO(item.getTrendDay8(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay9(getSumRechargeTrendVO(item.getTrendDay9(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay10(getSumRechargeTrendVO(item.getTrendDay10(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay11(getSumRechargeTrendVO(item.getTrendDay11(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay12(getSumRechargeTrendVO(item.getTrendDay12(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay13(getSumRechargeTrendVO(item.getTrendDay13(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay14(getSumRechargeTrendVO(item.getTrendDay14(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay15(getSumRechargeTrendVO(item.getTrendDay15(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay16(getSumRechargeTrendVO(item.getTrendDay16(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay17(getSumRechargeTrendVO(item.getTrendDay17(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay18(getSumRechargeTrendVO(item.getTrendDay18(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay19(getSumRechargeTrendVO(item.getTrendDay19(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay20(getSumRechargeTrendVO(item.getTrendDay20(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay21(getSumRechargeTrendVO(item.getTrendDay21(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay22(getSumRechargeTrendVO(item.getTrendDay22(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay23(getSumRechargeTrendVO(item.getTrendDay23(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay24(getSumRechargeTrendVO(item.getTrendDay24(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay25(getSumRechargeTrendVO(item.getTrendDay25(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay26(getSumRechargeTrendVO(item.getTrendDay26(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay27(getSumRechargeTrendVO(item.getTrendDay27(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay28(getSumRechargeTrendVO(item.getTrendDay28(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay29(getSumRechargeTrendVO(item.getTrendDay29(), trendDay1Money, item.getCost()));
+
+        item.setRechargeTrendMonth1(getSumRechargeTrendVO(item.getTrendMonth1(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendMonth2(getSumRechargeTrendVO(item.getTrendMonth2(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendMonth3(getSumRechargeTrendVO(item.getTrendMonth3(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendMonth6(getSumRechargeTrendVO(item.getTrendMonth6(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendYear1(getSumRechargeTrendVO(item.getTrendYear1(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendTotal(getSumRechargeTrendVO(item.getTrendTotal(), trendDay1Money, item.getCost()));
+    }
+
     @Override
     public Map<LocalDate, List<AgentDayAgainVO>> accountAgentDayAgain(AgentDayAgainDTO dto) {
 
@@ -754,9 +818,50 @@ public class AccountAgentDayServiceImpl implements IAccountAgentDayService {
                 BigDecimal.ZERO : gamePromoteTotalSumVO.getCost().divide(BigDecimal.valueOf(gamePromoteTotalSumVO.getOldUserRechargeCount()), 4, RoundingMode.DOWN));
         gamePromoteTotalSumVO.setShowRechargeCountCost(gamePromoteTotalSumVO.getShowRechargeCount() == 0 ?
                 BigDecimal.ZERO : gamePromoteTotalSumVO.getCost().divide(BigDecimal.valueOf(gamePromoteTotalSumVO.getShowRechargeCount()), 4, RoundingMode.DOWN));
+        setTotalSumRechargeTrend(gamePromoteTotalSumVO);
         return gamePromoteTotalSumVO;
     }
 
+    private void setTotalSumRechargeTrend(GamePromoteTotalSumVO item) {
+        BigDecimal trendDay1Money = new BigDecimal(item.getTrendDay1().split("/")[0]);
+        item.setRechargeTrendDay1(getSumRechargeTrendVO(item.getTrendDay1(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay2(getSumRechargeTrendVO(item.getTrendDay2(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay3(getSumRechargeTrendVO(item.getTrendDay3(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay4(getSumRechargeTrendVO(item.getTrendDay4(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay5(getSumRechargeTrendVO(item.getTrendDay5(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay6(getSumRechargeTrendVO(item.getTrendDay6(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay7(getSumRechargeTrendVO(item.getTrendDay7(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay8(getSumRechargeTrendVO(item.getTrendDay8(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay9(getSumRechargeTrendVO(item.getTrendDay9(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay10(getSumRechargeTrendVO(item.getTrendDay10(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay11(getSumRechargeTrendVO(item.getTrendDay11(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay12(getSumRechargeTrendVO(item.getTrendDay12(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay13(getSumRechargeTrendVO(item.getTrendDay13(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay14(getSumRechargeTrendVO(item.getTrendDay14(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay15(getSumRechargeTrendVO(item.getTrendDay15(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay16(getSumRechargeTrendVO(item.getTrendDay16(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay17(getSumRechargeTrendVO(item.getTrendDay17(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay18(getSumRechargeTrendVO(item.getTrendDay18(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay19(getSumRechargeTrendVO(item.getTrendDay19(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay20(getSumRechargeTrendVO(item.getTrendDay20(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay21(getSumRechargeTrendVO(item.getTrendDay21(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay22(getSumRechargeTrendVO(item.getTrendDay22(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay23(getSumRechargeTrendVO(item.getTrendDay23(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay24(getSumRechargeTrendVO(item.getTrendDay24(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay25(getSumRechargeTrendVO(item.getTrendDay25(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay26(getSumRechargeTrendVO(item.getTrendDay26(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay27(getSumRechargeTrendVO(item.getTrendDay27(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay28(getSumRechargeTrendVO(item.getTrendDay28(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendDay29(getSumRechargeTrendVO(item.getTrendDay29(), trendDay1Money, item.getCost()));
+
+        item.setRechargeTrendMonth1(getSumRechargeTrendVO(item.getTrendMonth1(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendMonth2(getSumRechargeTrendVO(item.getTrendMonth2(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendMonth3(getSumRechargeTrendVO(item.getTrendMonth3(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendMonth6(getSumRechargeTrendVO(item.getTrendMonth6(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendYear1(getSumRechargeTrendVO(item.getTrendYear1(), trendDay1Money, item.getCost()));
+        item.setRechargeTrendTotal(getSumRechargeTrendVO(item.getTrendTotal(), trendDay1Money, item.getCost()));
+    }
+
     private SimpleCriteria getSimpleCriteria(GamePromoteTotalSumDTO dto) {
         SimpleCriteria cri = Cnd.cri();
         // 组装条件
@@ -922,14 +1027,41 @@ public class AccountAgentDayServiceImpl implements IAccountAgentDayService {
                 	first_roi AS first_recovery_rate,
                 	buy_roi AS buy_recovery_rate,
                 	gross_profit AS gross_margin,
-                	roi3 AS roi_day3,
-                	roi5 AS roi_day5,
-                	roi7 AS roi_day7,
-                	roi15 AS roi_day15,
-                	roi30 AS roi_day30,
-                	roi60 AS roi_day60,
-                	roi180 AS roi_day180,
-                	roi1yaer AS roi_year1,
+                        roi1 AS roi_day1,
+                        roi2 AS roi_day2,
+                        roi3 AS roi_day3,
+                        roi4 AS roi_day4,
+                        roi5 AS roi_day5,
+                        roi6 AS roi_day6,
+                        roi7 AS roi_day7,
+                        roi8 AS roi_day8,
+                        roi9 AS roi_day9,
+                        roi10 AS roi_day10,
+                        roi11 AS roi_day11,
+                        roi12 AS roi_day12,
+                        roi13 AS roi_day13,
+                        roi14 AS roi_day14,
+                        roi15 AS roi_day15,
+                        roi16 AS roi_day16,
+                        roi17 AS roi_day17,
+                        roi18 AS roi_day18,
+                        roi19 AS roi_day19,
+                        roi20 AS roi_day20,
+                        roi21 AS roi_day21,
+                        roi22 AS roi_day22,
+                        roi23 AS roi_day23,
+                        roi24 AS roi_day24,
+                        roi25 AS roi_day25,
+                        roi26 AS roi_day26,
+                        roi27 AS roi_day27,
+                        roi28 AS roi_day28,
+                        roi29 AS roi_day29,
+                        roi30 AS roi_day30,
+                        roi60 AS roi_day60,
+                        roi90 AS roi_day90,
+                        roi180 AS roi_day180,
+                        roi1yaer AS roi_year1,
+                        roi_total AS roiTotal,
                 	first_rate AS first_recharge_rate,
                 	buy_user_rate AS buy_user_recharge_rate,
                 	today_rate AS new_user_recharge_rate,
@@ -943,16 +1075,41 @@ public class AccountAgentDayServiceImpl implements IAccountAgentDayService {
                 	first_arpu AS first_recharge_arpu,
                 	today_arpu AS today_recharge_arpu,
                 	paper_arpu AS show_recharge_arpu,
-                	amount_d1 AS trend_day1,
-                	amount_d3 AS trend_day3,
-                	amount_d5 AS trend_day5,
-                	amount_d7 AS trend_day7,
-                	amount_d15 AS trend_day15,
-                	amount_m1 AS trend_month1,
-                	amount_m2 AS trend_month2,
-                	amount_m3 AS trend_month3,
-                	amount_m6 AS trend_month6,
-                	amount_sum AS trend_total,
+                       amount_d1 AS trend_day1,
+                       amount_d2 AS trend_day2,
+                       amount_d3 AS trend_day3,
+                       amount_d4 AS trend_day4,
+                       amount_d5 AS trend_day5,
+                       amount_d6 AS trend_day6,
+                       amount_d7 AS trend_day7,
+                       amount_d8 AS trend_day8,
+                       amount_d9 AS trend_day9,
+                       amount_d10 AS trend_day10,
+                       amount_d11 AS trend_day11,
+                       amount_d12 AS trend_day12,
+                       amount_d13 AS trend_day13,
+                       amount_d14 AS trend_day14,
+                       amount_d15 AS trend_day15,
+                       amount_d16 AS trend_day16,
+                       amount_d17 AS trend_day17,
+                       amount_d18 AS trend_day18,
+                       amount_d19 AS trend_day19,
+                       amount_d20 AS trend_day20,
+                       amount_d21 AS trend_day21,
+                       amount_d22 AS trend_day22,
+                       amount_d23 AS trend_day23,
+                       amount_d24 AS trend_day24,
+                       amount_d25 AS trend_day25,
+                       amount_d26 AS trend_day26,
+                       amount_d27 AS trend_day27,
+                       amount_d28 AS trend_day28,
+                       amount_d29 AS trend_day29,
+                       amount_m1 AS trend_month1,
+                       amount_m2 AS trend_month2,
+                       amount_m3 AS trend_month3,
+                       amount_m6 AS trend_month6,
+                       amount_y1 AS trend_year1,
+                       amount_sum AS trend_total,
                 	round(if(first_new_user_amount_count > 0, cost / first_new_user_amount_count, 0), 4) as first_recharge_count_cost,
                 	round(if(old_amount_count > 0, cost / old_amount_count, 0), 4) as old_user_recharge_count_cost,
                 	round(if(amount_count > 0, cost / amount_count, 0), 4) as show_recharge_count_cost,
@@ -1014,36 +1171,93 @@ public class AccountAgentDayServiceImpl implements IAccountAgentDayService {
                 	round(if(sum(cost) > 0, sum(new_user_total_amount) / sum(cost), 0), 4) as today_recovery_rate,
                 	round(if(sum(cost) > 0, sum(buy_new_user_total_amount) / sum(cost), 0), 4) as buy_recovery_rate,
                 	sum(gross_profit) as gross_margin,
-                	round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d3, '/', 1)) / sum(cost), 0), 4) as roi_day3,
-                	round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d5, '/', 1)) / sum(cost), 0), 4) as roi_day5,
-                	round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d7, '/', 1)) / sum(cost), 0), 4) as roi_day7,
-                	round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d15, '/', 1)) / sum(cost), 0), 4) as roi_day15,
-                	round(if(sum(cost) > 0, sum(SPLIT_PART(amount_m1, '/', 1)) / sum(cost), 0), 4) as roi_day30,
-                	round(if(sum(cost) > 0, sum(SPLIT_PART(amount_m2, '/', 1)) / sum(cost), 0), 4) as roi_day60,
-                	round(if(sum(cost) > 0, sum(SPLIT_PART(amount_m6, '/', 1)) / sum(cost), 0), 4) as roi_day180,
-                	round(if(sum(cost) > 0, sum(SPLIT_PART(amount_y1, '/', 1)) / sum(cost), 0), 4) as roi_year1,
-                	round(if(sum(register_num) > 0, sum(first_new_user_amount_num) / sum(register_num), 0), 4) as first_recharge_rate,
-                	round(if(sum(register_num) > 0, sum(buy_new_user_total_amount_num) / sum(register_num), 0), 4) as buy_user_recharge_rate,
-                	round(if(sum(register_num) > 0, sum(first_new_user_amount_num) / sum(amount_num), 0), 4) as new_user_recharge_rate,
-                	round(if(sum(first_new_user_amount_count) > 0, sum(first_new_user_amount) / sum(first_new_user_amount_count), 0), 4) as avg_first_user_recharge,
-                	round(if(sum(buy_new_user_total_amount_count) > 0, sum(buy_new_user_total_amount) / sum(buy_new_user_total_amount_count), 0), 4) as avg_buy_user_recharge,
-                	round(if(sum(amount_count) > 0, sum(amount) / sum(amount_count), 0), 4) as avg_show_user_recharge,
-                	round(if(sum(first_new_user_amount_num) > 0, sum(cost) / sum(first_new_user_amount_num), 0), 4) as first_recharge_cost,
-                	round(if(sum(buy_new_user_total_amount_num) > 0, sum(cost) / sum(buy_new_user_total_amount_num), 0), 4) as buy_user_recharge_cost,
-                	round(if(sum(new_user_total_amount_num) > 0, sum(reg_order_user_again) / sum(new_user_total_amount_num), 0), 4) as repeat_recharge_rate,
-                	round(if(sum(register_num) > 0, sum(new_user_total_amount) / sum(register_num), 0), 4) as new_reg_arpu,
-                	round(if(sum(first_new_user_amount_num) > 0, sum(first_new_user_amount) / sum(first_new_user_amount_num), 0), 4) as first_recharge_arpu,
-                	round(if(sum(new_user_total_amount_num) > 0, sum(new_user_total_amount) / sum(new_user_total_amount_num), 0), 4) as today_recharge_arpu,
-                	round(if(sum(amount_num) > 0, sum(amount) / sum(amount_num), 0), 4) as show_recharge_arpu,
-                	round(if(sum(first_new_user_amount_count) > 0, sum(cost) / sum(first_new_user_amount_count), 0), 4) as first_recharge_count_cost,
-                	round(if(sum(old_amount_count) > 0, sum(cost) / sum(old_amount_count), 0), 4) as old_user_recharge_count_cost,
-                	round(if(sum(amount_count) > 0, sum(cost) / sum(amount_count), 0), 4) as show_recharge_count_cost,
-                	round(if(sum(new_user_total_amount_count) > 0, sum(cost) / sum(new_user_total_amount_count), 0), 4) as new_user_recharge_count_cost,
-                	sum(hundred_user_num) as hundred_user_num,
-                	round(if(sum(hundred_user_num) > 0, sum(cost) / sum(hundred_user_num), 0), 4) as hundred_user_num_cost
-                from
-                	ads_account_agent_day
-                """;
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d1, '/', 6)) / sum(cost), 0), 4) as roi_day1,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d2, '/', 6)) / sum(cost), 0), 4) as roi_day2,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d3, '/', 6)) / sum(cost), 0), 4) as roi_day3,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d4, '/', 6)) / sum(cost), 0), 4) as roi_day4,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d5, '/', 6)) / sum(cost), 0), 4) as roi_day5,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d6, '/', 6)) / sum(cost), 0), 4) as roi_day6,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d7, '/', 6)) / sum(cost), 0), 4) as roi_day7,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d8, '/', 6)) / sum(cost), 0), 4) as roi_day8,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d9, '/', 6)) / sum(cost), 0), 4) as roi_day9,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d10, '/', 6)) / sum(cost), 0), 4) as roi_day10,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d11, '/', 6)) / sum(cost), 0), 4) as roi_day11,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d12, '/', 6)) / sum(cost), 0), 4) as roi_day12,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d13, '/', 6)) / sum(cost), 0), 4) as roi_day13,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d14, '/', 6)) / sum(cost), 0), 4) as roi_day14,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d15, '/', 6)) / sum(cost), 0), 4) as roi_day15,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d16, '/', 6)) / sum(cost), 0), 4) as roi_day16,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d17, '/', 6)) / sum(cost), 0), 4) as roi_day17,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d18, '/', 6)) / sum(cost), 0), 4) as roi_day18,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d19, '/', 6)) / sum(cost), 0), 4) as roi_day19,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d20, '/', 6)) / sum(cost), 0), 4) as roi_day20,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d21, '/', 6)) / sum(cost), 0), 4) as roi_day21,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d22, '/', 6)) / sum(cost), 0), 4) as roi_day22,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d23, '/', 6)) / sum(cost), 0), 4) as roi_day23,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d24, '/', 6)) / sum(cost), 0), 4) as roi_day24,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d25, '/', 6)) / sum(cost), 0), 4) as roi_day25,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d26, '/', 6)) / sum(cost), 0), 4) as roi_day26,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d27, '/', 6)) / sum(cost), 0), 4) as roi_day27,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d28, '/', 6)) / sum(cost), 0), 4) as roi_day28,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d29, '/', 6)) / sum(cost), 0), 4) as roi_day29,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_m1, '/', 6)) / sum(cost), 0), 4) as roi_day30,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_m2, '/', 6)) / sum(cost), 0), 4) as roi_day60,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_m3, '/', 6)) / sum(cost), 0), 4) as roi_day90,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_m6, '/', 6)) / sum(cost), 0), 4) as roi_day180,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_y1, '/', 6)) / sum(cost), 0), 4) as roi_year1,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_sum, '/', 6)) / sum(cost), 0), 4) as roi_total,
+                         """
+                +trendDay()+
+                        """
+                         CONCAT(SUM(CAST(SPLIT_PART(amount_m1 , '/', 1) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_m1, '/', 6) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_m1, '/', 2) AS BIGINT))) AS trend_month1,
+                         CONCAT(SUM(CAST(SPLIT_PART(amount_m2 , '/', 1) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_m2, '/', 6) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_m2, '/', 2) AS BIGINT))) AS trend_month2,
+                         CONCAT(SUM(CAST(SPLIT_PART(amount_m3 , '/', 1) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_m3, '/', 6) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_m3, '/', 2) AS BIGINT))) AS trend_month3,
+                         CONCAT(SUM(CAST(SPLIT_PART(amount_m6 , '/', 1) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_m6, '/', 6) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_m6, '/', 2) AS BIGINT))) AS trend_month6,
+                         CONCAT(SUM(CAST(SPLIT_PART(amount_y1 , '/', 1) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_y1, '/', 6) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_y1, '/', 2) AS BIGINT))) AS trend_year1,
+                         CONCAT(SUM(CAST(SPLIT_PART(amount_sum , '/', 1) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_sum, '/', 6) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_sum, '/', 2) AS BIGINT))) AS trend_total,
+                    round(if(sum(register_num) > 0, sum(first_new_user_amount_num) / sum(register_num), 0), 4) as first_recharge_rate,
+                    round(if(sum(register_num) > 0, sum(buy_new_user_total_amount_num) / sum(register_num), 0), 4) as buy_user_recharge_rate,
+                    round(if(sum(register_num) > 0, sum(first_new_user_amount_num) / sum(amount_num), 0), 4) as new_user_recharge_rate,
+                    round(if(sum(first_new_user_amount_count) > 0, sum(first_new_user_amount) / sum(first_new_user_amount_count), 0), 4) as avg_first_user_recharge,
+                    round(if(sum(buy_new_user_total_amount_count) > 0, sum(buy_new_user_total_amount) / sum(buy_new_user_total_amount_count), 0), 4) as avg_buy_user_recharge,
+                    round(if(sum(amount_count) > 0, sum(amount) / sum(amount_count), 0), 4) as avg_show_user_recharge,
+                    round(if(sum(first_new_user_amount_num) > 0, sum(cost) / sum(first_new_user_amount_num), 0), 4) as first_recharge_cost,
+                    round(if(sum(buy_new_user_total_amount_num) > 0, sum(cost) / sum(buy_new_user_total_amount_num), 0), 4) as buy_user_recharge_cost,
+                    round(if(sum(new_user_total_amount_num) > 0, sum(reg_order_user_again) / sum(new_user_total_amount_num), 0), 4) as repeat_recharge_rate,
+                    round(if(sum(register_num) > 0, sum(new_user_total_amount) / sum(register_num), 0), 4) as new_reg_arpu,
+                    round(if(sum(first_new_user_amount_num) > 0, sum(first_new_user_amount) / sum(first_new_user_amount_num), 0), 4) as first_recharge_arpu,
+                    round(if(sum(new_user_total_amount_num) > 0, sum(new_user_total_amount) / sum(new_user_total_amount_num), 0), 4) as today_recharge_arpu,
+                    round(if(sum(amount_num) > 0, sum(amount) / sum(amount_num), 0), 4) as show_recharge_arpu,
+                    round(if(sum(first_new_user_amount_count) > 0, sum(cost) / sum(first_new_user_amount_count), 0), 4) as first_recharge_count_cost,
+                    round(if(sum(old_amount_count) > 0, sum(cost) / sum(old_amount_count), 0), 4) as old_user_recharge_count_cost,
+                    round(if(sum(amount_count) > 0, sum(cost) / sum(amount_count), 0), 4) as show_recharge_count_cost,
+                    round(if(sum(new_user_total_amount_count) > 0, sum(cost) / sum(new_user_total_amount_count), 0), 4) as new_user_recharge_count_cost,
+                    sum(hundred_user_num) as hundred_user_num,
+                    round(if(sum(hundred_user_num) > 0, sum(cost) / sum(hundred_user_num), 0), 4) as hundred_user_num_cost
+                        from
+                        	ads_account_agent_day
+                        """;
+    }
+
+    private String trendDay(){
+        StringBuilder trendDay = new StringBuilder(StringUtils.EMPTY);
+        for (int day = 1; day <= 29; day++) {
+            trendDay.append("CONCAT(")
+                    .append("SUM(CAST(SPLIT_PART(amount_d")
+                    .append(day)
+                    .append(" , '/', 1) AS DECIMAL(10, 2))), ")
+                    .append("'/', ")
+                    .append("SUM(CAST(SPLIT_PART(amount_d")
+                    .append(day)
+                    .append(", '/', 6) AS DECIMAL(10, 2))), ")
+                    .append("'/', ")
+                    .append("SUM(CAST(SPLIT_PART(amount_d")
+                    .append(day)
+                    .append(", '/', 2) AS BIGINT))")
+                    .append(") AS trend_day")
+                    .append(day).append(",");
+        }
+        return trendDay.toString();
     }
 
     /**
@@ -1110,14 +1324,50 @@ public class AccountAgentDayServiceImpl implements IAccountAgentDayService {
                 	round(if(sum(a.cost) > 0, sum(a.first_new_user_amount) / sum(a.cost), 0), 4) as first_recovery_rate,
                 	round(if(sum(a.cost) > 0, sum(a.new_user_total_amount) / sum(a.cost), 0), 4) as today_recovery_rate,
                 	sum(a.gross_profit) as gross_margin,
-                	round(if(sum(a.cost) > 0, sum(a.SPLIT_PART(a.amount_d3, '/', 1)) / sum(a.cost), 0), 4) as roi_day3,
-                	round(if(sum(a.cost) > 0, sum(a.SPLIT_PART(a.amount_d5, '/', 1)) / sum(a.cost), 0), 4) as roi_day5,
-                	round(if(sum(a.cost) > 0, sum(a.SPLIT_PART(a.amount_d7, '/', 1)) / sum(a.cost), 0), 4) as roi_day7,
-                	round(if(sum(a.cost) > 0, sum(a.SPLIT_PART(a.amount_d15, '/', 1)) / sum(a.cost), 0), 4) as roi_day15,
-                	round(if(sum(a.cost) > 0, sum(a.SPLIT_PART(a.amount_m1, '/', 1)) / sum(a.cost), 0), 4) as roi_day30,
-                	round(if(sum(a.cost) > 0, sum(a.SPLIT_PART(a.amount_m2, '/', 1)) / sum(a.cost), 0), 4) as roi_day60,
-                	round(if(sum(a.cost) > 0, sum(a.SPLIT_PART(a.amount_m6, '/', 1)) / sum(a.cost), 0), 4) as roi_day180,
-                	round(if(sum(a.cost) > 0, sum(a.SPLIT_PART(a.amount_y1, '/', 1)) / sum(a.cost), 0), 4) as roi_year1,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d1, '/', 6)) / sum(cost), 0), 4) as roi_day1,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d2, '/', 6)) / sum(cost), 0), 4) as roi_day2,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d3, '/', 6)) / sum(cost), 0), 4) as roi_day3,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d4, '/', 6)) / sum(cost), 0), 4) as roi_day4,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d5, '/', 6)) / sum(cost), 0), 4) as roi_day5,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d6, '/', 6)) / sum(cost), 0), 4) as roi_day6,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d7, '/', 6)) / sum(cost), 0), 4) as roi_day7,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d8, '/', 6)) / sum(cost), 0), 4) as roi_day8,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d9, '/', 6)) / sum(cost), 0), 4) as roi_day9,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d10, '/', 6)) / sum(cost), 0), 4) as roi_day10,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d11, '/', 6)) / sum(cost), 0), 4) as roi_day11,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d12, '/', 6)) / sum(cost), 0), 4) as roi_day12,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d13, '/', 6)) / sum(cost), 0), 4) as roi_day13,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d14, '/', 6)) / sum(cost), 0), 4) as roi_day14,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d15, '/', 6)) / sum(cost), 0), 4) as roi_day15,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d16, '/', 6)) / sum(cost), 0), 4) as roi_day16,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d17, '/', 6)) / sum(cost), 0), 4) as roi_day17,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d18, '/', 6)) / sum(cost), 0), 4) as roi_day18,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d19, '/', 6)) / sum(cost), 0), 4) as roi_day19,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d20, '/', 6)) / sum(cost), 0), 4) as roi_day20,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d21, '/', 6)) / sum(cost), 0), 4) as roi_day21,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d22, '/', 6)) / sum(cost), 0), 4) as roi_day22,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d23, '/', 6)) / sum(cost), 0), 4) as roi_day23,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d24, '/', 6)) / sum(cost), 0), 4) as roi_day24,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d25, '/', 6)) / sum(cost), 0), 4) as roi_day25,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d26, '/', 6)) / sum(cost), 0), 4) as roi_day26,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d27, '/', 6)) / sum(cost), 0), 4) as roi_day27,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d28, '/', 6)) / sum(cost), 0), 4) as roi_day28,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d29, '/', 6)) / sum(cost), 0), 4) as roi_day29,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_m1, '/', 6)) / sum(cost), 0), 4) as roi_day30,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_m2, '/', 6)) / sum(cost), 0), 4) as roi_day60,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_m3, '/', 6)) / sum(cost), 0), 4) as roi_day90,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_m6, '/', 6)) / sum(cost), 0), 4) as roi_day180,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_y1, '/', 6)) / sum(cost), 0), 4) as roi_year1,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_sum, '/', 6)) / sum(cost), 0), 4) as roi_total,
+                          """
+                            +trendDay()+
+                          """
+                         CONCAT(SUM(CAST(SPLIT_PART(amount_m1 , '/', 1) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_m1, '/', 6) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_m1, '/', 2) AS BIGINT))) AS trend_month1,
+                         CONCAT(SUM(CAST(SPLIT_PART(amount_m2 , '/', 1) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_m2, '/', 6) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_m2, '/', 2) AS BIGINT))) AS trend_month2,
+                         CONCAT(SUM(CAST(SPLIT_PART(amount_m3 , '/', 1) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_m3, '/', 6) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_m3, '/', 2) AS BIGINT))) AS trend_month3,
+                         CONCAT(SUM(CAST(SPLIT_PART(amount_m6 , '/', 1) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_m6, '/', 6) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_m6, '/', 2) AS BIGINT))) AS trend_month6,
+                         CONCAT(SUM(CAST(SPLIT_PART(amount_y1 , '/', 1) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_y1, '/', 6) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_y1, '/', 2) AS BIGINT))) AS trend_year1,
+                         CONCAT(SUM(CAST(SPLIT_PART(amount_sum , '/', 1) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_sum, '/', 6) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_sum, '/', 2) AS BIGINT))) AS trend_total,
                 	round(if(sum(a.register_num) > 0, sum(a.first_new_user_amount_num) / sum(a.register_num), 0), 4) as first_recharge_rate,
                 	round(if(sum(a.register_num) > 0, sum(a.new_user_total_amount_num) / sum(a.register_num), 0), 4) as today_recharge_rate,
                 	round(if(sum(a.first_new_user_amount_count) > 0, sum(a.first_new_user_amount) / sum(a.first_new_user_amount_count), 0), 4) as avg_first_user_recharge,
@@ -1198,14 +1448,50 @@ public class AccountAgentDayServiceImpl implements IAccountAgentDayService {
                 	round(if(sum(a.cost) > 0, sum(a.first_new_user_amount) / sum(a.cost), 0), 4) as first_recovery_rate,
                 	round(if(sum(a.cost) > 0, sum(a.new_user_total_amount) / sum(a.cost), 0), 4) as today_recovery_rate,
                 	sum(a.gross_profit) as gross_margin,
-                	round(if(sum(a.cost) > 0, sum(a.SPLIT_PART(a.amount_d3, '/', 1)) / sum(a.cost), 0), 4) as roi_day3,
-                	round(if(sum(a.cost) > 0, sum(a.SPLIT_PART(a.amount_d5, '/', 1)) / sum(a.cost), 0), 4) as roi_day5,
-                	round(if(sum(a.cost) > 0, sum(a.SPLIT_PART(a.amount_d7, '/', 1)) / sum(a.cost), 0), 4) as roi_day7,
-                	round(if(sum(a.cost) > 0, sum(a.SPLIT_PART(a.amount_d15, '/', 1)) / sum(a.cost), 0), 4) as roi_day15,
-                	round(if(sum(a.cost) > 0, sum(a.SPLIT_PART(a.amount_m1, '/', 1)) / sum(a.cost), 0), 4) as roi_day30,
-                	round(if(sum(a.cost) > 0, sum(a.SPLIT_PART(a.amount_m2, '/', 1)) / sum(a.cost), 0), 4) as roi_day60,
-                	round(if(sum(a.cost) > 0, sum(a.SPLIT_PART(a.amount_m6, '/', 1)) / sum(a.cost), 0), 4) as roi_day180,
-                	round(if(sum(a.cost) > 0, sum(a.SPLIT_PART(a.amount_y1, '/', 1)) / sum(a.cost), 0), 4) as roi_year1,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d1, '/', 6)) / sum(cost), 0), 4) as roi_day1,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d2, '/', 6)) / sum(cost), 0), 4) as roi_day2,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d3, '/', 6)) / sum(cost), 0), 4) as roi_day3,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d4, '/', 6)) / sum(cost), 0), 4) as roi_day4,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d5, '/', 6)) / sum(cost), 0), 4) as roi_day5,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d6, '/', 6)) / sum(cost), 0), 4) as roi_day6,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d7, '/', 6)) / sum(cost), 0), 4) as roi_day7,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d8, '/', 6)) / sum(cost), 0), 4) as roi_day8,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d9, '/', 6)) / sum(cost), 0), 4) as roi_day9,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d10, '/', 6)) / sum(cost), 0), 4) as roi_day10,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d11, '/', 6)) / sum(cost), 0), 4) as roi_day11,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d12, '/', 6)) / sum(cost), 0), 4) as roi_day12,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d13, '/', 6)) / sum(cost), 0), 4) as roi_day13,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d14, '/', 6)) / sum(cost), 0), 4) as roi_day14,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d15, '/', 6)) / sum(cost), 0), 4) as roi_day15,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d16, '/', 6)) / sum(cost), 0), 4) as roi_day16,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d17, '/', 6)) / sum(cost), 0), 4) as roi_day17,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d18, '/', 6)) / sum(cost), 0), 4) as roi_day18,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d19, '/', 6)) / sum(cost), 0), 4) as roi_day19,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d20, '/', 6)) / sum(cost), 0), 4) as roi_day20,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d21, '/', 6)) / sum(cost), 0), 4) as roi_day21,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d22, '/', 6)) / sum(cost), 0), 4) as roi_day22,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d23, '/', 6)) / sum(cost), 0), 4) as roi_day23,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d24, '/', 6)) / sum(cost), 0), 4) as roi_day24,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d25, '/', 6)) / sum(cost), 0), 4) as roi_day25,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d26, '/', 6)) / sum(cost), 0), 4) as roi_day26,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d27, '/', 6)) / sum(cost), 0), 4) as roi_day27,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d28, '/', 6)) / sum(cost), 0), 4) as roi_day28,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_d29, '/', 6)) / sum(cost), 0), 4) as roi_day29,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_m1, '/', 6)) / sum(cost), 0), 4) as roi_day30,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_m2, '/', 6)) / sum(cost), 0), 4) as roi_day60,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_m3, '/', 6)) / sum(cost), 0), 4) as roi_day90,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_m6, '/', 6)) / sum(cost), 0), 4) as roi_day180,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_y1, '/', 6)) / sum(cost), 0), 4) as roi_year1,
+                         round(if(sum(cost) > 0, sum(SPLIT_PART(amount_sum, '/', 6)) / sum(cost), 0), 4) as roi_total,
+                        """
+                +trendDay()+
+                        """
+                         CONCAT(SUM(CAST(SPLIT_PART(amount_m1 , '/', 1) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_m1, '/', 6) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_m1, '/', 2) AS BIGINT))) AS trend_month1,
+                         CONCAT(SUM(CAST(SPLIT_PART(amount_m2 , '/', 1) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_m2, '/', 6) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_m2, '/', 2) AS BIGINT))) AS trend_month2,
+                         CONCAT(SUM(CAST(SPLIT_PART(amount_m3 , '/', 1) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_m3, '/', 6) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_m3, '/', 2) AS BIGINT))) AS trend_month3,
+                         CONCAT(SUM(CAST(SPLIT_PART(amount_m6 , '/', 1) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_m6, '/', 6) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_m6, '/', 2) AS BIGINT))) AS trend_month6,
+                         CONCAT(SUM(CAST(SPLIT_PART(amount_y1 , '/', 1) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_y1, '/', 6) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_y1, '/', 2) AS BIGINT))) AS trend_year1,
+                         CONCAT(SUM(CAST(SPLIT_PART(amount_sum , '/', 1) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_sum, '/', 6) AS DECIMAL(10, 2))),'/',SUM(CAST(SPLIT_PART(amount_sum, '/', 2) AS BIGINT))) AS trend_total,
                 	round(if(sum(a.register_num) > 0, sum(a.first_new_user_amount_num) / sum(a.register_num), 0), 4) as first_recharge_rate,
                 	round(if(sum(a.register_num) > 0, sum(a.new_user_total_amount_num) / sum(a.register_num), 0), 4) as today_recharge_rate,
                 	round(if(sum(a.first_new_user_amount_count) > 0, sum(a.first_new_user_amount) / sum(a.first_new_user_amount_count), 0), 4) as avg_first_user_recharge,

+ 151 - 286
game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/service/impl/GameDataServiceImpl.java

@@ -31,9 +31,12 @@ import org.springframework.beans.BeanWrapperImpl;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
 import org.springframework.util.CollectionUtils;
+import reactor.util.function.Tuple2;
+import reactor.util.function.Tuples;
 
 import java.beans.PropertyDescriptor;
 import java.lang.reflect.Field;
+import java.lang.reflect.Modifier;
 import java.math.BigDecimal;
 import java.math.RoundingMode;
 import java.time.LocalDate;
@@ -48,6 +51,38 @@ import java.util.stream.Collectors;
 @Service
 @Slf4j
 public class GameDataServiceImpl implements IGameDataService {
+    private static final List<Tuple2<Field, Field>> dayNFieldMapList;
+    static  {
+        Map<String, Field> fieldMap = new HashMap<>();
+        List<Field> dayNFieldList = new ArrayList<>();
+        Class<?> tempClazz = GameDataDayVO.class;
+        while (tempClazz != null) {
+            Field[] fields = tempClazz.getDeclaredFields();
+            for (Field field : fields) {
+                if (Modifier.isFinal(field.getModifiers()) || Modifier.isStatic(field.getModifiers())) {
+                    continue;
+                }
+                fieldMap.put(field.getName(), field);
+                if (field.getType() == RechargeTrendVO.class) {
+                    dayNFieldList.add(field);
+                }
+            }
+            tempClazz = tempClazz.getSuperclass();
+        }
+        if(dayNFieldList.isEmpty()) {
+            dayNFieldMapList  = Collections.emptyList();
+        } else {
+            dayNFieldMapList = new ArrayList<>(dayNFieldList.size());
+            for(Field dayNField : dayNFieldList) {
+                dayNField.setAccessible(true);
+                Field sourceField = fieldMap.get(dayNField.getName().replace("Trend", ""));
+                sourceField.setAccessible(true);
+                if(sourceField != null) {
+                    dayNFieldMapList.add(Tuples.of(sourceField, dayNField));
+                }
+            }
+        }
+    }
 
     @Autowired
     private Dao dao;
@@ -113,283 +148,7 @@ public class GameDataServiceImpl implements IGameDataService {
         pager.setRecordCount(dao.count(AdsGameDay.class, cri));
 
         List<GameDataDayVO> gameDataDayVOList = list.stream().map(vo -> {
-            //买量数据
-            /*String[] buyAmountD1 = vo.getBuyAmountD1().split("/");
-            vo.setBuyAmountD1Trend(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(buyAmountD1[0]))
-                    .rechargeUserCount(Long.valueOf(buyAmountD1[1]))
-                    .increase(new BigDecimal(buyAmountD1[2]))
-                    .back(new BigDecimal(buyAmountD1[3]))
-                    .multiples(new BigDecimal(buyAmountD1[4]))
-                    .build());*/
-            setAgainContentByNum(vo, "D1", "buy");
-
-
-            String[] buyAmountD3 = vo.getBuyAmountD3().split("/");
-            vo.setBuyAmountD3Trend(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(buyAmountD3[0]))
-                    .rechargeUserCount(Long.valueOf(buyAmountD3[1]))
-                    .increase(new BigDecimal(buyAmountD3[2]))
-                    .back(new BigDecimal(buyAmountD3[3]))
-                    .multiples(new BigDecimal(buyAmountD3[4]))
-                    .build());
-
-            String[] buyAmountD5 = vo.getBuyAmountD5().split("/");
-            vo.setBuyAmountD5Trend(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(buyAmountD5[0]))
-                    .rechargeUserCount(Long.valueOf(buyAmountD5[1]))
-                    .increase(new BigDecimal(buyAmountD5[2]))
-                    .back(new BigDecimal(buyAmountD5[3]))
-                    .multiples(new BigDecimal(buyAmountD5[4]))
-                    .build());
-
-            String[] buyAmountD7 = vo.getBuyAmountD7().split("/");
-            vo.setBuyAmountD7Trend(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(buyAmountD7[0]))
-                    .rechargeUserCount(Long.valueOf(buyAmountD7[1]))
-                    .increase(new BigDecimal(buyAmountD7[2]))
-                    .back(new BigDecimal(buyAmountD7[3]))
-                    .multiples(new BigDecimal(buyAmountD7[4]))
-                    .build());
-
-            String[] buyAmountD15 = vo.getBuyAmountD15().split("/");
-            vo.setBuyAmountD15Trend(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(buyAmountD15[0]))
-                    .rechargeUserCount(Long.valueOf(buyAmountD15[1]))
-                    .increase(new BigDecimal(buyAmountD15[2]))
-                    .back(new BigDecimal(buyAmountD15[3]))
-                    .multiples(new BigDecimal(buyAmountD15[4]))
-                    .build());
-
-            String[] buyAmountM1 = vo.getBuyAmountM1().split("/");
-            vo.setBuyAmountM1Trend(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(buyAmountM1[0]))
-                    .rechargeUserCount(Long.valueOf(buyAmountM1[1]))
-                    .increase(new BigDecimal(buyAmountM1[2]))
-                    .back(new BigDecimal(buyAmountM1[3]))
-                    .multiples(new BigDecimal(buyAmountM1[4]))
-                    .build());
-
-            String[] buyAmountM2 = vo.getBuyAmountM2().split("/");
-            vo.setBuyAmountM2Trend(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(buyAmountM2[0]))
-                    .rechargeUserCount(Long.valueOf(buyAmountM2[1]))
-                    .increase(new BigDecimal(buyAmountM2[2]))
-                    .back(new BigDecimal(buyAmountM2[3]))
-                    .multiples(new BigDecimal(buyAmountM2[4]))
-                    .build());
-
-            String[] buyAmountM3 = vo.getBuyAmountM3().split("/");
-            vo.setBuyAmountM3Trend(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(buyAmountM3[0]))
-                    .rechargeUserCount(Long.valueOf(buyAmountM3[1]))
-                    .increase(new BigDecimal(buyAmountM3[2]))
-                    .back(new BigDecimal(buyAmountM3[3]))
-                    .multiples(new BigDecimal(buyAmountM3[4]))
-                    .build());
-
-            String[] buyAmountM6 = vo.getBuyAmountM6().split("/");
-            vo.setBuyAmountM6Trend(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(buyAmountM6[0]))
-                    .rechargeUserCount(Long.valueOf(buyAmountM6[1]))
-                    .increase(new BigDecimal(buyAmountM6[2]))
-                    .back(new BigDecimal(buyAmountM6[3]))
-                    .multiples(new BigDecimal(buyAmountM6[4]))
-                    .build());
-
-            String[] buyAmountSum = vo.getBuyAmountSum().split("/");
-            vo.setBuyAmountSumTrend(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(buyAmountSum[0]))
-                    .rechargeUserCount(Long.valueOf(buyAmountSum[1]))
-                    .increase(new BigDecimal(buyAmountSum[2]))
-                    .back(new BigDecimal(buyAmountSum[3]))
-                    .multiples(new BigDecimal(buyAmountSum[4]))
-                    .build());
-
-            //自然量数据
-            String[] natureAmountD1 = vo.getNatureAmountD1().split("/");
-            vo.setNatureAmountD1Trend(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(natureAmountD1[0]))
-                    .rechargeUserCount(Long.valueOf(natureAmountD1[1]))
-                    .increase(new BigDecimal(natureAmountD1[2]))
-                    .back(new BigDecimal(natureAmountD1[3]))
-                    .multiples(new BigDecimal(natureAmountD1[4]))
-                    .build());
-
-            String[] natureAmountD3 = vo.getNatureAmountD3().split("/");
-            vo.setNatureAmountD3Trend(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(natureAmountD3[0]))
-                    .rechargeUserCount(Long.valueOf(natureAmountD3[1]))
-                    .increase(new BigDecimal(natureAmountD3[2]))
-                    .back(new BigDecimal(natureAmountD3[3]))
-                    .multiples(new BigDecimal(natureAmountD3[4]))
-                    .build());
-
-            String[] natureAmountD5 = vo.getNatureAmountD5().split("/");
-            vo.setNatureAmountD5Trend(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(natureAmountD5[0]))
-                    .rechargeUserCount(Long.valueOf(natureAmountD5[1]))
-                    .increase(new BigDecimal(natureAmountD5[2]))
-                    .back(new BigDecimal(natureAmountD5[3]))
-                    .multiples(new BigDecimal(natureAmountD5[4]))
-                    .build());
-
-            String[] natureAmountD7 = vo.getNatureAmountD7().split("/");
-            vo.setNatureAmountD7Trend(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(natureAmountD7[0]))
-                    .rechargeUserCount(Long.valueOf(natureAmountD7[1]))
-                    .increase(new BigDecimal(natureAmountD7[2]))
-                    .back(new BigDecimal(natureAmountD7[3]))
-                    .multiples(new BigDecimal(natureAmountD7[4]))
-                    .build());
-
-            String[] natureAmountD15 = vo.getNatureAmountD15().split("/");
-            vo.setNatureAmountD15Trend(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(natureAmountD15[0]))
-                    .rechargeUserCount(Long.valueOf(natureAmountD15[1]))
-                    .increase(new BigDecimal(natureAmountD15[2]))
-                    .back(new BigDecimal(natureAmountD15[3]))
-                    .multiples(new BigDecimal(natureAmountD15[4]))
-                    .build());
-
-            String[] natureAmountM1 = vo.getNatureAmountM1().split("/");
-            vo.setNatureAmountM1Trend(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(natureAmountM1[0]))
-                    .rechargeUserCount(Long.valueOf(natureAmountM1[1]))
-                    .increase(new BigDecimal(natureAmountM1[2]))
-                    .back(new BigDecimal(natureAmountM1[3]))
-                    .multiples(new BigDecimal(natureAmountM1[4]))
-                    .build());
-
-            String[] natureAmountM2 = vo.getNatureAmountM2().split("/");
-            vo.setNatureAmountM2Trend(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(natureAmountM2[0]))
-                    .rechargeUserCount(Long.valueOf(natureAmountM2[1]))
-                    .increase(new BigDecimal(natureAmountM2[2]))
-                    .back(new BigDecimal(natureAmountM2[3]))
-                    .multiples(new BigDecimal(natureAmountM2[4]))
-                    .build());
-
-            String[] natureAmountM3 = vo.getNatureAmountM3().split("/");
-            vo.setNatureAmountM3Trend(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(natureAmountM3[0]))
-                    .rechargeUserCount(Long.valueOf(natureAmountM3[1]))
-                    .increase(new BigDecimal(natureAmountM3[2]))
-                    .back(new BigDecimal(natureAmountM3[3]))
-                    .multiples(new BigDecimal(natureAmountM3[4]))
-                    .build());
-
-            String[] natureAmountM6 = vo.getNatureAmountM6().split("/");
-            vo.setNatureAmountM6Trend(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(natureAmountM6[0]))
-                    .rechargeUserCount(Long.valueOf(natureAmountM6[1]))
-                    .increase(new BigDecimal(natureAmountM6[2]))
-                    .back(new BigDecimal(natureAmountM6[3]))
-                    .multiples(new BigDecimal(natureAmountM6[4]))
-                    .build());
-
-            String[] natureAmountSum = vo.getNatureAmountSum().split("/");
-            vo.setNatureAmountSumTrend(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(natureAmountSum[0]))
-                    .rechargeUserCount(Long.valueOf(natureAmountSum[1]))
-                    .increase(new BigDecimal(natureAmountSum[2]))
-                    .back(new BigDecimal(natureAmountSum[3]))
-                    .multiples(new BigDecimal(natureAmountSum[4]))
-                    .build());
-
-            //总量数据
-            /*String[] amountD1 = vo.getAmountD1().split("/");
-            vo.setAmountD1Trend(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(amountD1[0]))
-                    .rechargeUserCount(Long.valueOf(amountD1[1]))
-                    .increase(new BigDecimal(amountD1[2]))
-                    .back(new BigDecimal(amountD1[3]))
-                    .multiples(new BigDecimal(amountD1[4]).setScale(2,RoundingMode.HALF_UP))
-                    .build());*/
-            setAgainContentByNum(vo, "D1", "");
-
-
-            String[] amountD3 = vo.getAmountD3().split("/");
-            vo.setAmountD3Trend(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(amountD3[0]))
-                    .rechargeUserCount(Long.valueOf(amountD3[1]))
-                    .increase(new BigDecimal(amountD3[2]))
-                    .back(new BigDecimal(amountD3[3]))
-                    .multiples(new BigDecimal(amountD3[4]))
-                    .build());
-
-            String[] amountD5 = vo.getAmountD5().split("/");
-            vo.setAmountD5Trend(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(amountD5[0]))
-                    .rechargeUserCount(Long.valueOf(amountD5[1]))
-                    .increase(new BigDecimal(amountD5[2]))
-                    .back(new BigDecimal(amountD5[3]))
-                    .multiples(new BigDecimal(amountD5[4]))
-                    .build());
-
-            String[] amountD7 = vo.getAmountD7().split("/");
-            vo.setAmountD7Trend(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(amountD7[0]))
-                    .rechargeUserCount(Long.valueOf(amountD7[1]))
-                    .increase(new BigDecimal(amountD7[2]))
-                    .back(new BigDecimal(amountD7[3]))
-                    .multiples(new BigDecimal(amountD7[4]))
-                    .build());
-
-            String[] amountD15 = vo.getAmountD15().split("/");
-            vo.setAmountD15Trend(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(amountD15[0]))
-                    .rechargeUserCount(Long.valueOf(amountD15[1]))
-                    .increase(new BigDecimal(amountD15[2]))
-                    .back(new BigDecimal(amountD15[3]))
-                    .multiples(new BigDecimal(amountD15[4]))
-                    .build());
-
-            String[] amountM1 = vo.getAmountM1().split("/");
-            vo.setAmountM1Trend(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(amountM1[0]))
-                    .rechargeUserCount(Long.valueOf(amountM1[1]))
-                    .increase(new BigDecimal(amountM1[2]))
-                    .back(new BigDecimal(amountM1[3]))
-                    .multiples(new BigDecimal(amountM1[4]))
-                    .build());
-
-            String[] amountM2 = vo.getAmountM2().split("/");
-            vo.setAmountM2Trend(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(amountM2[0]))
-                    .rechargeUserCount(Long.valueOf(amountM2[1]))
-                    .increase(new BigDecimal(amountM2[2]))
-                    .back(new BigDecimal(amountM2[3]))
-                    .multiples(new BigDecimal(amountM2[4]))
-                    .build());
-
-            String[] amountM3 = vo.getAmountM3().split("/");
-            vo.setAmountM3Trend(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(amountM3[0]))
-                    .rechargeUserCount(Long.valueOf(amountM3[1]))
-                    .increase(new BigDecimal(amountM3[2]))
-                    .back(new BigDecimal(amountM3[3]))
-                    .multiples(new BigDecimal(amountM3[4]))
-                    .build());
-
-            String[] amountM6 = vo.getAmountM6().split("/");
-            vo.setAmountM6Trend(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(amountM6[0]))
-                    .rechargeUserCount(Long.valueOf(amountM6[1]))
-                    .increase(new BigDecimal(amountM6[2]))
-                    .back(new BigDecimal(amountM6[3]))
-                    .multiples(new BigDecimal(amountM6[4]))
-                    .build());
-
-            String[] amountSum = vo.getAmountSum().split("/");
-            vo.setAmountSumTrend(RechargeTrendVO.builder()
-                    .rechargeMoney(new BigDecimal(amountSum[0]))
-                    .rechargeUserCount(Long.valueOf(amountSum[1]))
-                    .increase(new BigDecimal(amountSum[2]))
-                    .back(new BigDecimal(amountSum[3]))
-                    .multiples(new BigDecimal(amountSum[4]))
-                    .build());
-
+            formatDayN(vo);
             return vo;
         }).collect(Collectors.toList());
 
@@ -648,6 +407,7 @@ public class GameDataServiceImpl implements IGameDataService {
 
     /**
      * 游戏总数据总计
+     *
      * @param dto 前端传递的查询参数
      * @return 返回给前端额数据
      */
@@ -743,6 +503,8 @@ public class GameDataServiceImpl implements IGameDataService {
                                         .userAmount(adsEverydayWater.getUserAmount())
                                         .userOrderBy(Integer.valueOf(adsEverydayWater.getUserOrderBy()))
                                         .userName(adsEverydayWater.getUserName())
+                                        .roleName(adsEverydayWater.getRoleName())
+                                        .serverName(adsEverydayWater.getServerName())
                                         .proportion(
                                                 item.getAmount().compareTo(BigDecimal.ZERO) == 0 ?
                                                         BigDecimal.ZERO :
@@ -1112,6 +874,26 @@ public class GameDataServiceImpl implements IGameDataService {
         }
     }
 
+    private void formatDayN(GameDataDayVO vo) {
+        if(CollectionUtils.isEmpty(dayNFieldMapList)) {
+            return;
+        }
+        dayNFieldMapList.forEach(dayNFieldMap -> {
+            try {
+                String[] temps = ((String) dayNFieldMap.getT1().get(vo)).split("/");
+                dayNFieldMap.getT2().set(vo, RechargeTrendVO.builder()
+                        .rechargeMoney(new BigDecimal(temps[0]))
+                        .rechargeUserCount(Long.valueOf(temps[1]))
+                        .increase(new BigDecimal(temps[2]))
+                        .back(new BigDecimal(temps[3]))
+                        .multiples(new BigDecimal(temps[4]))
+                        .build());
+            } catch (IllegalAccessException e) {
+                throw new RuntimeException(e);
+            }
+        });
+    }
+
     /**
      * 通过反射使用set方法 得到复充趋势的值
      *
@@ -1346,7 +1128,8 @@ public class GameDataServiceImpl implements IGameDataService {
                     buy_new_user_total_amount_num,
                     buy_new_user_total_amount,
                     buy_first_roi,
-                    buy_today_roi,
+                    buy_first_amount_rate,
+                    buy_today_amount_rate,
                     buy_new_user_rate,
                     buy_first_avg_amount,
                     buy_today_avg_amount,
@@ -1357,14 +1140,39 @@ public class GameDataServiceImpl implements IGameDataService {
                     buy_today_amount_arpu,
                     buy_amount_arpu,
                     buy_amount_d1,
+                    buy_amount_d2,
                     buy_amount_d3,
+                    buy_amount_d4,
                     buy_amount_d5,
+                    buy_amount_d6,
                     buy_amount_d7,
+                    buy_amount_d8,
+                    buy_amount_d9,
+                    buy_amount_d10,
+                    buy_amount_d11,
+                    buy_amount_d12,
+                    buy_amount_d13,
+                    buy_amount_d14,
                     buy_amount_d15,
+                    buy_amount_d16,
+                    buy_amount_d17,
+                    buy_amount_d18,
+                    buy_amount_d19,
+                    buy_amount_d20,
+                    buy_amount_d21,
+                    buy_amount_d22,
+                    buy_amount_d23,
+                    buy_amount_d24,
+                    buy_amount_d25,
+                    buy_amount_d26,
+                    buy_amount_d27,
+                    buy_amount_d28,
+                    buy_amount_d29,
                     buy_amount_m1,
                     buy_amount_m2,
                     buy_amount_m3,
                     buy_amount_m6,
+                    buy_amount_y1,
                     buy_amount_sum,
                         
                     nature_first_new_user_amount_count,
@@ -1380,7 +1188,8 @@ public class GameDataServiceImpl implements IGameDataService {
                     nature_new_user_total_amount_num,
                     nature_new_user_total_amount,
                     nature_first_roi,
-                    nature_today_roi,
+                    nature_first_amount_rate,
+                    nature_today_amount_rate,
                     nature_new_user_rate,
                     nature_first_avg_amount,
                     nature_today_avg_amount,
@@ -1391,14 +1200,39 @@ public class GameDataServiceImpl implements IGameDataService {
                     nature_today_amount_arpu,
                     nature_amount_arpu,
                     nature_amount_d1,
+                    nature_amount_d2,
                     nature_amount_d3,
+                    nature_amount_d4,
                     nature_amount_d5,
+                    nature_amount_d6,
                     nature_amount_d7,
+                    nature_amount_d8,
+                    nature_amount_d9,
+                    nature_amount_d10,
+                    nature_amount_d11,
+                    nature_amount_d12,
+                    nature_amount_d13,
+                    nature_amount_d14,
                     nature_amount_d15,
+                    nature_amount_d16,
+                    nature_amount_d17,
+                    nature_amount_d18,
+                    nature_amount_d19,
+                    nature_amount_d20,
+                    nature_amount_d21,
+                    nature_amount_d22,
+                    nature_amount_d23,
+                    nature_amount_d24,
+                    nature_amount_d25,
+                    nature_amount_d26,
+                    nature_amount_d27,
+                    nature_amount_d28,
+                    nature_amount_d29,
                     nature_amount_m1,
                     nature_amount_m2,
                     nature_amount_m3,
                     nature_amount_m6,
+                    nature_amount_y1,
                     nature_amount_sum,
                         
                     first_new_user_amount_count,
@@ -1414,7 +1248,8 @@ public class GameDataServiceImpl implements IGameDataService {
                     new_user_total_amount_num,
                     new_user_total_amount,
                     first_roi,
-                    today_roi,
+                    first_amount_rate,
+                    today_amount_rate,
                     new_user_rate,
                     first_avg_amount,
                     today_avg_amount,
@@ -1425,14 +1260,39 @@ public class GameDataServiceImpl implements IGameDataService {
                     today_amount_arpu,
                     amount_arpu,
                     amount_d1,
+                    amount_d2,
                     amount_d3,
+                    amount_d4,
                     amount_d5,
+                    amount_d6,
                     amount_d7,
+                    amount_d8,
+                    amount_d9,
+                    amount_d10,
+                    amount_d11,
+                    amount_d12,
+                    amount_d13,
+                    amount_d14,
                     amount_d15,
+                    amount_d16,
+                    amount_d17,
+                    amount_d18,
+                    amount_d19,
+                    amount_d20,
+                    amount_d21,
+                    amount_d22,
+                    amount_d23,
+                    amount_d24,
+                    amount_d25,
+                    amount_d26,
+                    amount_d27,
+                    amount_d28,
+                    amount_d29,
                     amount_m1,
                     amount_m2,
                     amount_m3,
                     amount_m6,
+                    amount_y1,
                     amount_sum
                     
                 FROM
@@ -1466,8 +1326,9 @@ public class GameDataServiceImpl implements IGameDataService {
                 SUM(buy_new_user_total_amount_count) buy_new_user_total_amount_count,
                 SUM(buy_new_user_total_amount_num) buy_new_user_total_amount_num,
                 SUM(buy_new_user_total_amount) buy_new_user_total_amount,
-                round(if(SUM(buy_reg_num) > 0 , SUM(buy_first_new_user_amount_num) / SUM(buy_reg_num) ,0), 4) buy_first_roi,
-                round(if(SUM(buy_reg_num) > 0, SUM(buy_new_user_total_amount_num) / SUM(buy_reg_num), 0) ,4) buy_today_roi,
+                round(if(SUM(cost) > 0 , SUM(buy_first_new_user_amount) / SUM(cost) ,0), 4) buy_first_roi,
+                round(if(SUM(buy_reg_num) > 0 , SUM(buy_first_new_user_amount_num) / SUM(buy_reg_num) ,0), 4) buy_first_amount_rate,
+                round(if(SUM(buy_reg_num) > 0, SUM(buy_new_user_total_amount_num) / SUM(buy_reg_num), 0) ,4) buy_today_amount_rate,
                 round(if(SUM(buy_amount_num) > 0 , SUM(buy_first_new_user_amount_num) / SUM(buy_amount_num) ,0), 4) buy_new_user_rate,
                 round(if(SUM(buy_first_new_user_amount_count) > 0, SUM(buy_first_new_user_amount) / SUM(buy_first_new_user_amount_count), 0), 2) buy_first_avg_amount,
                 round(if(SUM(buy_new_user_total_amount_count) > 0, SUM(buy_new_user_total_amount) / SUM(buy_new_user_total_amount_count), 0), 2) buy_today_avg_amount,
@@ -1490,8 +1351,9 @@ public class GameDataServiceImpl implements IGameDataService {
                 SUM(nature_new_user_total_amount_count) nature_new_user_total_amount_count,
                 SUM(nature_new_user_total_amount_num) nature_new_user_total_amount_num,
                 SUM(nature_new_user_total_amount) nature_new_user_total_amount,
-                round(if(SUM(nature_reg_num) > 0 , SUM(nature_first_new_user_amount_num) / SUM(nature_reg_num) ,0), 4) nature_first_roi,
-                round(if(SUM(nature_reg_num) > 0, SUM(nature_new_user_total_amount_num) / SUM(nature_reg_num), 0) ,4) nature_today_roi,
+                round(if(SUM(cost) > 0 , SUM(nature_first_new_user_amount) / SUM(cost) ,0), 4) nature_first_roi,
+                round(if(SUM(nature_reg_num) > 0 , SUM(nature_first_new_user_amount_num) / SUM(nature_reg_num) ,0), 4) nature_first_amount_rate,
+                round(if(SUM(nature_reg_num) > 0, SUM(nature_new_user_total_amount_num) / SUM(nature_reg_num), 0) ,4) nature_today_amount_rate,
                 round(if(SUM(nature_amount_num) > 0 , SUM(nature_first_new_user_amount_num) / SUM(nature_amount_num) ,0), 4) nature_new_user_rate,
                 round(if(SUM(nature_first_new_user_amount_count) > 0, SUM(nature_first_new_user_amount) / SUM(nature_first_new_user_amount_count), 0), 2) nature_first_avg_amount,
                 round(if(SUM(nature_new_user_total_amount_count) > 0, SUM(nature_new_user_total_amount) / SUM(nature_new_user_total_amount_count), 0), 2) nature_today_avg_amount,
@@ -1514,8 +1376,9 @@ public class GameDataServiceImpl implements IGameDataService {
                 SUM(new_user_total_amount_count) new_user_total_amount_count,
                 SUM(new_user_total_amount_num) new_user_total_amount_num,
                 SUM(new_user_total_amount) new_user_total_amount,
-                round(if(SUM(reg_num) > 0 , SUM(first_new_user_amount_num) / SUM(reg_num) ,0), 4) first_roi,
-                round(if(SUM(reg_num) > 0, SUM(new_user_total_amount_num) / SUM(reg_num), 0) ,4) today_roi,
+                round(if(SUM(cost) > 0 , SUM(first_new_user_amount) / SUM(cost) ,0), 4) first_roi,
+                round(if(SUM(reg_num) > 0 , SUM(first_new_user_amount_num) / SUM(reg_num) ,0), 4) first_amount_rate,
+                round(if(SUM(reg_num) > 0, SUM(new_user_total_amount_num) / SUM(reg_num), 0) ,4) today_amount_rate,
                 round(if(SUM(amount_num) > 0 , SUM(first_new_user_amount_num) / SUM(amount_num) ,0), 4) new_user_rate,
                 round(if(SUM(first_new_user_amount_count) > 0, SUM(first_new_user_amount) / SUM(first_new_user_amount_count), 0), 2) first_avg_amount,
                 round(if(SUM(new_user_total_amount_count) > 0, SUM(new_user_total_amount) / SUM(new_user_total_amount_count), 0), 2) today_avg_amount,
@@ -2226,6 +2089,8 @@ public class GameDataServiceImpl implements IGameDataService {
                 amount_order_by,
                 amount_post,
                 amount_count,
+                role_name,
+                server_name,
                 amount_num
                 from ads_everyday_water
                 """;

+ 3 - 39
game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/service/impl/OverallSummaryServiceImpl.java

@@ -15,18 +15,16 @@ import org.nutz.dao.Dao;
 import org.nutz.dao.Sqls;
 import org.nutz.dao.sql.Criteria;
 import org.nutz.dao.sql.Sql;
-import org.springframework.beans.BeanUtils;
-import org.springframework.beans.BeanWrapper;
-import org.springframework.beans.BeanWrapperImpl;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
 
-import java.beans.PropertyDescriptor;
 import java.math.BigDecimal;
 import java.math.RoundingMode;
 import java.time.LocalDate;
 import java.time.temporal.ChronoUnit;
-import java.util.*;
+import java.util.HashMap;
+import java.util.List;
+import java.util.Map;
 
 /**
  * @author tianhua
@@ -271,40 +269,6 @@ public class OverallSummaryServiceImpl implements IOverallSummaryService {
         return cri;
     }
 
-    /**
-     * 所有为空值的属性都不copy
-     *
-     * @param source 原数据
-     * @param target 目标数据
-     */
-    private void copyNullProperties(Object source, Object target) {
-        BeanUtils.copyProperties(source, target, getNullField(source));
-    }
-
-    /**
-     * 获取属性中为空的字段
-     *
-     * @param target 目标对象
-     * @return 不需要替换的字段数组
-     */
-    private static String[] getNullField(Object target) {
-        BeanWrapper beanWrapper = new BeanWrapperImpl(target);
-        PropertyDescriptor[] propertyDescriptors = beanWrapper.getPropertyDescriptors();
-        Set<String> notNullFieldSet = new HashSet<>();
-        if (propertyDescriptors.length > 0) {
-            for (PropertyDescriptor p : propertyDescriptors) {
-                String name = p.getName();
-                Object value = beanWrapper.getPropertyValue(name);
-                if (Objects.isNull(value)) {
-                    notNullFieldSet.add(name);
-                }
-            }
-        }
-        String[] notNullField = new String[notNullFieldSet.size()];
-
-        return notNullFieldSet.toArray(notNullField);
-    }
-
     /**
      * 检查查询的时间内是否都有数据,没有则赋值默认值0
      *

+ 518 - 21
game-data/game-data-serve/src/main/java/com/zanxiang/game/data/serve/service/impl/PromotionDayServiceImpl.java

@@ -1,9 +1,12 @@
 package com.zanxiang.game.data.serve.service.impl;
 
+import com.google.common.base.CaseFormat;
 import com.zanxiang.game.data.serve.pojo.dto.PromotionDayDTO;
 import com.zanxiang.game.data.serve.pojo.dto.PromotionDayTotalDTO;
+import com.zanxiang.game.data.serve.pojo.enums.OrderByEnum;
 import com.zanxiang.game.data.serve.pojo.vo.PromotionDayTotalVO;
 import com.zanxiang.game.data.serve.pojo.vo.PromotionDayVO;
+import com.zanxiang.game.data.serve.pojo.vo.PromotionRechargeTrendVO;
 import com.zanxiang.game.data.serve.service.IAdsPromotionDayService;
 import com.zanxiang.game.data.serve.utils.Page;
 import lombok.extern.slf4j.Slf4j;
@@ -15,11 +18,21 @@ import org.nutz.dao.pager.Pager;
 import org.nutz.dao.sql.Criteria;
 import org.nutz.dao.sql.Sql;
 import org.nutz.dao.util.Daos;
+import org.springframework.beans.BeanUtils;
+import org.springframework.beans.BeanWrapper;
+import org.springframework.beans.BeanWrapperImpl;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
 
+import java.beans.PropertyDescriptor;
+import java.math.BigDecimal;
+import java.math.RoundingMode;
 import java.time.LocalDate;
+import java.util.HashSet;
 import java.util.List;
+import java.util.Objects;
+import java.util.Set;
+import java.util.stream.Collectors;
 
 /**
  * @author tianhua
@@ -35,11 +48,304 @@ public class PromotionDayServiceImpl implements IAdsPromotionDayService {
 
     @Override
     public Page<PromotionDayVO> getPromotionDayData(PromotionDayDTO dto) {
+        //不传递查询条件默认查询当天数据
+        if (dto.getCostBeginDate() == null || dto.getCostEndDate() == null) {
+            dto.setCostBeginDate(LocalDate.now());
+            dto.setCostEndDate(LocalDate.now());
+        }
+        //如果没有排序条件给默认值
+        if (StringUtils.isBlank(dto.getSortFiled())) {
+            dto.setSortFiled("today_cost");
+        }
+        if (StringUtils.isBlank(dto.getSortType())) {
+            dto.setSortType(OrderByEnum.DESC.getOrderType());
+        }
+        Criteria cri = myCri(dto);
+        //创建sql语句
+        Sql sql = Sqls.create(getPromotionDayDataSql() + cri);
+        //添加自定义回传对象
+        sql.setCallback(Sqls.callback.entities());
+        sql.setEntity(dao.getEntity(PromotionDayVO.class));
+        //设置pager对象
+        Pager pager = dao.createPager(dto.getPageNum(), dto.getPageSize());
+        sql.setPager(pager);
+        //执行sql
+        dao.execute(sql);
+        //获取到结果list
+        List<PromotionDayVO> list = sql.getList(PromotionDayVO.class);
+        //分页对象设置总条数
+        Sql sqlCount = Sqls.queryEntity("select count(*) from ads_promotion_day" + cri);
+        pager.setRecordCount((int) Daos.queryCount(dao, sqlCount));
+
+        //处理List中的每个vo对象缺少的数据
+        list.stream().map(vo ->{
+                    //记录最近有数据的LocalDate
+                    LocalDate latestDate = dto.getCostEndDate();
+                    Boolean hasDataDate = findDate(vo.getPromotionId(), latestDate);
+                    while (!hasDataDate) {
+                        latestDate = latestDate.minusDays(1);
+                        hasDataDate = findDate(vo.getPromotionId(), latestDate);
+                    }
+                    //构建查询条件
+                    Criteria totalCri = Cnd.cri();
+                    totalCri.where().andEquals("dt", latestDate);
+                    totalCri.where().andEquals("promotion_id", vo.getPromotionId());
+                    //查询出最近一条包含总数据的记录
+                    Sql totalDataSql = Sqls.create(getTotalDataSql() + totalCri);
+                    //设置回传对象
+                    totalDataSql.setCallback(Sqls.callback.entity());
+                    totalDataSql.setEntity(dao.getEntity(PromotionDayVO.class));
+                    //执行sql
+                    dao.execute(totalDataSql);
+                    //得到对象
+                    PromotionDayVO tempVO = totalDataSql.getObject(PromotionDayVO.class);
+                    //将两个对象内容合并
+                    copyNullProperties(tempVO, vo);
+
+                    //计算d2(次日)数据
+                    vo.setD2Trend(PromotionRechargeTrendVO.builder()
+                            .roi(vo.getTodayCost().compareTo(BigDecimal.ZERO) == 0 ? BigDecimal.ZERO :
+                                    vo.getD2().divide(vo.getTodayCost(), 4, RoundingMode.HALF_UP))
+                            .rechargeMoney(vo.getD2())
+                            .multiples(vo.getD1().compareTo(BigDecimal.ZERO) == 0 ? BigDecimal.ZERO :
+                                    vo.getD2().divide(vo.getD1(), 4, RoundingMode.HALF_UP))
+                            .build());
+                    //计算d3数据
+                    vo.setD3Trend(PromotionRechargeTrendVO.builder()
+                            .roi(vo.getTodayCost().compareTo(BigDecimal.ZERO) == 0 ? BigDecimal.ZERO :
+                                    vo.getD3().divide(vo.getTodayCost(), 4, RoundingMode.HALF_UP))
+                            .rechargeMoney(vo.getD3())
+                            .multiples(vo.getD1().compareTo(BigDecimal.ZERO) == 0 ? BigDecimal.ZERO :
+                                    vo.getD3().divide(vo.getD1(), 4, RoundingMode.HALF_UP))
+                            .build());
+                    //计算d7数据
+                    vo.setD7Trend(PromotionRechargeTrendVO.builder()
+                            .roi(vo.getTodayCost().compareTo(BigDecimal.ZERO) == 0 ? BigDecimal.ZERO :
+                                    vo.getD7().divide(vo.getTodayCost(), 4, RoundingMode.HALF_UP))
+                            .rechargeMoney(vo.getD7())
+                            .multiples(vo.getD1().compareTo(BigDecimal.ZERO) == 0 ? BigDecimal.ZERO :
+                                    vo.getD7().divide(vo.getD1(), 4, RoundingMode.HALF_UP))
+                            .build());
+                    //计算d15数据
+                    vo.setD15Trend(PromotionRechargeTrendVO.builder()
+                            .roi(vo.getTodayCost().compareTo(BigDecimal.ZERO) == 0 ? BigDecimal.ZERO :
+                                    vo.getD15().divide(vo.getTodayCost(), 4, RoundingMode.HALF_UP))
+                            .rechargeMoney(vo.getD15())
+                            .multiples(vo.getD1().compareTo(BigDecimal.ZERO) == 0 ? BigDecimal.ZERO :
+                                    vo.getD15().divide(vo.getD1(), 4, RoundingMode.HALF_UP))
+                            .build());
+
+                    //返回最终数据
+                    return vo;
+                }).collect(Collectors.toList());
+
+        //返回查询得结果
+        return new Page<>(list, pager);
+    }
+
+    /**
+     * 广告监控数据总计一栏
+     *
+     * @param dto
+     * @return
+     */
+    @Override
+    public PromotionDayTotalVO getPromotionDayTotalData(PromotionDayTotalDTO dto) {
         //不传递查询条件默认查询当天数据
         if (dto.getCostBeginDate() == null || dto.getCostEndDate() == null) {
             dto.setCostBeginDate(LocalDate.now());
             dto.setCostEndDate(LocalDate.now());
         }
+        //创建查询条件
+        Criteria cri = Cnd.cri();
+        if (dto.getAccountId() != null) {
+            //拼接推广账号Id查询条件
+            cri.where().andEquals("account_id", dto.getAccountId());
+        }
+        if (StringUtils.isNotBlank(dto.getAccountName())) {
+            //拼接推广账号名称查询条件
+            cri.where().andEquals("account_name", dto.getAccountName());
+        }
+        if (StringUtils.isNotBlank(dto.getAccountType())) {
+            //推广账号类型
+            cri.where().andEquals("account_type", dto.getAccountType());
+        }
+        if (dto.getPitcherId() != null) {
+            cri.where().andEquals("pitcher_id", dto.getPitcherId());
+        }
+        if (StringUtils.isNotBlank(dto.getPitcherName())) {
+            cri.where().andEquals("pitcher_name", dto.getPitcherName());
+        }
+        if (dto.getAgentId() != null) {
+            cri.where().andEquals("agent_id", dto.getAgentId());
+        }
+        if (StringUtils.isNotBlank(dto.getAgentKey())) {
+            cri.where().andEquals("agent_key", dto.getAgentKey());
+        }
+        if (StringUtils.isNotBlank(dto.getAgentName())) {
+            cri.where().andEquals("agent_name", dto.getAgentName());
+        }
+        if (StringUtils.isNotBlank(dto.getCpName())) {
+            cri.where().andEquals("cp_name", dto.getCpName());
+        }
+        if (StringUtils.isNotBlank(dto.getGameName())) {
+            cri.where().andEquals("game_name", dto.getGameName());
+        }
+        if (dto.getGameId() != null) {
+            cri.where().andEquals("game_id", dto.getGameId());
+        }
+        if (dto.getClassify() != null) {
+            cri.where().andEquals("classify", dto.getClassify());
+        }
+        if (StringUtils.isNotBlank(dto.getPromotionName())) {
+            cri.where().andEquals("promotion_name", dto.getPromotionName());
+        }
+        if (dto.getPromotionId() != null) {
+            cri.where().andEquals("promotion_id", dto.getPromotionId());
+        }
+        if (StringUtils.isNotBlank(dto.getStatus())) {
+            cri.where().andEquals("status", dto.getStatus());
+        }
+        if (StringUtils.isNotBlank(dto.getProjectName())) {
+            cri.where().andEquals("project_name", dto.getProjectName());
+        }
+        if (dto.getProjectId() != null) {
+            cri.where().andEquals("project_id", dto.getProjectId());
+        }
+        if (dto.getCostBeginDate() != null && dto.getCostEndDate() != null) {
+            cri.where().andBetween("dt", dto.getCostBeginDate(), dto.getCostEndDate());
+        }
+        if (StringUtils.isNotBlank(dto.getSourceSystem())) {
+            cri.where().andEquals("source_system", dto.getSourceSystem());
+        }
+        //创建sql
+        Sql promotionDayTotalSql = Sqls.create(promotionDayTotalSql() + cri);
+        //设置回传对象
+        promotionDayTotalSql.setCallback(Sqls.callback.entity());
+        promotionDayTotalSql.setEntity(dao.getEntity(PromotionDayTotalVO.class));
+        //执行sql
+        dao.execute(promotionDayTotalSql);
+        //得到结果
+        PromotionDayTotalVO vo = promotionDayTotalSql.getObject(PromotionDayTotalVO.class);
+
+        //计算总数据要根据promotionId分组
+        Criteria totalCri = cri;
+        totalCri.getGroupBy().groupBy("promotion_id");
+        //构建sql
+        Sql tempSql = Sqls.create(promotionDayTotalTotalDataTempSql() + totalCri);
+        Sql totalSumSql = Sqls.create(promotionDayTotalTotalDataSumSql() + "(" + tempSql + ") a");
+        //设置回传对象
+        totalSumSql.setCallback(Sqls.callback.entity());
+        totalSumSql.setEntity(dao.getEntity(PromotionDayTotalVO.class));
+        //执行sql
+        dao.execute(totalSumSql);
+        PromotionDayTotalVO tempVO = totalSumSql.getObject(PromotionDayTotalVO.class);
+        //将取到的值赋值vo
+        copyNullProperties(tempVO, vo);
+
+        //如果没有tempVO,返回默认值0
+        if (tempVO.getPromotionTotalCost() == null) {
+            //计算总数据
+            //总注册成本
+            vo.setRegTotalCost(BigDecimal.ZERO);
+            //总创角成本
+            vo.setRoleTotalCost(BigDecimal.ZERO);
+            //总创角率
+            vo.setRoleTotalRate(BigDecimal.ZERO);
+            //广告总ROI
+            vo.setPromotionTotalRoi(BigDecimal.ZERO);
+            //总付费成本
+            vo.setTotalRechargeCost(BigDecimal.ZERO);
+            //计算d2,d3,d7,d15数据
+            //计算d2(次日)数据
+            vo.setD2Trend(PromotionRechargeTrendVO.builder()
+                    .roi(BigDecimal.ZERO)
+                    .rechargeMoney(BigDecimal.ZERO)
+                    .multiples(BigDecimal.ZERO)
+                    .build());
+            //计算d3数据
+            vo.setD3Trend(PromotionRechargeTrendVO.builder()
+                    .roi(BigDecimal.ZERO)
+                    .rechargeMoney(BigDecimal.ZERO)
+                    .multiples(BigDecimal.ZERO)
+                    .build());
+            //计算d7数据
+            vo.setD7Trend(PromotionRechargeTrendVO.builder()
+                    .roi(BigDecimal.ZERO)
+                    .rechargeMoney(BigDecimal.ZERO)
+                    .multiples(BigDecimal.ZERO)
+                    .build());
+            //计算d15数据
+            vo.setD15Trend(PromotionRechargeTrendVO.builder()
+                    .roi(BigDecimal.ZERO)
+                    .rechargeMoney(BigDecimal.ZERO)
+                    .multiples(BigDecimal.ZERO)
+                    .build());
+
+            return vo;
+        }
+
+        //计算总数据
+        //总注册成本
+        vo.setRegTotalCost(vo.getRegTotalNum() == 0L ? BigDecimal.ZERO :
+                vo.getPromotionTotalCost().divide(BigDecimal.valueOf(vo.getRegTotalNum()), 2, RoundingMode.HALF_UP));
+        //总创角成本
+        vo.setRoleTotalCost(vo.getRoleTotalNum() == 0L ? BigDecimal.ZERO :
+                vo.getPromotionTotalCost().divide(BigDecimal.valueOf(vo.getRoleTotalNum()), 2, RoundingMode.HALF_UP));
+        //总创角率
+        vo.setRoleTotalRate(vo.getRegTotalNum() == 0L ? BigDecimal.ZERO :
+                BigDecimal.valueOf(vo.getRoleTotalNum()).divide(BigDecimal.valueOf(vo.getRegTotalNum()), 4, RoundingMode.HALF_UP));
+        //广告总ROI
+        vo.setPromotionTotalRoi(vo.getPromotionTotalCost().compareTo(BigDecimal.ZERO) == 0 ? BigDecimal.ZERO :
+                vo.getTotalAmount().divide(vo.getPromotionTotalCost(), 4, RoundingMode.HALF_UP));
+        //总付费成本
+        vo.setTotalRechargeCost(vo.getTotalAmountNum() == 0L ? BigDecimal.ZERO :
+                vo.getPromotionTotalCost().divide(BigDecimal.valueOf(vo.getTotalAmountNum()), 2, RoundingMode.HALF_UP));
+
+        //计算d2,d3,d7,d15数据
+        //计算d2(次日)数据
+        vo.setD2Trend(PromotionRechargeTrendVO.builder()
+                .roi(vo.getTodayCost().compareTo(BigDecimal.ZERO) == 0 ? BigDecimal.ZERO :
+                        vo.getD2().divide(vo.getTodayCost(), 4, RoundingMode.HALF_UP))
+                .rechargeMoney(vo.getD2())
+                .multiples(vo.getD1().compareTo(BigDecimal.ZERO) == 0 ? BigDecimal.ZERO :
+                        vo.getD2().divide(vo.getD1(), 4, RoundingMode.HALF_UP))
+                .build());
+        //计算d3数据
+        vo.setD3Trend(PromotionRechargeTrendVO.builder()
+                .roi(vo.getTodayCost().compareTo(BigDecimal.ZERO) == 0 ? BigDecimal.ZERO :
+                        vo.getD3().divide(vo.getTodayCost(), 4, RoundingMode.HALF_UP))
+                .rechargeMoney(vo.getD3())
+                .multiples(vo.getD1().compareTo(BigDecimal.ZERO) == 0 ? BigDecimal.ZERO :
+                        vo.getD3().divide(vo.getD1(), 4, RoundingMode.HALF_UP))
+                .build());
+        //计算d7数据
+        vo.setD7Trend(PromotionRechargeTrendVO.builder()
+                .roi(vo.getTodayCost().compareTo(BigDecimal.ZERO) == 0 ? BigDecimal.ZERO :
+                        vo.getD7().divide(vo.getTodayCost(), 4, RoundingMode.HALF_UP))
+                .rechargeMoney(vo.getD7())
+                .multiples(vo.getD1().compareTo(BigDecimal.ZERO) == 0 ? BigDecimal.ZERO :
+                        vo.getD7().divide(vo.getD1(), 4, RoundingMode.HALF_UP))
+                .build());
+        //计算d15数据
+        vo.setD15Trend(PromotionRechargeTrendVO.builder()
+                .roi(vo.getTodayCost().compareTo(BigDecimal.ZERO) == 0 ? BigDecimal.ZERO :
+                        vo.getD15().divide(vo.getTodayCost(), 4, RoundingMode.HALF_UP))
+                .rechargeMoney(vo.getD15())
+                .multiples(vo.getD1().compareTo(BigDecimal.ZERO) == 0 ? BigDecimal.ZERO :
+                        vo.getD15().divide(vo.getD1(), 4, RoundingMode.HALF_UP))
+                .build());
+
+        return vo;
+    }
+
+    /**
+     * 广告监控用到的查询条件
+     *
+     * @param dto 前端传递的查询条件
+     * @return 查询条件
+     */
+    private Criteria myCri(PromotionDayDTO dto) {
         //创建查询条件
         Criteria cri = Cnd.cri();
         if (dto.getAccountId() != null) {
@@ -104,29 +410,79 @@ public class PromotionDayServiceImpl implements IAdsPromotionDayService {
         }
         //拼接分组条件
         cri.getGroupBy().groupBy("promotion_id");
-        //创建sql语句
-        Sql sql = Sqls.create(getPromotionDayDataSql() + cri );
-        //添加自定义回传对象
-        sql.setCallback(Sqls.callback.entities());
-        sql.setEntity(dao.getEntity(PromotionDayVO.class));
-        //设置pager对象
-        Pager pager = dao.createPager(dto.getPageNum(), dto.getPageSize());
-        sql.setPager(pager);
-        //执行sql
+        //拼接排序条件
+        cri.getOrderBy().orderBy(CaseFormat.LOWER_CAMEL.to(CaseFormat.LOWER_UNDERSCORE, dto.getSortFiled()), dto.getSortType());
+
+
+        return cri;
+    }
+
+    /**
+     * 用来判断当前日期有没有数据
+     *
+     * @param promotionId 查询的广告id
+     * @param latestDate  时间参数
+     * @return Boolean
+     */
+    private Boolean findDate(String promotionId, LocalDate latestDate) {
+        //创建查询条件
+        Criteria cri = Cnd.cri();
+        cri.where().andEquals("promotion_id", Long.valueOf(promotionId));
+        cri.where().andEquals("dt", latestDate);
+        Sql sql = Sqls.create("""
+                SELECT
+                    promotion_id
+                FROM
+                    game_ads.ads_promotion_day
+                """ + cri);
+        sql.setCallback(Sqls.callback.str());
         dao.execute(sql);
-        //获取到结果list
-        List<PromotionDayVO> list = sql.getList(PromotionDayVO.class);
-        //分页对象设置总条数
-        Sql sqlCount = Sqls.queryEntity("select count(*) from ads_promotion_day" + cri);
-        pager.setRecordCount((int) Daos.queryCount(dao, sqlCount));
+        String tempStr = sql.getString();
+        //查询结果判断
+        if (tempStr != null) {
+            return true;
+        }
+        return false;
+    }
 
-        //返回查询得结果
-        return new Page<>(list,pager);
+    /**
+     * 所有为空值的属性都不copy
+     *
+     * @param source 原数据
+     * @param target 目标数据
+     */
+    private void copyNullProperties(Object source, Object target) {
+        BeanUtils.copyProperties(source, target, getNullField(source));
     }
 
     /**
-     * 查询广告监控数据
-     * @return
+     * 获取属性中为空的字段
+     *
+     * @param target 目标对象
+     * @return 不需要替换的字段数组
+     */
+    private static String[] getNullField(Object target) {
+        BeanWrapper beanWrapper = new BeanWrapperImpl(target);
+        PropertyDescriptor[] propertyDescriptors = beanWrapper.getPropertyDescriptors();
+        Set<String> notNullFieldSet = new HashSet<>();
+        if (propertyDescriptors.length > 0) {
+            for (PropertyDescriptor p : propertyDescriptors) {
+                String name = p.getName();
+                Object value = beanWrapper.getPropertyValue(name);
+                if (Objects.isNull(value)) {
+                    notNullFieldSet.add(name);
+                }
+            }
+        }
+        String[] notNullField = new String[notNullFieldSet.size()];
+
+        return notNullFieldSet.toArray(notNullField);
+    }
+
+    /**
+     * 查询广告监控数据sql
+     *
+     * @return String
      */
     private String getPromotionDayDataSql() {
         return """
@@ -201,6 +557,7 @@ public class PromotionDayServiceImpl implements IAdsPromotionDayService {
                 	round(if(SUM(reg_num) > 0, SUM(first_new_user_amount_num) / SUM(reg_num), 0), 4) as first_amount_rate,
                 	round(if(SUM(first_new_user_amount_count) > 0, SUM(first_new_user_amount) / SUM(first_new_user_amount_count), 0), 2) as first_new_user_avg_price,
                 	round(if(SUM(new_user_total_amount_count) > 0, SUM(new_user_total_amount) / SUM(new_user_total_amount_count), 0), 2) as new_user_total_avg_price,
+                	SUM(d1) as d1,
                 	SUM(d2) as d2,
                 	SUM(d3) as d3,
                 	SUM(d7) as d7,
@@ -210,8 +567,148 @@ public class PromotionDayServiceImpl implements IAdsPromotionDayService {
                 """;
     }
 
-    @Override
-    public PromotionDayTotalVO getPromotionDayTotalData(PromotionDayTotalDTO dto) {
-        return null;
+    /**
+     * 查询广告每日里总数据sql
+     *
+     * @return String
+     */
+    private String getTotalDataSql() {
+        return """
+                SELECT
+                    status,
+                    creative_preview,
+                    landing_type,
+                    pricing,
+                    cpa_bid,
+                    roi_goal,
+                    budget,
+                    schedule_time,
+                    notes,
+                    service,
+                    balance,
+                    promotion_total_cost,
+                    convert_target,
+                    reg_total_num,
+                    role_total_num,
+                    reg_total_cost,
+                    role_total_cost,
+                    role_total_rate,
+                    total_amount_count,
+                    total_amount_num,
+                    total_amount,
+                    promotion_total_roi,
+                    total_recharge_cost
+                FROM
+                    game_ads.ads_promotion_day
+                """;
+    }
+
+    /**
+     * 查询广告监控每日总计一栏sql
+     *
+     * @return String
+     */
+    private String promotionDayTotalSql() {
+        return """
+                SELECT
+                    IFNULL(SUM(today_cost), 0) as today_cost,
+                	IFNULL(SUM(show_count), 0) as show_count,
+                	round(if(SUM(show_count) > 0, SUM(today_cost) / SUM(show_count), 0), 2) as thousand_display_price,
+                	IFNULL(SUM(click_count), 0) as click_count,
+                	round(if(SUM(click_count) > 0, SUM(today_cost) / SUM(click_count), 0), 2) as avg_click_cost,
+                	round(if(SUM(show_count) > 0, SUM(click_count) / SUM(show_count), 0), 4) as ctr,
+                	IFNULL(SUM(convert_count), 0) as convert_count,
+                	IFNULL(SUM(convert_cost), 0) as convert_cost,
+                	round(if(SUM(click_count) > 0, SUM(convert_count) / SUM(click_count), 0), 4) as convert_rate,
+                	IFNULL(SUM(reg_num), 0) as reg_num,
+                	IFNULL(SUM(first_role_num), 0) as first_role_num,
+                	IFNULL(SUM(new_user_total_role_num), 0) as new_user_total_role_num,
+                	round(if(SUM(reg_num) > 0, SUM(today_cost) / SUM(reg_num), 0), 2) as reg_cost,
+                	round(if(SUM(first_role_num) > 0, SUM(today_cost) / SUM(first_role_num), 0), 2) as first_role_cost,
+                	round(if(SUM(new_user_total_role_num) > 0, SUM(today_cost) / SUM(new_user_total_role_num), 0), 2) as new_user_total_role_cost,
+                	round(if(SUM(reg_num) > 0, SUM(first_role_num) / SUM(reg_num), 0), 4) as first_role_rate,
+                	round(if(SUM(reg_num) > 0, SUM(new_user_total_role_num) / SUM(reg_num), 0), 4) as new_user_total_role_rate,
+                	IFNULL(SUM(first_new_user_amount_count), 0) as first_new_user_amount_count,
+                	IFNULL(SUM(first_new_user_amount_num), 0) as first_new_user_amount_num,
+                	IFNULL(SUM(first_new_user_amount), 0) as first_new_user_amount,
+                	IFNULL(SUM(new_user_total_amount_count), 0) as new_user_total_amount_count,
+                	IFNULL(SUM(new_user_total_amount_num), 0) as new_user_total_amount_num,
+                	IFNULL(SUM(new_user_total_amount), 0) as new_user_total_amount,
+                	round(if(SUM(today_cost) > 0, SUM(first_new_user_amount) / SUM(today_cost), 0), 4) as first_roi,
+                	IFNULL(SUM(twenty_four_hours_amount), 0) as twenty_four_hours_amount,
+                	round(if(SUM(today_cost) > 0, SUM(twenty_four_hours_amount) / SUM(today_cost), 0), 4) as twenty_four_hours_roi,
+                	round(if(SUM(today_cost) > 0, SUM(new_user_total_amount) / SUM(today_cost), 0), 4) as total_roi,
+                	round(if(SUM(first_new_user_amount_num) > 0, SUM(today_cost) / SUM(first_new_user_amount_num), 0), 2) as first_new_user_recharge_cost,
+                	round(if(SUM(new_user_total_amount_num) > 0, SUM(today_cost) / SUM(new_user_total_amount_num), 0), 2) as new_user_total_recharge_cost,
+                	round(if(SUM(first_new_user_amount_num) > 0, SUM(first_new_user_amount) / SUM(first_new_user_amount_num), 0), 2) as first_new_user_arppu,
+                	round(if(SUM(new_user_total_amount_num) > 0, SUM(new_user_total_amount) / SUM(new_user_total_amount_num), 0), 2) as new_user_total_amount_arppu,
+                	IFNULL(SUM(first_new_user_hundred_user_num), 0) as first_new_user_hundred_user_num,
+                	round(if(SUM(first_new_user_hundred_user_num) > 0, SUM(today_cost) / SUM(first_new_user_hundred_user_num), 0), 2) as first_new_user_hundred_user_cost,
+                	IFNULL(SUM(first_recharge_fifty_hundred_num), 0) as first_recharge_fifty_hundred_num,
+                	round(if(SUM(new_user_total_amount_num) > 0, SUM(first_recharge_fifty_hundred_num) / SUM(new_user_total_amount_num), 0), 4) as first_recharge_fifty_hundred_rate,
+                	IFNULL(SUM(first_new_user_two_hundred_user_num), 0) as first_new_user_two_hundred_user_num,
+                	round(if(SUM(first_new_user_two_hundred_user_num) > 0, SUM(today_cost) / SUM(first_new_user_two_hundred_user_num), 0), 2) as first_new_user_two_hundred_user_cost,
+                	IFNULL(SUM(new_user_total_hundred_user_num), 0) as new_user_total_hundred_user_num,
+                	round(if(SUM(new_user_total_hundred_user_num) > 0, SUM(today_cost) / SUM(new_user_total_hundred_user_num), 0), 2) as new_user_total_hundred_user_cost,
+                	IFNULL(SUM(first_ios_amount_num), 0) as first_ios_amount_num,
+                	IFNULL(SUM(first_ios_amount_count), 0) as first_ios_amount_count,
+                	IFNULL(SUM(first_ios_amount), 0) as first_ios_amount,
+                	round(if(SUM(first_new_user_amount_num) > 0, SUM(first_ios_amount_num) / SUM(first_new_user_amount_num), 0), 4) as first_ios_amount_num_rate,
+                	round(if(SUM(first_new_user_amount) > 0, SUM(first_ios_amount) / SUM(first_new_user_amount), 0), 4) as first_ios_amount_rate,
+                	round(if(SUM(today_cost)> 0, SUM(first_ios_amount) / SUM(today_cost), 0), 4) as first_ios_amount_roi,
+                	IFNULL(SUM(first_android_amount_count), 0) as first_android_amount_count,
+                	IFNULL(SUM(first_android_amount_num), 0) as first_android_amount_num,
+                	IFNULL(SUM(first_android_amount), 0) as first_android_amount,
+                	round(if(SUM(first_new_user_amount_num) > 0,SUM(first_android_amount_num) / SUM(first_new_user_amount_num), 0), 4) as first_android_amount_num_rate,
+                	round(if(SUM(first_new_user_amount) > 0, SUM(first_android_amount) / SUM(first_new_user_amount), 0), 4) as first_android_amount_rate,
+                	round(if(SUM(today_cost) > 0, SUM(first_android_amount) / SUM(today_cost), 0), 4) as first_android_amount_roi,
+                	round(if(SUM(reg_num) > 0, SUM(first_new_user_amount_num) / SUM(reg_num), 0), 4) as first_amount_rate,
+                	round(if(SUM(first_new_user_amount_count) > 0, SUM(first_new_user_amount) / SUM(first_new_user_amount_count), 0), 2) as first_new_user_avg_price,
+                	round(if(SUM(new_user_total_amount_count) > 0, SUM(new_user_total_amount) / SUM(new_user_total_amount_count), 0), 2) as new_user_total_avg_price,
+                	IFNULL(SUM(d1), 0) as d1,
+                	IFNULL(SUM(d2), 0) as d2,
+                	IFNULL(SUM(d3), 0) as d3,
+                	IFNULL(SUM(d7), 0) as d7,
+                	IFNULL(SUM(d15), 0) as d15
+                FROM
+                	game_ads.ads_promotion_day
+                """;
+    }
+
+    /**
+     * 用来查询出总计一栏的总数据sql
+     *
+     * @return String
+     */
+    private String promotionDayTotalTotalDataTempSql() {
+        return """
+                SELECT
+                    MAX(promotion_total_cost) promotion_total_cost,
+                    MAX(reg_total_num) reg_total_num,
+                    MAX(role_total_num) role_total_num,
+                    MAX(total_amount_count) total_amount_count,
+                    MAX(total_amount_num) total_amount_num,
+                    MAX(total_amount) total_amount
+                FROM
+                    game_ads.ads_promotion_day
+                """;
+    }
+
+    /**
+     * 得到计算后的总数据
+     *
+     * @return String
+     */
+    private String promotionDayTotalTotalDataSumSql() {
+        return """
+                SELECT
+                    IFNULL(SUM(promotion_total_cost), 0) promotion_total_cost,
+                    IFNULL(SUM(reg_total_num), 0) reg_total_num,
+                    IFNULL(SUM(role_total_num), 0) role_total_num,
+                    IFNULL(SUM(total_amount_count), 0) total_amount_count,
+                    IFNULL(SUM(total_amount_num), 0) total_amount_num,
+                    IFNULL(SUM(total_amount), 0) total_amount
+                FROM
+                """;
     }
 }

+ 1 - 1
game-module/game-module-sdk/src/main/java/com/zanxiang/game/module/sdk/SDKApplication.java

@@ -23,7 +23,7 @@ public class SDKApplication {
 
     public static void main(String[] args) {
         SpringApplication.run(SDKApplication.class, args);
-        System.out.println("赞象SDK服务启动成功 <dubbo升级3.0, APP下载地址访问上报修改> ( ´・・)ノ(._.`) \n" +
+        System.out.println("赞象SDK服务启动成功 <dubbo升级3.0, 解决前端没有checkSession的问题> ( ´・・)ノ(._.`) \n" +
                 " ___________ _   __\n" +
                 "/  ___|  _  \\ | / /\n" +
                 "\\ `--.| | | | |/ / \n" +

+ 10 - 0
game-module/game-module-sdk/src/main/java/com/zanxiang/game/module/sdk/service/impl/UserTokenServiceImpl.java

@@ -3,7 +3,9 @@ package com.zanxiang.game.module.sdk.service.impl;
 import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
 import com.zanxiang.game.module.base.pojo.enums.BanStatusEnum;
+import com.zanxiang.game.module.base.pojo.enums.GameCategoryEnum;
 import com.zanxiang.game.module.base.util.DateUtils;
+import com.zanxiang.game.module.mybatis.entity.Game;
 import com.zanxiang.game.module.mybatis.entity.GameExt;
 import com.zanxiang.game.module.mybatis.entity.User;
 import com.zanxiang.game.module.mybatis.entity.UserToken;
@@ -55,6 +57,9 @@ public class UserTokenServiceImpl extends ServiceImpl<UserTokenMapper, UserToken
     @Autowired
     private IUserLoginLogService userLoginLogService;
 
+    @Autowired
+    private IGameService gameService;
+
     @Override
     public ResultVO<Long> cpTokenCheck(String appId, Long userId, String token, String sign) {
         //查询登录签名
@@ -100,6 +105,11 @@ public class UserTokenServiceImpl extends ServiceImpl<UserTokenMapper, UserToken
     @Override
     public Boolean userTokenExpireTimeCheck(UserData userData) {
         log.error("缓存token验证请求 userData : {}", JsonUtil.toString(userData));
+        //微信小游戏, 解决前端没有checkSession的问题, 临时方案, 每次都重新登录
+        Game game = gameService.getById(userData.getGameId());
+        if (game == null || Objects.equals(game.getCategory(), GameCategoryEnum.CATEGORY_WX_APPLET.getId())) {
+            return Boolean.FALSE;
+        }
         //判断是否存在用户id或者token是否存在
         if (userData.getUserId() == null || Strings.isBlank(userData.getToken())) {
             return Boolean.FALSE;