瀏覽代碼

素材标签逻辑

syh 4 年之前
父節點
當前提交
ace35e3da5
共有 19 個文件被更改,包括 1759 次插入129 次删除
  1. 154 4
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/ctop/controller/AdvertiserController.java
  2. 1 1
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/ctop/controller/ProjectMemberController.java
  3. 5 1
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/ctop/controller/TagInfoController.java
  4. 1 1
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/ctop/service/IAdvertiserService.java
  5. 1 1
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/ctop/service/impl/AdvertiserServiceImpl.java
  6. 299 0
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/excelutil/entity/EffecfReportAccountEntity.java
  7. 302 0
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/excelutil/entity/EffecfReportCreativeEntity.java
  8. 299 0
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/excelutil/entity/EffecfReportGroupEntity.java
  9. 299 0
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/excelutil/entity/EffecfReportPlanEntity.java
  10. 312 0
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/excelutil/entity/EffecfReportProjectEntity.java
  11. 5 4
      jeecg-boot-module-system/src/test/java/org/jeecg/SampleTest.java
  12. 1 1
      module-common/src/main/java/cn/com/ctop/common/module/service/ITagInfoService.java
  13. 4 6
      module-common/src/main/java/cn/com/ctop/common/module/service/impl/TagInfoServiceImpl.java
  14. 1 1
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/ctop/vo/SheetInfoVo.java
  15. 0 3
      module-crawler/src/main/java/cn/com/ctop/crawler/modules/core/service/impl/KuaishouCrawlerServiceImpl.java
  16. 6 17
      module-kuaishou/src/main/java/cn/com/ctop/kuaishou/modules/batch/controller/KuaiShouController.java
  17. 10 3
      module-kuaishou/src/main/java/cn/com/ctop/kuaishou/modules/report/entity/KuaishouInfoDTO.java
  18. 47 58
      module-kuaishou/src/main/java/cn/com/ctop/kuaishou/modules/report/mapper/xml/KuaishouReportDailyAccountMapper.xml
  19. 12 28
      module-kuaishou/src/main/java/cn/com/ctop/kuaishou/modules/report/service/impl/KuaishouReportDailyAccountServiceImpl.java

+ 154 - 4
jeecg-boot-module-system/src/main/java/org/jeecg/modules/ctop/controller/AdvertiserController.java

@@ -9,6 +9,11 @@ import cn.com.ctop.common.module.service.IProjectService;
 import cn.com.ctop.common.module.service.ISysRoleExtService;
 import cn.com.ctop.common.module.service.IUserAllocationService;
 import cn.com.ctop.common.module.utils.*;
+import cn.com.ctop.common.module.vo.SheetInfoVo;
+import cn.com.ctop.kuaishou.modules.report.entity.KuaishouInfoDTO;
+import cn.com.ctop.kuaishou.modules.report.entity.KuaishouReportDailyAccountDTO;
+import cn.com.ctop.kuaishou.modules.report.entity.ProjectAccountDTO;
+import cn.com.ctop.kuaishou.modules.report.service.IKuaishouReportDailyAccountService;
 import com.alibaba.excel.EasyExcelFactory;
 import com.alibaba.excel.ExcelWriter;
 import com.alibaba.excel.metadata.Sheet;
@@ -16,6 +21,7 @@ import com.alibaba.fastjson.JSONObject;
 import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
 import com.baomidou.mybatisplus.core.metadata.IPage;
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
+import com.github.pagehelper.PageInfo;
 import io.swagger.annotations.Api;
 import io.swagger.annotations.ApiOperation;
 import lombok.extern.slf4j.Slf4j;
@@ -25,12 +31,12 @@ import org.jeecg.common.util.DateUtils;
 import org.jeecg.modules.ctop.entity.Advertiser;
 import org.jeecg.modules.ctop.mapper.ProjectMemberMapper;
 import org.jeecg.modules.ctop.service.IAdvertiserService;
-import org.jeecg.modules.ctop.vo.SheetInfoVo;
-import org.jeecg.modules.excelutil.entity.KuaishouXxlEntity;
+import org.jeecg.modules.excelutil.entity.*;
 import org.jeecg.modules.system.entity.SysCategory;
 import org.jeecg.modules.system.entity.UserCompany;
 import org.jeecg.modules.system.mapper.UserCompanyMapper;
 import org.jeecg.modules.system.service.ISysCategoryService;
+import org.springframework.beans.BeanUtils;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.web.bind.annotation.*;
 
@@ -67,7 +73,6 @@ public class AdvertiserController {
     @Autowired
     private IUserAllocationService userAllocationService;
 
-
     /**
      * 查询 公司广告主
      *
@@ -405,7 +410,10 @@ public class AdvertiserController {
      */
     @RequestMapping(value = "/exportXxlDailyReport")
     @ResponseBody
-    public void exportXxl(HttpServletRequest request, HttpServletResponse response, Long projectId, String systemType) throws IOException {
+    public void exportXxl(HttpServletRequest request,
+                          HttpServletResponse response,
+                          Long projectId,
+                          String systemType) throws IOException {
         List<SheetInfoVo> sheets = new ArrayList<>();
         if (null == systemType || "".equals(systemType.trim())) {
             systemType = null;
@@ -441,4 +449,146 @@ public class AdvertiserController {
         outputStream.flush();
         outputStream.close();
     }
+
+    @Autowired
+    private IKuaishouReportDailyAccountService accountService;
+
+    @RequestMapping("/exportKuaishouProjectInfo")
+    public void getKuaishouProjectInfo(@RequestBody KuaishouInfoDTO dto,
+                                       HttpServletRequest request,
+                                       HttpServletResponse response)throws IOException  {
+        Result<PageInfo<ProjectAccountDTO>> result = new Result<>();
+        result.setSuccess(true);
+
+        if(dto.getPageSize() == 0){
+            dto.setPageSize(100000);
+        }
+        OutputStream outputStream = response.getOutputStream();
+        String date = DateUtils.formatDate(new Date());
+        HttpUtils.setResponseHeader(response, "快手效果报表" + date + ".xlsx");
+        ExcelWriter excelWriter = EasyExcelFactory.getWriter(outputStream);
+        String type = dto.getType();
+        if(null!=type&&type.trim().equals("project")){
+            SheetInfoVo projectSheetVo = this.getProjectSheetVo(dto, "项目报表");
+            Sheet sheet = new Sheet( 1, 0, EffecfReportProjectEntity.class);
+            sheet.setSheetName(projectSheetVo.getSheetName());
+            excelWriter.write(projectSheetVo.getDetails(), sheet);
+        }
+        if(null!=type&&type.trim().equals("account")){
+            SheetInfoVo accountSheetVo = this.getAccountSheetVo(dto, "账户报表");
+            Sheet sheet = new Sheet( 1, 0, EffecfReportAccountEntity.class);
+            sheet.setSheetName(accountSheetVo.getSheetName());
+            excelWriter.write(accountSheetVo.getDetails(), sheet);
+        }
+
+        if(null!=type&&type.trim().equals("campaign")){
+            SheetInfoVo planSheetVo = this.getPlanSheetVo(dto, "广告计划报表");
+            Sheet sheet = new Sheet( 1, 0, EffecfReportPlanEntity.class);
+            sheet.setSheetName(planSheetVo.getSheetName());
+            excelWriter.write(planSheetVo.getDetails(), sheet);
+        }
+
+        if(null!=type&&type.trim().equals("group")){
+            SheetInfoVo campaignSheetVo = this.getGroupSheetVo(dto, "广告组报表");
+            Sheet sheet = new Sheet( 1, 0, EffecfReportGroupEntity.class);
+            sheet.setSheetName(campaignSheetVo.getSheetName());
+            excelWriter.write(campaignSheetVo.getDetails(), sheet);
+        }
+
+        if(null!=type&&type.trim().equals("creative")){
+            SheetInfoVo creativeSheetVo = this.getCreativeSheetVo(dto, "广告创意");
+            Sheet sheet = new Sheet( 1, 0, EffecfReportCreativeEntity.class);
+            sheet.setSheetName(creativeSheetVo.getSheetName());
+            excelWriter.write(creativeSheetVo.getDetails(), sheet);
+        }
+
+        excelWriter.finish();
+        outputStream.flush();
+        outputStream.close();
+    }
+
+    private SheetInfoVo getCreativeSheetVo(KuaishouInfoDTO dto, String sheetName) {
+        SheetInfoVo vo = new SheetInfoVo<EffecfReportProjectEntity>();
+        vo.setSheetName(sheetName);
+        PageInfo<KuaishouReportDailyAccountDTO> kuaishouCampaignInfoList = accountService.getKuaishouCreativeInfoByUnitId(dto.getProjectList(), dto.getUnitId(), dto.getStartDate(), dto.getEndDate(),dto.getPageSize(),dto.getPageNum(),dto.getYn());
+        List<KuaishouReportDailyAccountDTO> dtos = kuaishouCampaignInfoList.getList();
+        if(null!=dtos&&!dtos.isEmpty()){
+            List<EffecfReportCreativeEntity> details = new ArrayList<>();
+            for(KuaishouReportDailyAccountDTO dto1:dtos){
+                EffecfReportCreativeEntity entity = new EffecfReportCreativeEntity();
+                BeanUtils.copyProperties(dto1,entity);
+                details.add(entity);
+            }
+            vo.setDetails(details);
+        }
+        return vo;
+    }
+
+    private SheetInfoVo getGroupSheetVo(KuaishouInfoDTO dto, String sheetName) {
+        SheetInfoVo vo = new SheetInfoVo<EffecfReportProjectEntity>();
+        vo.setSheetName(sheetName);
+        PageInfo<KuaishouReportDailyAccountDTO> kuaishouCampaignInfoList = accountService.getKuaishouUnitInfoByCampaignId(dto.getProjectList(), dto.getCampaignId(), dto.getStartDate(), dto.getEndDate(),dto.getPageSize(),dto.getPageNum(),dto.getYn());
+        List<KuaishouReportDailyAccountDTO> dtos = kuaishouCampaignInfoList.getList();
+        if(null!=dtos&&!dtos.isEmpty()){
+            List<EffecfReportGroupEntity> details = new ArrayList<>();
+            for(KuaishouReportDailyAccountDTO dto1:dtos){
+                EffecfReportGroupEntity entity = new EffecfReportGroupEntity();
+                BeanUtils.copyProperties(dto1,entity);
+                details.add(entity);
+            }
+            vo.setDetails(details);
+        }
+        return vo;
+    }
+
+    private SheetInfoVo getPlanSheetVo(KuaishouInfoDTO dto, String sheetName) {
+        SheetInfoVo vo = new SheetInfoVo<EffecfReportProjectEntity>();
+        vo.setSheetName(sheetName);
+        PageInfo<KuaishouReportDailyAccountDTO> kuaishouCampaignInfoList = accountService.getKuaishouCampaignInfoByAccountId(dto.getProjectList(), dto.getAccountId(), dto.getStartDate(), dto.getEndDate(),dto.getPageSize(),dto.getPageNum(),dto.getYn());
+        List<KuaishouReportDailyAccountDTO> dtos = kuaishouCampaignInfoList.getList();
+        if(null!=dtos&&!dtos.isEmpty()){
+            List<EffecfReportPlanEntity> details = new ArrayList<>();
+            for(KuaishouReportDailyAccountDTO dto1:dtos){
+                EffecfReportPlanEntity entity = new EffecfReportPlanEntity();
+                BeanUtils.copyProperties(dto1,entity);
+                details.add(entity);
+            }
+            vo.setDetails(details);
+        }
+        return vo;
+    }
+
+    private SheetInfoVo getAccountSheetVo(KuaishouInfoDTO dto, String sheetName) {
+        SheetInfoVo vo = new SheetInfoVo<EffecfReportProjectEntity>();
+        vo.setSheetName(sheetName);
+        PageInfo<KuaishouReportDailyAccountDTO> kuaishouReportDailyAccountDTOList = accountService.getKuaishouAccountInfoByProjectId(dto.getProjectId(),dto.getProjectList(), dto.getStartDate(), dto.getEndDate(),dto.getPageSize(),dto.getPageNum(),dto.getYn());
+        List<KuaishouReportDailyAccountDTO> dtos = kuaishouReportDailyAccountDTOList.getList();
+        if(null!=dtos&&!dtos.isEmpty()){
+            List<EffecfReportAccountEntity> details = new ArrayList<>();
+            for(KuaishouReportDailyAccountDTO dto1:dtos){
+                EffecfReportAccountEntity entity = new EffecfReportAccountEntity();
+                BeanUtils.copyProperties(dto1,entity);
+                details.add(entity);
+            }
+            vo.setDetails(details);
+        }
+        return vo;
+    }
+
+    private SheetInfoVo getProjectSheetVo(KuaishouInfoDTO dto, String sheetName) {
+        SheetInfoVo vo = new SheetInfoVo<EffecfReportProjectEntity>();
+        vo.setSheetName(sheetName);
+        PageInfo<ProjectAccountDTO> projectAccountDTOList = accountService.getKuaishouProjectInfo(dto.getStartDate(), dto.getEndDate(), dto.getProjectList(),dto.getPageSize(),dto.getPageNum(), "", dto.getYn());
+        List<ProjectAccountDTO> dtos = projectAccountDTOList.getList();
+        if(null!=dtos&&!dtos.isEmpty()){
+            List<EffecfReportProjectEntity> details = new ArrayList<>();
+            for(ProjectAccountDTO dto1:dtos){
+                EffecfReportProjectEntity entity = new EffecfReportProjectEntity();
+                BeanUtils.copyProperties(dto1,entity);
+                details.add(entity);
+            }
+            vo.setDetails(details);
+        }
+        return vo;
+    }
 }

+ 1 - 1
jeecg-boot-module-system/src/main/java/org/jeecg/modules/ctop/controller/ProjectMemberController.java

@@ -131,7 +131,7 @@ public class ProjectMemberController {
         try {
             String userId = ((LoginUser) SecurityUtils.getSubject().getPrincipal()).getId();
             String roleCode = sysRoleService.getRoleCodeByUserId(userId);
-            if (!"admin".equals(roleCode) && !roleCode.contains("sale") && !"meidaManager".equals(roleCode)) {
+            if ("admin".equals(roleCode) || roleCode.contains("sale") || "meidaManager".equals(roleCode)) {
                 List<Project>projects = projectService.list();
                 result.put("data",projects);
                 ResultMapUtils.setResultMap(result, StatusCode.COMMON_SUCCESS);

+ 5 - 1
jeecg-boot-module-system/src/main/java/org/jeecg/modules/ctop/controller/TagInfoController.java

@@ -11,6 +11,7 @@ import org.apache.shiro.SecurityUtils;
 import org.jeecg.common.api.vo.Result;
 import org.jeecg.common.system.query.QueryGenerator;
 import org.jeecg.common.system.vo.LoginUser;
+import org.jeecg.modules.system.service.ISysRoleService;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.web.bind.annotation.*;
 
@@ -160,12 +161,15 @@ public class TagInfoController {
 		}
 		return result;
 	}
+	@Autowired
+	private ISysRoleService roleService;
 
 	@RequestMapping(value = "/queryTreeList", method = RequestMethod.GET)
     public Result<List<TagInfoTreeModel>> queryTreeList() {
 	    Result<List<TagInfoTreeModel>> result = new Result<>();
 	    try {
-            List<TagInfoTreeModel> list = tagInfoService.queryTreeList();
+			LoginUser user = (LoginUser) SecurityUtils.getSubject().getPrincipal();
+            List<TagInfoTreeModel> list = tagInfoService.queryTreeList(user.getId());
 	        result.setResult(list);
 	        result.setSuccess(true);
 	    } catch (Exception e) {

+ 1 - 1
jeecg-boot-module-system/src/main/java/org/jeecg/modules/ctop/service/IAdvertiserService.java

@@ -1,9 +1,9 @@
 package org.jeecg.modules.ctop.service;
 
 import cn.com.ctop.common.module.entity.UserAllocation;
+import cn.com.ctop.common.module.vo.SheetInfoVo;
 import com.baomidou.mybatisplus.extension.service.IService;
 import org.jeecg.modules.ctop.entity.Advertiser;
-import org.jeecg.modules.ctop.vo.SheetInfoVo;
 
 import java.text.ParseException;
 import java.util.List;

+ 1 - 1
jeecg-boot-module-system/src/main/java/org/jeecg/modules/ctop/service/impl/AdvertiserServiceImpl.java

@@ -2,13 +2,13 @@ package org.jeecg.modules.ctop.service.impl;
 
 import cn.com.ctop.common.module.entity.UserAllocation;
 import cn.com.ctop.common.module.service.IUserAllocationService;
+import cn.com.ctop.common.module.vo.SheetInfoVo;
 import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
 import org.jeecg.common.util.DateUtils;
 import org.jeecg.modules.ctop.entity.Advertiser;
 import org.jeecg.modules.ctop.mapper.AdvertiserMapper;
 import org.jeecg.modules.ctop.service.IAdvertiserService;
-import org.jeecg.modules.ctop.vo.SheetInfoVo;
 import org.jeecg.modules.excelutil.entity.KuaishouXxlEntity;
 import org.jeecg.modules.excelutil.entity.YdPlanAggregateEntity;
 import org.jeecg.modules.excelutil.entity.YdWeekAggregateEntity;

+ 299 - 0
jeecg-boot-module-system/src/main/java/org/jeecg/modules/excelutil/entity/EffecfReportAccountEntity.java

@@ -0,0 +1,299 @@
+package org.jeecg.modules.excelutil.entity;
+
+import com.alibaba.excel.annotation.ExcelProperty;
+import com.alibaba.excel.metadata.BaseRowModel;
+
+import java.math.BigDecimal;
+
+public class EffecfReportAccountEntity extends BaseRowModel {
+    @ExcelProperty(index = 1, value = "账户名称")
+    private String authName;
+    @ExcelProperty(index = 2, value = "账户id")
+    private String accountId;
+    @ExcelProperty(index = 3, value = "项目名称")
+    private String projectName;
+    @ExcelProperty(index = 4, value = "消耗")
+    private BigDecimal charge;
+    @ExcelProperty(index = 5, value = "封面曝光数")
+    private Long photoShow;
+    @ExcelProperty(index = 6, value = "封面点击数")
+    private Long photoClick;
+    @ExcelProperty(index = 7, value = "素材曝光数")
+    private Long aclick;
+    @ExcelProperty(index = 8, value = "行为数")
+    private Long bclick;
+    @ExcelProperty(index = 9, value = "激活数")
+    private Long activation;
+    @ExcelProperty(index = 10, value = "注册数")
+    private Long eventRegister;
+    @ExcelProperty(index = 11, value = "点击数")
+    private Long submit;
+    @ExcelProperty(index = 12, value = "次留数")
+    private Long eventNextDayStay;
+    @ExcelProperty(index = 13, value = "次留成本")
+    private BigDecimal eventNextDayStayCost;
+    @ExcelProperty(index = 14, value = "激活成本")
+    private BigDecimal activationCost;
+    @ExcelProperty(index = 15, value = "封面点击率")
+    private String photoClickRatio;
+    @ExcelProperty(index = 16, value = "行为率")
+    private String actionRate;
+    @ExcelProperty(index = 17, value = "千次曝光花费")
+    private BigDecimal impression1kCost;
+    @ExcelProperty(index = 18, value = "封面点击单价")
+    private BigDecimal photoClickCost;
+    @ExcelProperty(index = 19, value = "行为单价")
+    private BigDecimal actionCost;
+    @ExcelProperty(index = 20, value = "分享数")
+    private Long photoShare;
+    @ExcelProperty(index = 21, value = "评论数")
+    private Long photoComment;
+    @ExcelProperty(index = 22, value = "点赞数")
+    private Long photoLike;
+    @ExcelProperty(index = 23, value = "新增关注数")
+    private Long follow;
+    @ExcelProperty(index = 24, value = "举报数")
+    private Long report;
+    @ExcelProperty(index = 25, value = "取消关注数")
+    private Long cancelFollow;
+    @ExcelProperty(index = 26, value = "拉黑数")
+    private Long block;
+    @ExcelProperty(index = 27, value = "减少此类作品数")
+    private Long nagative;
+    @ExcelProperty(index = 28, value = "安卓下载开始数")
+    private Long downloadStarted;
+    @ExcelProperty(index = 29, value = "安卓下载完成数")
+    private Long downloadCompleted;
+
+    public String getAuthName() {
+        return authName;
+    }
+
+    public void setAuthName(String authName) {
+        this.authName = authName;
+    }
+
+    public String getAccountId() {
+        return accountId;
+    }
+
+    public void setAccountId(String accountId) {
+        this.accountId = accountId;
+    }
+
+    public String getProjectName() {
+        return projectName;
+    }
+
+    public void setProjectName(String projectName) {
+        this.projectName = projectName;
+    }
+
+    public BigDecimal getCharge() {
+        return charge;
+    }
+
+    public void setCharge(BigDecimal charge) {
+        this.charge = charge;
+    }
+
+    public Long getPhotoShow() {
+        return photoShow;
+    }
+
+    public void setPhotoShow(Long photoShow) {
+        this.photoShow = photoShow;
+    }
+
+    public Long getPhotoClick() {
+        return photoClick;
+    }
+
+    public void setPhotoClick(Long photoClick) {
+        this.photoClick = photoClick;
+    }
+
+    public Long getAclick() {
+        return aclick;
+    }
+
+    public void setAclick(Long aclick) {
+        this.aclick = aclick;
+    }
+
+    public Long getBclick() {
+        return bclick;
+    }
+
+    public void setBclick(Long bclick) {
+        this.bclick = bclick;
+    }
+
+    public Long getActivation() {
+        return activation;
+    }
+
+    public void setActivation(Long activation) {
+        this.activation = activation;
+    }
+
+    public Long getEventRegister() {
+        return eventRegister;
+    }
+
+    public void setEventRegister(Long eventRegister) {
+        this.eventRegister = eventRegister;
+    }
+
+    public Long getSubmit() {
+        return submit;
+    }
+
+    public void setSubmit(Long submit) {
+        this.submit = submit;
+    }
+
+    public Long getEventNextDayStay() {
+        return eventNextDayStay;
+    }
+
+    public void setEventNextDayStay(Long eventNextDayStay) {
+        this.eventNextDayStay = eventNextDayStay;
+    }
+
+    public BigDecimal getEventNextDayStayCost() {
+        return eventNextDayStayCost;
+    }
+
+    public void setEventNextDayStayCost(BigDecimal eventNextDayStayCost) {
+        this.eventNextDayStayCost = eventNextDayStayCost;
+    }
+
+    public BigDecimal getActivationCost() {
+        return activationCost;
+    }
+
+    public void setActivationCost(BigDecimal activationCost) {
+        this.activationCost = activationCost;
+    }
+
+    public String getPhotoClickRatio() {
+        return photoClickRatio;
+    }
+
+    public void setPhotoClickRatio(String photoClickRatio) {
+        this.photoClickRatio = photoClickRatio;
+    }
+
+    public String getActionRate() {
+        return actionRate;
+    }
+
+    public void setActionRate(String actionRate) {
+        this.actionRate = actionRate;
+    }
+
+    public BigDecimal getImpression1kCost() {
+        return impression1kCost;
+    }
+
+    public void setImpression1kCost(BigDecimal impression1kCost) {
+        this.impression1kCost = impression1kCost;
+    }
+
+    public BigDecimal getPhotoClickCost() {
+        return photoClickCost;
+    }
+
+    public void setPhotoClickCost(BigDecimal photoClickCost) {
+        this.photoClickCost = photoClickCost;
+    }
+
+    public BigDecimal getActionCost() {
+        return actionCost;
+    }
+
+    public void setActionCost(BigDecimal actionCost) {
+        this.actionCost = actionCost;
+    }
+
+    public Long getPhotoShare() {
+        return photoShare;
+    }
+
+    public void setPhotoShare(Long photoShare) {
+        this.photoShare = photoShare;
+    }
+
+    public Long getPhotoComment() {
+        return photoComment;
+    }
+
+    public void setPhotoComment(Long photoComment) {
+        this.photoComment = photoComment;
+    }
+
+    public Long getPhotoLike() {
+        return photoLike;
+    }
+
+    public void setPhotoLike(Long photoLike) {
+        this.photoLike = photoLike;
+    }
+
+    public Long getFollow() {
+        return follow;
+    }
+
+    public void setFollow(Long follow) {
+        this.follow = follow;
+    }
+
+    public Long getReport() {
+        return report;
+    }
+
+    public void setReport(Long report) {
+        this.report = report;
+    }
+
+    public Long getCancelFollow() {
+        return cancelFollow;
+    }
+
+    public void setCancelFollow(Long cancelFollow) {
+        this.cancelFollow = cancelFollow;
+    }
+
+    public Long getBlock() {
+        return block;
+    }
+
+    public void setBlock(Long block) {
+        this.block = block;
+    }
+
+    public Long getNagative() {
+        return nagative;
+    }
+
+    public void setNagative(Long nagative) {
+        this.nagative = nagative;
+    }
+
+    public Long getDownloadStarted() {
+        return downloadStarted;
+    }
+
+    public void setDownloadStarted(Long downloadStarted) {
+        this.downloadStarted = downloadStarted;
+    }
+
+    public Long getDownloadCompleted() {
+        return downloadCompleted;
+    }
+
+    public void setDownloadCompleted(Long downloadCompleted) {
+        this.downloadCompleted = downloadCompleted;
+    }
+}

+ 302 - 0
jeecg-boot-module-system/src/main/java/org/jeecg/modules/excelutil/entity/EffecfReportCreativeEntity.java

@@ -0,0 +1,302 @@
+package org.jeecg.modules.excelutil.entity;
+
+import com.alibaba.excel.annotation.ExcelProperty;
+import com.alibaba.excel.metadata.BaseRowModel;
+
+import java.math.BigDecimal;
+
+/**
+ * @author 宋英豪
+ */
+public class EffecfReportCreativeEntity extends BaseRowModel {
+    @ExcelProperty(index = 1, value = "创意视频url")
+    private String url;
+    @ExcelProperty(index = 2, value = "创意名称")
+    private String creativeName;
+    @ExcelProperty(index = 3, value = "广告组名称")
+    private String campaignName;
+    @ExcelProperty(index = 4, value = "消耗")
+    private BigDecimal charge;
+    @ExcelProperty(index = 5, value = "封面曝光数")
+    private Long photoShow;
+    @ExcelProperty(index = 6, value = "封面点击数")
+    private Long photoClick;
+    @ExcelProperty(index = 7, value = "素材曝光数")
+    private Long aclick;
+    @ExcelProperty(index = 8, value = "行为数")
+    private Long bclick;
+    @ExcelProperty(index = 9, value = "激活数")
+    private Long activation;
+    @ExcelProperty(index = 10, value = "注册数")
+    private Long eventRegister;
+    @ExcelProperty(index = 11, value = "点击数")
+    private Long submit;
+    @ExcelProperty(index = 12, value = "次留数")
+    private Long eventNextDayStay;
+    @ExcelProperty(index = 13, value = "次留成本")
+    private BigDecimal eventNextDayStayCost;
+    @ExcelProperty(index = 14, value = "激活成本")
+    private BigDecimal activationCost;
+    @ExcelProperty(index = 15, value = "封面点击率")
+    private String photoClickRatio;
+    @ExcelProperty(index = 16, value = "行为率")
+    private String actionRate;
+    @ExcelProperty(index = 17, value = "千次曝光花费")
+    private BigDecimal impression1kCost;
+    @ExcelProperty(index = 18, value = "封面点击单价")
+    private BigDecimal photoClickCost;
+    @ExcelProperty(index = 19, value = "行为单价")
+    private BigDecimal actionCost;
+    @ExcelProperty(index = 20, value = "分享数")
+    private Long photoShare;
+    @ExcelProperty(index = 21, value = "评论数")
+    private Long photoComment;
+    @ExcelProperty(index = 22, value = "点赞数")
+    private Long photoLike;
+    @ExcelProperty(index = 23, value = "新增关注数")
+    private Long follow;
+    @ExcelProperty(index = 24, value = "举报数")
+    private Long report;
+    @ExcelProperty(index = 25, value = "取消关注数")
+    private Long cancelFollow;
+    @ExcelProperty(index = 26, value = "拉黑数")
+    private Long block;
+    @ExcelProperty(index = 27, value = "减少此类作品数")
+    private Long nagative;
+    @ExcelProperty(index = 28, value = "安卓下载开始数")
+    private Long downloadStarted;
+    @ExcelProperty(index = 29, value = "安卓下载完成数")
+    private Long downloadCompleted;
+
+    public BigDecimal getCharge() {
+        return charge;
+    }
+
+    public void setCharge(BigDecimal charge) {
+        this.charge = charge;
+    }
+
+    public Long getPhotoShow() {
+        return photoShow;
+    }
+
+    public void setPhotoShow(Long photoShow) {
+        this.photoShow = photoShow;
+    }
+
+    public Long getPhotoClick() {
+        return photoClick;
+    }
+
+    public void setPhotoClick(Long photoClick) {
+        this.photoClick = photoClick;
+    }
+
+    public Long getAclick() {
+        return aclick;
+    }
+
+    public void setAclick(Long aclick) {
+        this.aclick = aclick;
+    }
+
+    public Long getBclick() {
+        return bclick;
+    }
+
+    public void setBclick(Long bclick) {
+        this.bclick = bclick;
+    }
+
+    public Long getActivation() {
+        return activation;
+    }
+
+    public void setActivation(Long activation) {
+        this.activation = activation;
+    }
+
+    public Long getEventRegister() {
+        return eventRegister;
+    }
+
+    public void setEventRegister(Long eventRegister) {
+        this.eventRegister = eventRegister;
+    }
+
+    public Long getSubmit() {
+        return submit;
+    }
+
+    public void setSubmit(Long submit) {
+        this.submit = submit;
+    }
+
+    public Long getEventNextDayStay() {
+        return eventNextDayStay;
+    }
+
+    public void setEventNextDayStay(Long eventNextDayStay) {
+        this.eventNextDayStay = eventNextDayStay;
+    }
+
+    public BigDecimal getEventNextDayStayCost() {
+        return eventNextDayStayCost;
+    }
+
+    public void setEventNextDayStayCost(BigDecimal eventNextDayStayCost) {
+        this.eventNextDayStayCost = eventNextDayStayCost;
+    }
+
+    public BigDecimal getActivationCost() {
+        return activationCost;
+    }
+
+    public void setActivationCost(BigDecimal activationCost) {
+        this.activationCost = activationCost;
+    }
+
+    public String getPhotoClickRatio() {
+        return photoClickRatio;
+    }
+
+    public void setPhotoClickRatio(String photoClickRatio) {
+        this.photoClickRatio = photoClickRatio;
+    }
+
+    public String getActionRate() {
+        return actionRate;
+    }
+
+    public void setActionRate(String actionRate) {
+        this.actionRate = actionRate;
+    }
+
+    public BigDecimal getImpression1kCost() {
+        return impression1kCost;
+    }
+
+    public void setImpression1kCost(BigDecimal impression1kCost) {
+        this.impression1kCost = impression1kCost;
+    }
+
+    public BigDecimal getPhotoClickCost() {
+        return photoClickCost;
+    }
+
+    public void setPhotoClickCost(BigDecimal photoClickCost) {
+        this.photoClickCost = photoClickCost;
+    }
+
+    public BigDecimal getActionCost() {
+        return actionCost;
+    }
+
+    public void setActionCost(BigDecimal actionCost) {
+        this.actionCost = actionCost;
+    }
+
+    public Long getPhotoShare() {
+        return photoShare;
+    }
+
+    public void setPhotoShare(Long photoShare) {
+        this.photoShare = photoShare;
+    }
+
+    public Long getPhotoComment() {
+        return photoComment;
+    }
+
+    public void setPhotoComment(Long photoComment) {
+        this.photoComment = photoComment;
+    }
+
+    public Long getPhotoLike() {
+        return photoLike;
+    }
+
+    public void setPhotoLike(Long photoLike) {
+        this.photoLike = photoLike;
+    }
+
+    public Long getFollow() {
+        return follow;
+    }
+
+    public void setFollow(Long follow) {
+        this.follow = follow;
+    }
+
+    public Long getReport() {
+        return report;
+    }
+
+    public void setReport(Long report) {
+        this.report = report;
+    }
+
+    public Long getCancelFollow() {
+        return cancelFollow;
+    }
+
+    public void setCancelFollow(Long cancelFollow) {
+        this.cancelFollow = cancelFollow;
+    }
+
+    public Long getBlock() {
+        return block;
+    }
+
+    public void setBlock(Long block) {
+        this.block = block;
+    }
+
+    public Long getNagative() {
+        return nagative;
+    }
+
+    public void setNagative(Long nagative) {
+        this.nagative = nagative;
+    }
+
+    public Long getDownloadStarted() {
+        return downloadStarted;
+    }
+
+    public void setDownloadStarted(Long downloadStarted) {
+        this.downloadStarted = downloadStarted;
+    }
+
+    public Long getDownloadCompleted() {
+        return downloadCompleted;
+    }
+
+    public void setDownloadCompleted(Long downloadCompleted) {
+        this.downloadCompleted = downloadCompleted;
+    }
+
+    public String getUrl() {
+        return url;
+    }
+
+    public void setUrl(String url) {
+        this.url = url;
+    }
+
+    public String getCreativeName() {
+        return creativeName;
+    }
+
+    public void setCreativeName(String creativeName) {
+        this.creativeName = creativeName;
+    }
+
+    public String getCampaignName() {
+        return campaignName;
+    }
+
+    public void setCampaignName(String campaignName) {
+        this.campaignName = campaignName;
+    }
+}

+ 299 - 0
jeecg-boot-module-system/src/main/java/org/jeecg/modules/excelutil/entity/EffecfReportGroupEntity.java

@@ -0,0 +1,299 @@
+package org.jeecg.modules.excelutil.entity;
+
+import com.alibaba.excel.annotation.ExcelProperty;
+import com.alibaba.excel.metadata.BaseRowModel;
+
+import java.math.BigDecimal;
+
+public class EffecfReportGroupEntity extends BaseRowModel {
+    @ExcelProperty(index = 1, value = "广告组名称")
+    private String unitName;
+    @ExcelProperty(index = 2, value = "广告组id")
+    private Long unitId;
+    @ExcelProperty(index = 3, value = "计划名称")
+    private String campaignName;
+    @ExcelProperty(index = 4, value = "消耗")
+    private BigDecimal charge;
+    @ExcelProperty(index = 5, value = "封面曝光数")
+    private Long photoShow;
+    @ExcelProperty(index = 6, value = "封面点击数")
+    private Long photoClick;
+    @ExcelProperty(index = 7, value = "素材曝光数")
+    private Long aclick;
+    @ExcelProperty(index = 8, value = "行为数")
+    private Long bclick;
+    @ExcelProperty(index = 9, value = "激活数")
+    private Long activation;
+    @ExcelProperty(index = 10, value = "注册数")
+    private Long eventRegister;
+    @ExcelProperty(index = 11, value = "点击数")
+    private Long submit;
+    @ExcelProperty(index = 12, value = "次留数")
+    private Long eventNextDayStay;
+    @ExcelProperty(index = 13, value = "次留成本")
+    private BigDecimal eventNextDayStayCost;
+    @ExcelProperty(index = 14, value = "激活成本")
+    private BigDecimal activationCost;
+    @ExcelProperty(index = 15, value = "封面点击率")
+    private String photoClickRatio;
+    @ExcelProperty(index = 16, value = "行为率")
+    private String actionRate;
+    @ExcelProperty(index = 17, value = "千次曝光花费")
+    private BigDecimal impression1kCost;
+    @ExcelProperty(index = 18, value = "封面点击单价")
+    private BigDecimal photoClickCost;
+    @ExcelProperty(index = 19, value = "行为单价")
+    private BigDecimal actionCost;
+    @ExcelProperty(index = 20, value = "分享数")
+    private Long photoShare;
+    @ExcelProperty(index = 21, value = "评论数")
+    private Long photoComment;
+    @ExcelProperty(index = 22, value = "点赞数")
+    private Long photoLike;
+    @ExcelProperty(index = 23, value = "新增关注数")
+    private Long follow;
+    @ExcelProperty(index = 24, value = "举报数")
+    private Long report;
+    @ExcelProperty(index = 25, value = "取消关注数")
+    private Long cancelFollow;
+    @ExcelProperty(index = 26, value = "拉黑数")
+    private Long block;
+    @ExcelProperty(index = 27, value = "减少此类作品数")
+    private Long nagative;
+    @ExcelProperty(index = 28, value = "安卓下载开始数")
+    private Long downloadStarted;
+    @ExcelProperty(index = 29, value = "安卓下载完成数")
+    private Long downloadCompleted;
+
+    public BigDecimal getCharge() {
+        return charge;
+    }
+
+    public void setCharge(BigDecimal charge) {
+        this.charge = charge;
+    }
+
+    public Long getPhotoShow() {
+        return photoShow;
+    }
+
+    public void setPhotoShow(Long photoShow) {
+        this.photoShow = photoShow;
+    }
+
+    public Long getPhotoClick() {
+        return photoClick;
+    }
+
+    public void setPhotoClick(Long photoClick) {
+        this.photoClick = photoClick;
+    }
+
+    public Long getAclick() {
+        return aclick;
+    }
+
+    public void setAclick(Long aclick) {
+        this.aclick = aclick;
+    }
+
+    public Long getBclick() {
+        return bclick;
+    }
+
+    public void setBclick(Long bclick) {
+        this.bclick = bclick;
+    }
+
+    public Long getActivation() {
+        return activation;
+    }
+
+    public void setActivation(Long activation) {
+        this.activation = activation;
+    }
+
+    public Long getEventRegister() {
+        return eventRegister;
+    }
+
+    public void setEventRegister(Long eventRegister) {
+        this.eventRegister = eventRegister;
+    }
+
+    public Long getSubmit() {
+        return submit;
+    }
+
+    public void setSubmit(Long submit) {
+        this.submit = submit;
+    }
+
+    public Long getEventNextDayStay() {
+        return eventNextDayStay;
+    }
+
+    public void setEventNextDayStay(Long eventNextDayStay) {
+        this.eventNextDayStay = eventNextDayStay;
+    }
+
+    public BigDecimal getEventNextDayStayCost() {
+        return eventNextDayStayCost;
+    }
+
+    public void setEventNextDayStayCost(BigDecimal eventNextDayStayCost) {
+        this.eventNextDayStayCost = eventNextDayStayCost;
+    }
+
+    public BigDecimal getActivationCost() {
+        return activationCost;
+    }
+
+    public void setActivationCost(BigDecimal activationCost) {
+        this.activationCost = activationCost;
+    }
+
+    public String getPhotoClickRatio() {
+        return photoClickRatio;
+    }
+
+    public void setPhotoClickRatio(String photoClickRatio) {
+        this.photoClickRatio = photoClickRatio;
+    }
+
+    public String getActionRate() {
+        return actionRate;
+    }
+
+    public void setActionRate(String actionRate) {
+        this.actionRate = actionRate;
+    }
+
+    public BigDecimal getImpression1kCost() {
+        return impression1kCost;
+    }
+
+    public void setImpression1kCost(BigDecimal impression1kCost) {
+        this.impression1kCost = impression1kCost;
+    }
+
+    public BigDecimal getPhotoClickCost() {
+        return photoClickCost;
+    }
+
+    public void setPhotoClickCost(BigDecimal photoClickCost) {
+        this.photoClickCost = photoClickCost;
+    }
+
+    public BigDecimal getActionCost() {
+        return actionCost;
+    }
+
+    public void setActionCost(BigDecimal actionCost) {
+        this.actionCost = actionCost;
+    }
+
+    public Long getPhotoShare() {
+        return photoShare;
+    }
+
+    public void setPhotoShare(Long photoShare) {
+        this.photoShare = photoShare;
+    }
+
+    public Long getPhotoComment() {
+        return photoComment;
+    }
+
+    public void setPhotoComment(Long photoComment) {
+        this.photoComment = photoComment;
+    }
+
+    public Long getPhotoLike() {
+        return photoLike;
+    }
+
+    public void setPhotoLike(Long photoLike) {
+        this.photoLike = photoLike;
+    }
+
+    public Long getFollow() {
+        return follow;
+    }
+
+    public void setFollow(Long follow) {
+        this.follow = follow;
+    }
+
+    public Long getReport() {
+        return report;
+    }
+
+    public void setReport(Long report) {
+        this.report = report;
+    }
+
+    public Long getCancelFollow() {
+        return cancelFollow;
+    }
+
+    public void setCancelFollow(Long cancelFollow) {
+        this.cancelFollow = cancelFollow;
+    }
+
+    public Long getBlock() {
+        return block;
+    }
+
+    public void setBlock(Long block) {
+        this.block = block;
+    }
+
+    public Long getNagative() {
+        return nagative;
+    }
+
+    public void setNagative(Long nagative) {
+        this.nagative = nagative;
+    }
+
+    public Long getDownloadStarted() {
+        return downloadStarted;
+    }
+
+    public void setDownloadStarted(Long downloadStarted) {
+        this.downloadStarted = downloadStarted;
+    }
+
+    public Long getDownloadCompleted() {
+        return downloadCompleted;
+    }
+
+    public void setDownloadCompleted(Long downloadCompleted) {
+        this.downloadCompleted = downloadCompleted;
+    }
+
+    public Long getUnitId() {
+        return unitId;
+    }
+
+    public void setUnitId(Long unitId) {
+        this.unitId = unitId;
+    }
+
+    public String getUnitName() {
+        return unitName;
+    }
+
+    public void setUnitName(String unitName) {
+        this.unitName = unitName;
+    }
+
+    public String getCampaignName() {
+        return campaignName;
+    }
+
+    public void setCampaignName(String campaignName) {
+        this.campaignName = campaignName;
+    }
+}

+ 299 - 0
jeecg-boot-module-system/src/main/java/org/jeecg/modules/excelutil/entity/EffecfReportPlanEntity.java

@@ -0,0 +1,299 @@
+package org.jeecg.modules.excelutil.entity;
+
+import com.alibaba.excel.annotation.ExcelProperty;
+import com.alibaba.excel.metadata.BaseRowModel;
+
+import java.math.BigDecimal;
+
+public class EffecfReportPlanEntity extends BaseRowModel {
+    @ExcelProperty(index = 1, value = "计划名称")
+    private String campaignName;
+    @ExcelProperty(index = 2, value = "计划id")
+    private Long campaignId;
+    @ExcelProperty(index = 3, value = "账户名称")
+    private String authName;
+    @ExcelProperty(index = 4, value = "消耗")
+    private BigDecimal charge;
+    @ExcelProperty(index = 5, value = "封面曝光数")
+    private Long photoShow;
+    @ExcelProperty(index = 6, value = "封面点击数")
+    private Long photoClick;
+    @ExcelProperty(index = 7, value = "素材曝光数")
+    private Long aclick;
+    @ExcelProperty(index = 8, value = "行为数")
+    private Long bclick;
+    @ExcelProperty(index = 9, value = "激活数")
+    private Long activation;
+    @ExcelProperty(index = 10, value = "注册数")
+    private Long eventRegister;
+    @ExcelProperty(index = 11, value = "点击数")
+    private Long submit;
+    @ExcelProperty(index = 12, value = "次留数")
+    private Long eventNextDayStay;
+    @ExcelProperty(index = 13, value = "次留成本")
+    private BigDecimal eventNextDayStayCost;
+    @ExcelProperty(index = 14, value = "激活成本")
+    private BigDecimal activationCost;
+    @ExcelProperty(index = 15, value = "封面点击率")
+    private String photoClickRatio;
+    @ExcelProperty(index = 16, value = "行为率")
+    private String actionRate;
+    @ExcelProperty(index = 17, value = "千次曝光花费")
+    private BigDecimal impression1kCost;
+    @ExcelProperty(index = 18, value = "封面点击单价")
+    private BigDecimal photoClickCost;
+    @ExcelProperty(index = 19, value = "行为单价")
+    private BigDecimal actionCost;
+    @ExcelProperty(index = 20, value = "分享数")
+    private Long photoShare;
+    @ExcelProperty(index = 21, value = "评论数")
+    private Long photoComment;
+    @ExcelProperty(index = 22, value = "点赞数")
+    private Long photoLike;
+    @ExcelProperty(index = 23, value = "新增关注数")
+    private Long follow;
+    @ExcelProperty(index = 24, value = "举报数")
+    private Long report;
+    @ExcelProperty(index = 25, value = "取消关注数")
+    private Long cancelFollow;
+    @ExcelProperty(index = 26, value = "拉黑数")
+    private Long block;
+    @ExcelProperty(index = 27, value = "减少此类作品数")
+    private Long nagative;
+    @ExcelProperty(index = 28, value = "安卓下载开始数")
+    private Long downloadStarted;
+    @ExcelProperty(index = 29, value = "安卓下载完成数")
+    private Long downloadCompleted;
+
+    public String getAuthName() {
+        return authName;
+    }
+
+    public void setAuthName(String authName) {
+        this.authName = authName;
+    }
+
+    public BigDecimal getCharge() {
+        return charge;
+    }
+
+    public void setCharge(BigDecimal charge) {
+        this.charge = charge;
+    }
+
+    public Long getPhotoShow() {
+        return photoShow;
+    }
+
+    public void setPhotoShow(Long photoShow) {
+        this.photoShow = photoShow;
+    }
+
+    public Long getPhotoClick() {
+        return photoClick;
+    }
+
+    public void setPhotoClick(Long photoClick) {
+        this.photoClick = photoClick;
+    }
+
+    public Long getAclick() {
+        return aclick;
+    }
+
+    public void setAclick(Long aclick) {
+        this.aclick = aclick;
+    }
+
+    public Long getBclick() {
+        return bclick;
+    }
+
+    public void setBclick(Long bclick) {
+        this.bclick = bclick;
+    }
+
+    public Long getActivation() {
+        return activation;
+    }
+
+    public void setActivation(Long activation) {
+        this.activation = activation;
+    }
+
+    public Long getEventRegister() {
+        return eventRegister;
+    }
+
+    public void setEventRegister(Long eventRegister) {
+        this.eventRegister = eventRegister;
+    }
+
+    public Long getSubmit() {
+        return submit;
+    }
+
+    public void setSubmit(Long submit) {
+        this.submit = submit;
+    }
+
+    public Long getEventNextDayStay() {
+        return eventNextDayStay;
+    }
+
+    public void setEventNextDayStay(Long eventNextDayStay) {
+        this.eventNextDayStay = eventNextDayStay;
+    }
+
+    public BigDecimal getEventNextDayStayCost() {
+        return eventNextDayStayCost;
+    }
+
+    public void setEventNextDayStayCost(BigDecimal eventNextDayStayCost) {
+        this.eventNextDayStayCost = eventNextDayStayCost;
+    }
+
+    public BigDecimal getActivationCost() {
+        return activationCost;
+    }
+
+    public void setActivationCost(BigDecimal activationCost) {
+        this.activationCost = activationCost;
+    }
+
+    public String getPhotoClickRatio() {
+        return photoClickRatio;
+    }
+
+    public void setPhotoClickRatio(String photoClickRatio) {
+        this.photoClickRatio = photoClickRatio;
+    }
+
+    public String getActionRate() {
+        return actionRate;
+    }
+
+    public void setActionRate(String actionRate) {
+        this.actionRate = actionRate;
+    }
+
+    public BigDecimal getImpression1kCost() {
+        return impression1kCost;
+    }
+
+    public void setImpression1kCost(BigDecimal impression1kCost) {
+        this.impression1kCost = impression1kCost;
+    }
+
+    public BigDecimal getPhotoClickCost() {
+        return photoClickCost;
+    }
+
+    public void setPhotoClickCost(BigDecimal photoClickCost) {
+        this.photoClickCost = photoClickCost;
+    }
+
+    public BigDecimal getActionCost() {
+        return actionCost;
+    }
+
+    public void setActionCost(BigDecimal actionCost) {
+        this.actionCost = actionCost;
+    }
+
+    public Long getPhotoShare() {
+        return photoShare;
+    }
+
+    public void setPhotoShare(Long photoShare) {
+        this.photoShare = photoShare;
+    }
+
+    public Long getPhotoComment() {
+        return photoComment;
+    }
+
+    public void setPhotoComment(Long photoComment) {
+        this.photoComment = photoComment;
+    }
+
+    public Long getPhotoLike() {
+        return photoLike;
+    }
+
+    public void setPhotoLike(Long photoLike) {
+        this.photoLike = photoLike;
+    }
+
+    public Long getFollow() {
+        return follow;
+    }
+
+    public void setFollow(Long follow) {
+        this.follow = follow;
+    }
+
+    public Long getReport() {
+        return report;
+    }
+
+    public void setReport(Long report) {
+        this.report = report;
+    }
+
+    public Long getCancelFollow() {
+        return cancelFollow;
+    }
+
+    public void setCancelFollow(Long cancelFollow) {
+        this.cancelFollow = cancelFollow;
+    }
+
+    public Long getBlock() {
+        return block;
+    }
+
+    public void setBlock(Long block) {
+        this.block = block;
+    }
+
+    public Long getNagative() {
+        return nagative;
+    }
+
+    public void setNagative(Long nagative) {
+        this.nagative = nagative;
+    }
+
+    public Long getDownloadStarted() {
+        return downloadStarted;
+    }
+
+    public void setDownloadStarted(Long downloadStarted) {
+        this.downloadStarted = downloadStarted;
+    }
+
+    public Long getDownloadCompleted() {
+        return downloadCompleted;
+    }
+
+    public void setDownloadCompleted(Long downloadCompleted) {
+        this.downloadCompleted = downloadCompleted;
+    }
+
+    public String getCampaignName() {
+        return campaignName;
+    }
+
+    public void setCampaignName(String campaignName) {
+        this.campaignName = campaignName;
+    }
+
+    public Long getCampaignId() {
+        return campaignId;
+    }
+
+    public void setCampaignId(Long campaignId) {
+        this.campaignId = campaignId;
+    }
+}

+ 312 - 0
jeecg-boot-module-system/src/main/java/org/jeecg/modules/excelutil/entity/EffecfReportProjectEntity.java

@@ -0,0 +1,312 @@
+package org.jeecg.modules.excelutil.entity;
+
+import com.alibaba.excel.annotation.ExcelProperty;
+import com.alibaba.excel.metadata.BaseRowModel;
+
+import java.math.BigDecimal;
+
+/**
+ * @author 宋英豪
+ */
+public class EffecfReportProjectEntity extends BaseRowModel {
+    @ExcelProperty(index = 1, value = "项目名称")
+    private String projectName;
+    @ExcelProperty(index = 2, value = "运营负责人")
+    private String responsibleName;
+    @ExcelProperty(index = 3, value = "广告主")
+    private String advertiserName;
+    @ExcelProperty(index = 4, value = "设计负责人")
+    private String designResponsibleName;
+    @ExcelProperty(index = 5, value = "消耗")
+    private BigDecimal charge;
+    @ExcelProperty(index = 6, value = "封面曝光数")
+    private Long photoShow;
+    @ExcelProperty(index = 7, value = "封面点击数")
+    private Long photoClick;
+    @ExcelProperty(index = 8, value = "素材曝光数")
+    private Long aclick;
+    @ExcelProperty(index = 9, value = "行为数")
+    private Long bclick;
+    @ExcelProperty(index = 10, value = "激活数")
+    private Long activation;
+    @ExcelProperty(index = 11, value = "提交按钮点击数")
+    private Long submit;
+    @ExcelProperty(index = 12, value = "注册数")
+    private Long eventRegister;
+    @ExcelProperty(index = 13, value = "次日留存数")
+    private Long eventNextDayStay;
+    @ExcelProperty(index = 14, value = "次日留存成本")
+    private BigDecimal eventNextDayStayCost;
+    @ExcelProperty(index = 15, value = "激活成本")
+    private BigDecimal activationCost;
+    @ExcelProperty(index = 16, value = "封面点击率")
+    private String photoClickRate;
+    @ExcelProperty(index = 17, value = "行为率")
+    private String bclickRate;
+    @ExcelProperty(index = 18, value = "千次封面曝光花费")
+    private BigDecimal impression1kCost;
+    @ExcelProperty(index = 19, value = "封面点击单价")
+    private BigDecimal photoClickCost;
+    @ExcelProperty(index = 20, value = "行为单价")
+    private BigDecimal actionCost;
+    @ExcelProperty(index = 21, value = "分项数")
+    private Long photoShare;
+    @ExcelProperty(index = 22, value = "评论数")
+    private Long photoComment;
+    @ExcelProperty(index = 23, value = "点赞数")
+    private Long photoLike;
+    @ExcelProperty(index = 24, value = "新增关注数")
+    private Long follow;
+    @ExcelProperty(index = 25, value = "举报数")
+    private Long report;
+    @ExcelProperty(index = 26, value = "取关数")
+    private Long cancelFollow;
+    @ExcelProperty(index = 27, value = "拉黑数")
+    private Long block;
+    @ExcelProperty(index = 28, value = "减少此类作品数")
+    private Long nagative;
+    @ExcelProperty(index = 29, value = "安卓下载开始数")
+    private Long downloadStarted;
+    @ExcelProperty(index = 30, value = "安卓下载完成数")
+    private Long downloadCompleted;
+
+    public String getProjectName() {
+        return projectName;
+    }
+
+    public void setProjectName(String projectName) {
+        this.projectName = projectName;
+    }
+
+    public String getResponsibleName() {
+        return responsibleName;
+    }
+
+    public void setResponsibleName(String responsibleName) {
+        this.responsibleName = responsibleName;
+    }
+
+    public String getAdvertiserName() {
+        return advertiserName;
+    }
+
+    public void setAdvertiserName(String advertiserName) {
+        this.advertiserName = advertiserName;
+    }
+
+    public String getDesignResponsibleName() {
+        return designResponsibleName;
+    }
+
+    public void setDesignResponsibleName(String designResponsibleName) {
+        this.designResponsibleName = designResponsibleName;
+    }
+
+    public BigDecimal getCharge() {
+        return charge;
+    }
+
+    public void setCharge(BigDecimal charge) {
+        this.charge = charge;
+    }
+
+    public Long getPhotoShow() {
+        return photoShow;
+    }
+
+    public void setPhotoShow(Long photoShow) {
+        this.photoShow = photoShow;
+    }
+
+    public Long getPhotoClick() {
+        return photoClick;
+    }
+
+    public void setPhotoClick(Long photoClick) {
+        this.photoClick = photoClick;
+    }
+
+    public Long getAclick() {
+        return aclick;
+    }
+
+    public void setAclick(Long aclick) {
+        this.aclick = aclick;
+    }
+
+    public Long getBclick() {
+        return bclick;
+    }
+
+    public void setBclick(Long bclick) {
+        this.bclick = bclick;
+    }
+
+    public Long getActivation() {
+        return activation;
+    }
+
+    public void setActivation(Long activation) {
+        this.activation = activation;
+    }
+
+    public Long getSubmit() {
+        return submit;
+    }
+
+    public void setSubmit(Long submit) {
+        this.submit = submit;
+    }
+
+    public Long getEventRegister() {
+        return eventRegister;
+    }
+
+    public void setEventRegister(Long eventRegister) {
+        this.eventRegister = eventRegister;
+    }
+
+    public Long getEventNextDayStay() {
+        return eventNextDayStay;
+    }
+
+    public void setEventNextDayStay(Long eventNextDayStay) {
+        this.eventNextDayStay = eventNextDayStay;
+    }
+
+    public BigDecimal getEventNextDayStayCost() {
+        return eventNextDayStayCost;
+    }
+
+    public void setEventNextDayStayCost(BigDecimal eventNextDayStayCost) {
+        this.eventNextDayStayCost = eventNextDayStayCost;
+    }
+
+    public BigDecimal getActivationCost() {
+        return activationCost;
+    }
+
+    public void setActivationCost(BigDecimal activationCost) {
+        this.activationCost = activationCost;
+    }
+
+    public String getPhotoClickRate() {
+        return photoClickRate;
+    }
+
+    public void setPhotoClickRate(String photoClickRate) {
+        this.photoClickRate = photoClickRate;
+    }
+
+    public String getBclickRate() {
+        return bclickRate;
+    }
+
+    public void setBclickRate(String bclickRate) {
+        this.bclickRate = bclickRate;
+    }
+
+    public BigDecimal getImpression1kCost() {
+        return impression1kCost;
+    }
+
+    public void setImpression1kCost(BigDecimal impression1kCost) {
+        this.impression1kCost = impression1kCost;
+    }
+
+    public BigDecimal getPhotoClickCost() {
+        return photoClickCost;
+    }
+
+    public void setPhotoClickCost(BigDecimal photoClickCost) {
+        this.photoClickCost = photoClickCost;
+    }
+
+    public BigDecimal getActionCost() {
+        return actionCost;
+    }
+
+    public void setActionCost(BigDecimal actionCost) {
+        this.actionCost = actionCost;
+    }
+
+    public Long getPhotoShare() {
+        return photoShare;
+    }
+
+    public void setPhotoShare(Long photoShare) {
+        this.photoShare = photoShare;
+    }
+
+    public Long getPhotoComment() {
+        return photoComment;
+    }
+
+    public void setPhotoComment(Long photoComment) {
+        this.photoComment = photoComment;
+    }
+
+    public Long getPhotoLike() {
+        return photoLike;
+    }
+
+    public void setPhotoLike(Long photoLike) {
+        this.photoLike = photoLike;
+    }
+
+    public Long getFollow() {
+        return follow;
+    }
+
+    public void setFollow(Long follow) {
+        this.follow = follow;
+    }
+
+    public Long getReport() {
+        return report;
+    }
+
+    public void setReport(Long report) {
+        this.report = report;
+    }
+
+    public Long getCancelFollow() {
+        return cancelFollow;
+    }
+
+    public void setCancelFollow(Long cancelFollow) {
+        this.cancelFollow = cancelFollow;
+    }
+
+    public Long getBlock() {
+        return block;
+    }
+
+    public void setBlock(Long block) {
+        this.block = block;
+    }
+
+    public Long getNagative() {
+        return nagative;
+    }
+
+    public void setNagative(Long nagative) {
+        this.nagative = nagative;
+    }
+
+    public Long getDownloadStarted() {
+        return downloadStarted;
+    }
+
+    public void setDownloadStarted(Long downloadStarted) {
+        this.downloadStarted = downloadStarted;
+    }
+
+    public Long getDownloadCompleted() {
+        return downloadCompleted;
+    }
+
+    public void setDownloadCompleted(Long downloadCompleted) {
+        this.downloadCompleted = downloadCompleted;
+    }
+}

+ 5 - 4
jeecg-boot-module-system/src/test/java/org/jeecg/SampleTest.java

@@ -43,10 +43,11 @@ public class SampleTest {
 
     @Test
     public void loadBytedanceCreativeData() {
-        List<UserAllocation>allocations = allocationService.getByParams(428L,null,0);
-        for(UserAllocation allocation:allocations){
-            CtopOauthToken token = oauthTokenService.getTokenByAccountId(allocation.getAccountId());
-            reportService.getAdvertiserReport(token,new Date(),new Date(),CtopAdConstant.BYTEDANCE_REPORT_TYPE_HOURLY);
+        String accountIdString = "1661556811389966,1650504410207245,1652711697337351,1652711697724429,1650504410574859,1668459522250759";
+        String[] accountIds = accountIdString.split(",");
+        for(int i=0;i<accountIds.length;i++){
+            CtopOauthToken token = oauthTokenService.getTokenByAccountId(Long.parseLong(accountIds[i]));
+            reportService.getAdvertiserPlanReport(token,new Date(),new Date(),CtopAdConstant.BYTEDANCE_REPORT_TYPE_HOURLY);
         }
     }
 

+ 1 - 1
module-common/src/main/java/cn/com/ctop/common/module/service/ITagInfoService.java

@@ -14,7 +14,7 @@ import java.util.List;
  */
 public interface ITagInfoService extends IService<TagInfo> {
 
-    List<TagInfoTreeModel> queryTreeList();
+    List<TagInfoTreeModel> queryTreeList(String userId);
 
     TagInfo getByTagCode(String tagCode);
 }

+ 4 - 6
module-common/src/main/java/cn/com/ctop/common/module/service/impl/TagInfoServiceImpl.java

@@ -5,10 +5,8 @@ import cn.com.ctop.common.module.mapper.TagInfoMapper;
 import cn.com.ctop.common.module.model.TagInfoTreeModel;
 import cn.com.ctop.common.module.service.ITagInfoService;
 import cn.com.ctop.common.module.utils.FindstagInfosChildrenUtil;
-import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
 import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
-import org.jeecg.common.constant.CommonConstant;
 import org.springframework.stereotype.Service;
 
 import java.util.List;
@@ -26,10 +24,10 @@ public class TagInfoServiceImpl extends ServiceImpl<TagInfoMapper, TagInfo> impl
      * queryTreeList 对应 queryTreeList 查询所有的部门数据,以树结构形式响应给前端
      */
     @Override
-    public List<TagInfoTreeModel> queryTreeList() {
-        LambdaQueryWrapper<TagInfo> query = new LambdaQueryWrapper<>();
-        query.eq(TagInfo::getDelFlag, CommonConstant.DEL_FLAG_0.toString());
-        query.orderByAsc(TagInfo::getTagOrder);
+    public List<TagInfoTreeModel> queryTreeList(String userId) {
+        QueryWrapper<TagInfo> query = new QueryWrapper<>();
+        query.eq("del_flag", "0").or(wrapper->wrapper.eq("status",0).eq("user_id",userId));
+        query.orderByAsc("tag_order");
         List<TagInfo> list = this.list(query);
         // 调用wrapTreeDataToTreeList方法生成树状数据
         List<TagInfoTreeModel> listResult = FindstagInfosChildrenUtil.wrapTreeDataToTreeList(list);

+ 1 - 1
jeecg-boot-module-system/src/main/java/org/jeecg/modules/ctop/vo/SheetInfoVo.java

@@ -1,4 +1,4 @@
-package org.jeecg.modules.ctop.vo;
+package cn.com.ctop.common.module.vo;
 
 import java.util.List;
 

+ 0 - 3
module-crawler/src/main/java/cn/com/ctop/crawler/modules/core/service/impl/KuaishouCrawlerServiceImpl.java

@@ -10,7 +10,6 @@ import cn.com.ctop.crawler.modules.core.service.IKuaishouCrawlerService;
 import cn.com.ctop.crawler.modules.core.util.KuaishouUtil;
 import cn.com.ctop.crawler.modules.log.entity.CrawlerLog;
 import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.context.annotation.Primary;
 import org.springframework.stereotype.Service;
 
 import java.io.UnsupportedEncodingException;
@@ -18,8 +17,6 @@ import java.net.URLEncoder;
 import java.util.Random;
 
 @Service
-@Primary
-
 public class KuaishouCrawlerServiceImpl implements IKuaishouCrawlerService {
     @Autowired
     private IIpPoolService iIpPoolService;

+ 6 - 17
module-kuaishou/src/main/java/cn/com/ctop/kuaishou/modules/batch/controller/KuaiShouController.java

@@ -7,16 +7,15 @@ import cn.com.ctop.kuaishou.modules.report.entity.KuaishouInfoDTO;
 import cn.com.ctop.kuaishou.modules.report.entity.KuaishouReportDailyAccountDTO;
 import cn.com.ctop.kuaishou.modules.report.entity.ProjectAccountDTO;
 import cn.com.ctop.kuaishou.modules.report.service.IKuaishouReportDailyAccountService;
-import com.baomidou.mybatisplus.extension.api.R;
-import com.github.pagehelper.Page;
 import com.github.pagehelper.PageInfo;
 import lombok.extern.slf4j.Slf4j;
 import org.jeecg.common.api.vo.Result;
 import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.web.bind.annotation.*;
+import org.springframework.web.bind.annotation.RequestBody;
+import org.springframework.web.bind.annotation.RequestMapping;
+import org.springframework.web.bind.annotation.RestController;
 
 import java.util.HashMap;
-import java.util.List;
 import java.util.Map;
 
 /**
@@ -69,8 +68,6 @@ public class KuaiShouController {
         return result;
     }
 
-
-    @ResponseBody
     @RequestMapping("/getKuaishouProjectInfo")
     public Result<PageInfo<ProjectAccountDTO>> getKuaishouProjectInfo(@RequestBody KuaishouInfoDTO dto) {
         Result<PageInfo<ProjectAccountDTO>> result = new Result<>();
@@ -94,11 +91,10 @@ public class KuaiShouController {
             result.setMessage("执行出错");
         }finally {
         }
-
         return result;
     }
 
-    @ResponseBody
+
     @RequestMapping("/getKuaishouSaleProjectInfo")
     public Result<PageInfo<ProjectAccountDTO>> getKuaishouSaleProjectInfo(@RequestBody KuaishouInfoDTO dto) {
         Result<PageInfo<ProjectAccountDTO>> result = new Result<>();
@@ -126,8 +122,6 @@ public class KuaiShouController {
         return result;
     }
 
-
-    @ResponseBody
     @RequestMapping("/getKuaishouAccountInfoByProjectId")
     public Result<PageInfo<KuaishouReportDailyAccountDTO>> getKuaishouAccountInfoByProjectId(@RequestBody KuaishouInfoDTO dto) {
         Result<PageInfo<KuaishouReportDailyAccountDTO>> result = new Result<>();
@@ -156,7 +150,6 @@ public class KuaiShouController {
         return result;
     }
 
-    @ResponseBody
     @RequestMapping("/getKuaishouSaleAccountInfoByProjectId")
     public Result<PageInfo<KuaishouReportDailyAccountDTO>> getKuaishouSaleAccountInfoByProjectId(@RequestBody KuaishouInfoDTO dto) {
         Result<PageInfo<KuaishouReportDailyAccountDTO>> result = new Result<>();
@@ -185,7 +178,6 @@ public class KuaiShouController {
         return result;
     }
 
-    @ResponseBody
     @RequestMapping("/getKuaishouCampaignInfoByAccountId")
     public Result<PageInfo<KuaishouReportDailyAccountDTO>> getKuaishouCampaignInfoByAccountId(@RequestBody KuaishouInfoDTO dto) {
         Result<PageInfo<KuaishouReportDailyAccountDTO>> result = new Result<>();
@@ -214,8 +206,6 @@ public class KuaiShouController {
         return result;
     }
 
-
-    @ResponseBody
     @RequestMapping("/getKuaishouUnitInfoByCampaignId")
     public Result<PageInfo<KuaishouReportDailyAccountDTO>> getKuaishouUnitInfoByCampaignId(@RequestBody KuaishouInfoDTO dto) {
         Result<PageInfo<KuaishouReportDailyAccountDTO>> result = new Result<>();
@@ -243,7 +233,6 @@ public class KuaiShouController {
         return result;
     }
 
-    @ResponseBody
     @RequestMapping("/getKuaishouCreativeInfoByUnitId")
     public Result<PageInfo<KuaishouReportDailyAccountDTO>> getKuaishouCreativeInfoByUnitId(@RequestBody KuaishouInfoDTO dto) {
         Result<PageInfo<KuaishouReportDailyAccountDTO>> result = new Result<>();
@@ -261,13 +250,13 @@ public class KuaiShouController {
         try{
             PageInfo<KuaishouReportDailyAccountDTO> kuaishouCampaignInfoList = accountService.getKuaishouCreativeInfoByUnitId(dto.getProjectList(), dto.getUnitId(), dto.getStartDate(), dto.getEndDate(),dto.getPageSize(),dto.getPageNum(),dto.getYn());
             result.setResult(kuaishouCampaignInfoList);
+            return result;
         }catch(Exception e){
             log.error(e.getMessage());
             result.setSuccess(false);
             result.setMessage("执行出错");
-        }finally {
+            return result;
         }
 
-        return result;
     }
 }

+ 10 - 3
module-kuaishou/src/main/java/cn/com/ctop/kuaishou/modules/report/entity/KuaishouInfoDTO.java

@@ -1,11 +1,9 @@
 package cn.com.ctop.kuaishou.modules.report.entity;
 
 import com.github.pagehelper.PageInfo;
-import com.github.pagehelper.page.PageMethod;
 import lombok.Data;
 
 import java.io.Serializable;
-import java.math.BigDecimal;
 import java.util.List;
 
 
@@ -15,8 +13,17 @@ public class KuaishouInfoDTO extends PageInfo implements Serializable {
     private String endDate;
     private Long unitId;
     private List<Long> projectList;
-    private Long accountId;  //广告主名称
+    //广告主名称
     private Long campaignId;
+    private Long accountId;
+    /**
+     * project
+     * account
+     * campaign
+     * group
+     * creative
+     */
+    private String type;
     private Long projectId;
     private Integer yn;
 

+ 47 - 58
module-kuaishou/src/main/java/cn/com/ctop/kuaishou/modules/report/mapper/xml/KuaishouReportDailyAccountMapper.xml

@@ -4,66 +4,66 @@
 
     <resultMap id="BaseResultMap" type="cn.com.ctop.kuaishou.modules.report.entity.KuaishouReportDailyAccount">
         <id column="id" property="id" jdbcType="BIGINT"/>
-        <result column="account_id" property="account_id" jdbcType="BIGINT"/>
+        <result column="account_id" property="accountId" jdbcType="BIGINT"/>
         <result column="charge" property="charge" jdbcType="DECIMAL"/>
-        <result column="photo_show" property="photo_show" jdbcType="BIGINT"/>
+        <result column="photo_show" property="photoShow" jdbcType="BIGINT"/>
         <result column="aclick" property="aclick" jdbcType="BIGINT"/>
         <result column="bclick" property="bclick" jdbcType="BIGINT"/>
-        <result column="photo_share" property="photo_share" jdbcType="BIGINT"/>
-        <result column="photo_comment" property="photo_comment" jdbcType="BIGINT"/>
-        <result column="photo_like" property="photo_like" jdbcType="BIGINT"/>
+        <result column="photo_share" property="photoShare" jdbcType="BIGINT"/>
+        <result column="photo_comment" property="photoComment" jdbcType="BIGINT"/>
+        <result column="photo_like" property="photoLike" jdbcType="BIGINT"/>
         <result column="follow" property="follow" jdbcType="BIGINT"/>
-        <result column="cancel_follow" property="cancel_follow" jdbcType="BIGINT"/>
+        <result column="cancel_follow" property="cancelFollow" jdbcType="BIGINT"/>
         <result column="report" property="report" jdbcType="BIGINT"/>
         <result column="block" property="block" jdbcType="BIGINT"/>
         <result column="negative" property="negative" jdbcType="BIGINT"/>
-        <result column="download_started" property="download_started" jdbcType="BIGINT"/>
-        <result column="download_completed" property="download_completed" jdbcType="BIGINT"/>
+        <result column="download_started" property="downloadStarted" jdbcType="BIGINT"/>
+        <result column="download_completed" property="downloadCompleted" jdbcType="BIGINT"/>
         <result column="activation" property="activation" jdbcType="BIGINT"/>
         <result column="submit" property="submit" jdbcType="BIGINT"/>
-        <result column="stat_date" property="stat_date" jdbcType="VARCHAR"/>
-        <result column="photo_click" property="photo_click" jdbcType="BIGINT"/>
-        <result column="photo_click_ratio" property="photo_click_ratio" jdbcType="DOUBLE"/>
-        <result column="action_ratio" property="action_ratio" jdbcType="DOUBLE"/>
-        <result column="impression_1k_cost" property="impression_1k_cost" jdbcType="DECIMAL"/>
-        <result column="photo_click_cost" property="photo_click_cost" jdbcType="DECIMAL"/>
-        <result column="action_cost" property="action_cost" jdbcType="DECIMAL"/>
-        <result column="event_pay_first_day" property="event_pay_first_day" jdbcType="BIGINT"/>
-        <result column="event_pay_purchase_amount_first_day" property="event_pay_purchase_amount_first_day"
+        <result column="stat_date" property="statDate" jdbcType="VARCHAR"/>
+        <result column="photo_click" property="photoClick" jdbcType="BIGINT"/>
+        <result column="photo_click_ratio" property="photoClickRatio" jdbcType="DOUBLE"/>
+        <result column="action_ratio" property="actionRatio" jdbcType="DOUBLE"/>
+        <result column="impression_1k_cost" property="impression1kCost" jdbcType="DECIMAL"/>
+        <result column="photo_click_cost" property="photoClickCost" jdbcType="DECIMAL"/>
+        <result column="action_cost" property="actionCost" jdbcType="DECIMAL"/>
+        <result column="event_pay_first_day" property="eventPayFirstDay" jdbcType="BIGINT"/>
+        <result column="event_pay_purchase_amount_first_day" property="eventPayPurchaseAmountFirstDay"
                 jdbcType="DECIMAL"/>
-        <result column="event_pay_first_day_roi" property="event_pay_first_day_roi" jdbcType="DOUBLE"/>
-        <result column="event_pay" property="event_pay" jdbcType="BIGINT"/>
-        <result column="event_pay_purchase_amount" property="event_pay_purchase_amount" jdbcType="DECIMAL"/>
-        <result column="event_pay_roi" property="event_pay_roi" jdbcType="DOUBLE"/>
-        <result column="event_register" property="event_register" jdbcType="BIGINT"/>
-        <result column="event_register_cost" property="event_register_cost" jdbcType="DECIMAL"/>
-        <result column="event_register_ratio" property="event_register_ratio" jdbcType="DOUBLE"/>
-        <result column="event_jin_jian_app" property="event_jin_jian_app" jdbcType="BIGINT"/>
-        <result column="event_jin_jian_app_cost" property="event_jin_jian_app_cost" jdbcType="DECIMAL"/>
-        <result column="event_credit_grant_app" property="event_credit_grant_app" jdbcType="BIGINT"/>
-        <result column="event_credit_grant_app_cost" property="event_credit_grant_app_cost" jdbcType="DECIMAL"/>
-        <result column="event_credit_grant_app_ratio" property="event_credit_grant_app_ratio" jdbcType="DOUBLE"/>
-        <result column="event_order_paid" property="event_order_paid" jdbcType="BIGINT"/>
-        <result column="event_order_paid_purchase_amount" property="event_order_paid_purchase_amount"
+        <result column="event_pay_first_day_roi" property="eventPayFirstDayRoi" jdbcType="DOUBLE"/>
+        <result column="event_pay" property="eventPay" jdbcType="BIGINT"/>
+        <result column="event_pay_purchase_amount" property="eventPayPurchaseAmount" jdbcType="DECIMAL"/>
+        <result column="event_pay_roi" property="eventPayRoi" jdbcType="DOUBLE"/>
+        <result column="event_register" property="eventRegister" jdbcType="BIGINT"/>
+        <result column="event_register_cost" property="eventRegisterCost" jdbcType="DECIMAL"/>
+        <result column="event_register_ratio" property="eventRegisterRatio" jdbcType="DOUBLE"/>
+        <result column="event_jin_jian_app" property="eventJinJianApp" jdbcType="BIGINT"/>
+        <result column="event_jin_jian_app_cost" property="eventJinJianAppCost" jdbcType="DECIMAL"/>
+        <result column="event_credit_grant_app" property="eventCreditGrantApp" jdbcType="BIGINT"/>
+        <result column="event_credit_grant_app_cost" property="eventCreditGrantAppCost" jdbcType="DECIMAL"/>
+        <result column="event_credit_grant_app_ratio" property="eventCreditGrantAppRatio" jdbcType="DOUBLE"/>
+        <result column="event_order_paid" property="eventOrderPaid" jdbcType="BIGINT"/>
+        <result column="event_order_paid_purchase_amount" property="eventOrderPaidPurchaseAmount"
                 jdbcType="DECIMAL"/>
-        <result column="event_jin_jian_landing_page" property="event_jin_jian_landing_page" jdbcType="BIGINT"/>
-        <result column="event_jin_jian_landing_page_cost" property="event_jin_jian_landing_page_cost"
+        <result column="event_jin_jian_landing_page" property="eventJinJianLandingPage" jdbcType="BIGINT"/>
+        <result column="event_jin_jian_landing_page_cost" property="eventJinJianLandingPageCost"
                 jdbcType="DECIMAL"/>
-        <result column="event_credit_grant_landing_page" property="event_credit_grant_landing_page" jdbcType="BIGINT"/>
-        <result column="event_credit_grant_landing_page_cost" property="event_credit_grant_landing_page_cost"
+        <result column="event_credit_grant_landing_page" property="eventCreditGrantLandingPage" jdbcType="BIGINT"/>
+        <result column="event_credit_grant_landing_page_cost" property="eventCreditGrantLandingPageCost"
                 jdbcType="DECIMAL"/>
-        <result column="event_credit_grant_landing_ratio" property="event_credit_grant_landing_ratio"
+        <result column="event_credit_grant_landing_ratio" property="eventCreditGrantLandingRatio"
                 jdbcType="DOUBLE"/>
-        <result column="event_next_day_stay_cost" property="event_next_day_stay_cost" jdbcType="DECIMAL"/>
-        <result column="event_next_day_stay_ratio" property="event_next_day_stay_ratio" jdbcType="BIGINT"/>
-        <result column="form_action_ratio" property="form_action_ratio" jdbcType="DOUBLE"/>
-        <result column="event_order_paid_cost" property="event_order_paid_cost" jdbcType="DECIMAL"/>
-        <result column="event_next_day_stay" property="event_next_day_stay" jdbcType="BIGINT"/>
-        <result column="form_cost" property="form_cost" jdbcType="DECIMAL"/>
-        <result column="form_count" property="form_count" jdbcType="BIGINT"/>
-        <result column="play_3s_ratio" property="play_3s_ratio" jdbcType="DOUBLE"/>
-        <result column="create_time" property="create_time" jdbcType="TIMESTAMP"/>
-        <result column="update_time" property="update_time" jdbcType="TIMESTAMP"/>
+        <result column="event_next_day_stay_cost" property="eventNextDayStayCost" jdbcType="DECIMAL"/>
+        <result column="event_next_day_stay_ratio" property="eventNextDayStayRatio" jdbcType="BIGINT"/>
+        <result column="form_action_ratio" property="formActionRatio" jdbcType="DOUBLE"/>
+        <result column="event_order_paid_cost" property="eventOrderPaidCost" jdbcType="DECIMAL"/>
+        <result column="event_next_day_stay" property="eventNextDayStay" jdbcType="BIGINT"/>
+        <result column="form_cost" property="formCost" jdbcType="DECIMAL"/>
+        <result column="form_count" property="formCount" jdbcType="BIGINT"/>
+        <result column="play_3s_ratio" property="play3sRatio" jdbcType="DOUBLE"/>
+        <result column="create_time" property="createTime" jdbcType="TIMESTAMP"/>
+        <result column="update_time" property="updateTime" jdbcType="TIMESTAMP"/>
     </resultMap>
 
     <sql id="Base_Column_List">
@@ -538,8 +538,6 @@
     </select>
 
     <select id="getKuaishouAccountInfoByProjectId" resultType="cn.com.ctop.kuaishou.modules.report.entity.KuaishouReportDailyAccountDTO">
         select
         #{yn} as 'yn',
         concat(#{startDate}, '~' ,#{endDate}) as 'statDate',
@@ -623,17 +621,11 @@
         </if>
         group by a.account_id
         order by sum(a.charge) desc
-<!--        )m-->
-<!--        <if test="yn=1">-->
-<!--            where-->
-<!--            m.charge != 0-->
-<!--        </if>-->
     </select>
 
     <select id="getKuaishouProjectInfo" resultType="cn.com.ctop.kuaishou.modules.report.entity.ProjectAccountDTO">
              select
-        #{yn} as 'yn',
+            #{yn} as 'yn',
             concat(#{startDate}, '~' , #{endDate}) as 'statDate',
             (select project_id from ctop_user_allocation where account_id = a.account_id limit 1) as 'projectId',
             (select project_name from ctop_user_allocation where account_id = a.account_id limit 1) as 'projectName',
@@ -694,7 +686,6 @@
             from
             ctop_kuaishou_report_daily_account a
             left join  (select * from ctop_user_allocation group by account_id) b on a.account_id = b.account_id
-            -- left join ctop_project c on b.project_id = c.id
             where
             a.stat_date &gt;= #{startDate}
             and
@@ -707,11 +698,6 @@
             </foreach>
             group by b.project_id
             order by sum(a.charge) desc
-<!--        ) m-->
-<!--        <if test="yn = 1">-->
-<!--        where-->
-<!--            m.charge != 0-->
-<!--        </if>-->
     </select>
 
     <!-- 计划汇总 -->

+ 12 - 28
module-kuaishou/src/main/java/cn/com/ctop/kuaishou/modules/report/service/impl/KuaishouReportDailyAccountServiceImpl.java

@@ -2,7 +2,6 @@ package cn.com.ctop.kuaishou.modules.report.service.impl;
 
 import cn.com.ctop.kuaishou.modules.report.entity.KuaishouReportDailyAccount;
 import cn.com.ctop.kuaishou.modules.report.entity.KuaishouReportDailyAccountDTO;
-import cn.com.ctop.kuaishou.modules.report.entity.KuaishouVideoInfoDTO;
 import cn.com.ctop.kuaishou.modules.report.entity.ProjectAccountDTO;
 import cn.com.ctop.kuaishou.modules.report.mapper.KuaishouReportDailyAccountMapper;
 import cn.com.ctop.kuaishou.modules.report.service.IKuaishouReportDailyAccountService;
@@ -11,12 +10,10 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
 import com.github.pagehelper.PageHelper;
 import com.github.pagehelper.PageInfo;
 import org.apache.shiro.SecurityUtils;
-import org.apache.shiro.mgt.SecurityManager;
 import org.jeecg.common.system.vo.LoginUser;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
 
-import java.math.BigDecimal;
 import java.util.ArrayList;
 import java.util.List;
 
@@ -34,11 +31,8 @@ public class KuaishouReportDailyAccountServiceImpl extends ServiceImpl<KuaishouR
     //获取快手参与的项目的信息
     @Override
     public PageInfo<ProjectAccountDTO> getKuaishouProjectInfo(String startDate, String endDate, List<Long> projectList, Integer pageSize, Integer pageNum, String sort ,Integer yn){
-        List<ProjectAccountDTO> projectAccountDTOList = new ArrayList<>();
-
         if(projectList==null || projectList.size()==0){
             LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
-            //String userId = "a6abfea0f27843bf8595a234410afb04";
             String userId = sysUser.getId();
             String roleCode = dailyAccountMapper.getRoleCodeByUserId(userId);
 
@@ -59,11 +53,8 @@ public class KuaishouReportDailyAccountServiceImpl extends ServiceImpl<KuaishouR
 
     @Override
     public PageInfo<ProjectAccountDTO> getKuaishouSaleProjectInfo(String startDate, String endDate, List<Long> projectList, Integer pageSize, Integer pageNum, String sort,Integer yn ){
-        List<ProjectAccountDTO> projectAccountDTOList = new ArrayList<>();
-
         if(projectList==null || projectList.size()==0){
             LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
-            //String userId = "e9ca23d68d884d4ebb19d07889727dae";
             String userId = sysUser.getId();
             String roleCode = dailyAccountMapper.getRoleCodeByUserId(userId);
 
@@ -85,7 +76,6 @@ public class KuaishouReportDailyAccountServiceImpl extends ServiceImpl<KuaishouR
     @Override
     public PageInfo<KuaishouReportDailyAccountDTO> getKuaishouSaleAccountInfoByProjectId(List<Long> projectList, Long projectId, String startDate, String endDate, Integer pageSize, Integer pageNum, Integer yn){
         LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
-        //String userId = "e9ca23d68d884d4ebb19d07889727dae";
         String userId = sysUser.getId();
         String roleCode = dailyAccountMapper.getRoleCodeByUserId(userId);
 
@@ -106,14 +96,8 @@ public class KuaishouReportDailyAccountServiceImpl extends ServiceImpl<KuaishouR
     @Override
     public PageInfo<KuaishouReportDailyAccountDTO> getKuaishouAccountInfoByProjectId(Long projectId, List<Long> projectList, String startDate, String endDate, Integer pageSize, Integer pageNum, Integer yn){
         LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
-        //String userId = "e9ca23d68d884d4ebb19d07889727dae";
         String userId = sysUser.getId();
         String roleCode = dailyAccountMapper.getRoleCodeByUserId(userId);
-
-        //List<Long> mediaIds = new ArrayList<>();
-        //mediaIds.add(2L);
-        //mediaIds.add(4L);
-
         List<Long> accountIds = null;
         if(projectId==null && projectList==null){
             if("admin".equals(roleCode)){
@@ -124,13 +108,15 @@ public class KuaishouReportDailyAccountServiceImpl extends ServiceImpl<KuaishouR
         }
 
         PageHelper.startPage(pageNum,pageSize);
+        if(null == projectList||projectList.isEmpty()){
+            projectList = null;
+        }
         return new PageInfo<>(dailyAccountMapper.getKuaishouAccountInfoByProjectId(projectId, startDate, endDate, projectList, accountIds, yn));
     }
 
     @Override
     public PageInfo<KuaishouReportDailyAccountDTO> getKuaishouCampaignInfoByAccountId(List<Long> projectList, Long accountId, String startDate, String endDate, Integer pageSize, Integer pageNum, Integer yn){
         LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
-        //String userId = "e9ca23d68d884d4ebb19d07889727dae";
         String userId = sysUser.getId();
         String roleCode = dailyAccountMapper.getRoleCodeByUserId(userId);
 
@@ -142,16 +128,16 @@ public class KuaishouReportDailyAccountServiceImpl extends ServiceImpl<KuaishouR
                 accountIds = dailyAccountMapper.getUserProjectAccountIds(userId,1);
             }
         }
-
+        if(null == projectList||projectList.isEmpty()){
+            projectList = null;
+        }
         PageHelper.startPage(pageNum,pageSize);
         return new PageInfo<>(dailyAccountMapper.getKuaishouCampaignInfoByAccountId(projectList, startDate, endDate, accountId,accountIds,yn));
     }
 
     @Override
     public PageInfo<KuaishouReportDailyAccountDTO> getKuaishouUnitInfoByCampaignId(List<Long> projectList, Long campaignId, String startDate, String endDate, Integer pageSize, Integer pageNum, Integer yn){
-
         LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
-        //String userId = "e9ca23d68d884d4ebb19d07889727dae";
         String userId = sysUser.getId();
         String roleCode = dailyAccountMapper.getRoleCodeByUserId(userId);
 
@@ -163,7 +149,9 @@ public class KuaishouReportDailyAccountServiceImpl extends ServiceImpl<KuaishouR
                 accountIds = dailyAccountMapper.getUserProjectAccountIds(userId,1);
             }
         }
-
+        if(null == projectList||projectList.isEmpty()){
+            projectList = null;
+        }
         PageHelper.startPage(pageNum,pageSize);
         return new PageInfo<>(dailyAccountMapper.getKuaishouUnitInfoByCampaignId(projectList, startDate, endDate, campaignId,accountIds, yn));
     }
@@ -171,7 +159,6 @@ public class KuaishouReportDailyAccountServiceImpl extends ServiceImpl<KuaishouR
     @Override
     public PageInfo<KuaishouReportDailyAccountDTO> getKuaishouCreativeInfoByUnitId(List<Long> projectList, Long unitId, String startDate, String endDate, Integer pageSize, Integer pageNum, Integer yn){
         LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
-        //String userId = "e9ca23d68d884d4ebb19d07889727dae";
         String userId = sysUser.getId();
         String roleCode = dailyAccountMapper.getRoleCodeByUserId(userId);
 
@@ -183,14 +170,11 @@ public class KuaishouReportDailyAccountServiceImpl extends ServiceImpl<KuaishouR
                 accountIds = dailyAccountMapper.getUserProjectAccountIds(userId,1);
             }
         }
-
+        if(null == projectList||projectList.isEmpty()){
+            projectList = null;
+        }
         PageHelper.startPage(pageNum,pageSize);
         List<KuaishouReportDailyAccountDTO> kuaishouCreativeInfoList = dailyAccountMapper.getKuaishouCreativeInfoByUnitId(projectList, startDate, endDate, unitId,accountIds, yn);
-        //for(KuaishouReportDailyAccountDTO creativeInfo:kuaishouCreativeInfoList){
-        //    KuaishouVideoInfoDTO videoInfo = dailyAccountMapper.getVideoUrl(creativeInfo.getPhotoId());
-        //    creativeInfo.setUrl(videoInfo.getUrl());
-        //    creativeInfo.setCoverUrl(videoInfo.getCoverUrl());
-        //}
         return new PageInfo<>(kuaishouCreativeInfoList);
     }