Bläddra i källkod

Merge remote-tracking branch 'origin/master'

yumeng 4 år sedan
förälder
incheckning
ca34b88339
16 ändrade filer med 86 tillägg och 910 borttagningar
  1. 1 0
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/orderplatform/controller/OperatorApprovalProcessCtrl.java
  2. 1 1
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/orderplatform/controller/PlatformOrderCtrl.java
  3. 1 0
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/orderplatform/mapper/PlatformOrderMapper.java
  4. 3 0
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/orderplatform/mapper/xml/PlatformOrderMapper.xml
  5. 3 0
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/orderplatform/service/IPlatformOrderService.java
  6. 8 0
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/orderplatform/service/impl/PlatformOrderServiceImpl.java
  7. 4 2
      module-kuaishou/src/main/java/cn/com/ctop/kuaishou/modules/report/service/impl/KuaiShouYiCheReportServiceImpl.java
  8. 4 17
      module-toutiao/src/main/java/cn/com/ctop/toutiao/modules/report/mapper/xml/ByteDanceVideoReportDailyMapper.xml
  9. 0 261
      performance-appraisal/src/main/java/cn/com/ctop/huananvideoreport/controller/HuananVideoReportController.java
  10. 0 17
      performance-appraisal/src/main/java/cn/com/ctop/huananvideoreport/dto/HuananVideoReportDTO.java
  11. 0 121
      performance-appraisal/src/main/java/cn/com/ctop/huananvideoreport/entity/HuananVideoReport.java
  12. 0 24
      performance-appraisal/src/main/java/cn/com/ctop/huananvideoreport/mapper/HuananVideoReportMapper.java
  13. 0 294
      performance-appraisal/src/main/java/cn/com/ctop/huananvideoreport/mapper/xml/HuananVideoReportMapper.xml
  14. 0 17
      performance-appraisal/src/main/java/cn/com/ctop/huananvideoreport/service/IHuananVideoReportService.java
  15. 0 65
      performance-appraisal/src/main/java/cn/com/ctop/huananvideoreport/service/impl/HuananVideoReportServiceImpl.java
  16. 61 91
      performance-appraisal/src/main/java/cn/com/ctop/userefficientvideomap/mapper/xml/UserEfficientVideoMapMapper.xml

+ 1 - 0
jeecg-boot-module-system/src/main/java/org/jeecg/modules/orderplatform/controller/OperatorApprovalProcessCtrl.java

@@ -37,6 +37,7 @@ public class OperatorApprovalProcessCtrl {
             boolean save = platformOrderService.save(platformOrder);
             if (save) {
                 operateRecordHandler.Submit(platformOrder.getOrderCode(), "PAYOUT");
+                result.setResult(platformOrderService.queryByCode(platformOrder.getOrderCode()));
                 result.success("下单成功!");
             }
         } catch (Exception e) {

+ 1 - 1
jeecg-boot-module-system/src/main/java/org/jeecg/modules/orderplatform/controller/PlatformOrderCtrl.java

@@ -44,7 +44,7 @@ public class PlatformOrderCtrl {
 														 HttpServletRequest req) {
 		Result<PageInfo<PlatformOrder>> result = new Result<>();
 		QueryWrapper<PlatformOrder> queryWrapper = new QueryWrapper<>();
-		//发起人精准查询
+		//发起人精准匹配
 		if((null!=platformOrder.getCreateByName())){
 			SysUser sysUser=sysUserService.getUserByRealName(platformOrder.getCreateByName());
 			if(null!=sysUser){

+ 1 - 0
jeecg-boot-module-system/src/main/java/org/jeecg/modules/orderplatform/mapper/PlatformOrderMapper.java

@@ -9,4 +9,5 @@ import org.jeecg.modules.orderplatform.entity.PlatformOrder;
  */
 public interface PlatformOrderMapper extends BaseMapper<PlatformOrder> {
 
+    PlatformOrder queryByCode(String code);
 }

+ 3 - 0
jeecg-boot-module-system/src/main/java/org/jeecg/modules/orderplatform/mapper/xml/PlatformOrderMapper.xml

@@ -2,4 +2,7 @@
 <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
 <mapper namespace="org.jeecg.modules.orderplatform.mapper.PlatformOrderMapper">
 
+    <select id="queryByCode" resultType="org.jeecg.modules.orderplatform.entity.PlatformOrder">
+        select * from ctop_platform_order where order_code=#{code}
+    </select>
 </mapper>

+ 3 - 0
jeecg-boot-module-system/src/main/java/org/jeecg/modules/orderplatform/service/IPlatformOrderService.java

@@ -13,4 +13,7 @@ public interface IPlatformOrderService extends IService<PlatformOrder> {
 
     //更新订单素材完成数量
     boolean updateOrderFinishAmount(String code);
+
+    //根据orderCode查询
+    PlatformOrder queryByCode(String code);
 }

+ 8 - 0
jeecg-boot-module-system/src/main/java/org/jeecg/modules/orderplatform/service/impl/PlatformOrderServiceImpl.java

@@ -25,6 +25,9 @@ public class PlatformOrderServiceImpl extends ServiceImpl<PlatformOrderMapper, P
     @Autowired
     IPlatformMaterialService platFormMaterialService;
 
+    @Autowired
+    PlatformOrderMapper platformOrderMapper;
+
     @Override
     public boolean generateMaterials(PlatformOrder platformOrder) {
         boolean result=false;
@@ -59,6 +62,11 @@ public class PlatformOrderServiceImpl extends ServiceImpl<PlatformOrderMapper, P
         return this.updateById(platformOrder);
     }
 
+    @Override
+    public PlatformOrder queryByCode(String code) {
+        return platformOrderMapper.queryByCode(code);
+    }
+
     /**
      * 生成真人物料
      */

+ 4 - 2
module-kuaishou/src/main/java/cn/com/ctop/kuaishou/modules/report/service/impl/KuaiShouYiCheReportServiceImpl.java

@@ -114,9 +114,11 @@ public class KuaiShouYiCheReportServiceImpl implements IKuaiShouYiCheReportServi
             returnJson.put("android", androidReport);
             returnJson.remove("systemType");
             JSONObject directApplicationReport = kuaiShouYiCheReportMapper.getDirectApplicationReportByMap(requestMap);
-            returnJson.put("directApplication", directApplicationReport); // 应用直达
+            // 应用直达
+            returnJson.put("directApplication", directApplicationReport);
             List<JSONObject> channelSubcontractingReport = kuaiShouYiCheReportMapper.getChannelSubcontractingReportByMap(requestMap);
-            returnJson.put("channelSubcontracting", channelSubcontractingReport); // 渠道包分析
+            // 渠道包分析
+            returnJson.put("channelSubcontracting", channelSubcontractingReport);
 
         } catch (Exception e) {
             e.printStackTrace();

+ 4 - 17
module-toutiao/src/main/java/cn/com/ctop/toutiao/modules/report/mapper/xml/ByteDanceVideoReportDailyMapper.xml

@@ -252,10 +252,9 @@
                 a.advertiser_id as advertiserId,
                 a.advertiser_name as advertiserName,
                 a.stat_datetime as statDatetime,
-                sum(a.cost) as cost,  -- 消耗
+                sum(a.cost) as cost,
                 a.video_url as videoUrl,
                 (select info.url from ctop_material_info info where info.code = a.signature limit 1) as url,
-                -- huanbi as huanbi,
                 signature as signature
 
         from ctop_bytedance_video_report_daily a
@@ -263,9 +262,6 @@
         where
         stat_datetime &gt;= #{startDate}
         and stat_datetime &lt;= #{endDate}
-<!--        <if test=" role != 'admin' ">
-            and a.company_id = #{companyId}
-        </if>-->
         <if test="accountIds != null">
             and a.account_id in
             <foreach item="item" index="index" collection="accountIds" open="(" separator="," close=")">
@@ -285,10 +281,9 @@
         a.advertiser_id as advertiserId,
         a.advertiser_name as advertiserName,
         a.stat_datetime as statDatetime,
-        sum(a.cost) as cost,  -- 消耗
+        sum(a.cost) as cost,
         a.video_url as videoUrl,
         (select info.url from ctop_material_info info where info.code = a.signature limit 1) as url,
-        -- huanbi as huanbi,
         signature as signature
 
         from ctop_bytedance_video_report_daily a
@@ -296,7 +291,6 @@
         where
         stat_datetime &gt;= #{startDate}
         and stat_datetime &lt;= #{endDate}
-        <!-- and a.company_id = #{companyId} -->
         <if test="accountIds != null">
         and a.account_id in
             <foreach item="item" index="index" collection="accountIds" open="(" separator="," close=")">
@@ -316,10 +310,9 @@
         a.advertiser_id as advertiserId,
         a.advertiser_name as advertiserName,
         a.stat_datetime as statDatetime,
-        sum(a.cost) as cost,  -- 消耗
+        sum(a.cost) as cost,
         a.video_url as videoUrl,
         (select info.url from ctop_material_info info where info.code = a.signature limit 1) as url,
-        -- huanbi as huanbi,
         signature as signature
 
         from ctop_bytedance_video_report_daily a
@@ -327,7 +320,6 @@
         where
         stat_datetime &gt;= #{startDate}
         and stat_datetime &lt;= #{endDate}
-        <!-- and a.company_id = #{companyId} -->
         <if test="accountIds != null">
             and a.account_id in
             <foreach item="item" index="index" collection="accountIds" open="(" separator="," close=")">
@@ -347,10 +339,9 @@
         a.advertiser_id as advertiserId,
         a.advertiser_name as advertiserName,
         a.stat_datetime as statDatetime,
-        sum(a.cost) as cost,  -- 消耗
+        sum(a.cost) as cost,
         a.video_url as videoUrl,
         (select info.url from ctop_material_info info where info.code = a.signature limit 1) as url,
-        -- huanbi as huanbi,
         signature as signature
 
         from ctop_bytedance_video_report_daily a
@@ -1092,7 +1083,6 @@
         left join (select material_id,clip_id,shot_id,plan_id,plane_id from ctop_material_ascription group by material_id) f on a.signature = f.material_id
         where stat_datetime &gt;= #{startDate}
         and stat_datetime &lt;= #{endDate}
-        <!-- and a.company_id = #{companyId}  -->
         and f.material_id is not null
         and f.shot_id = #{userId}
         <if test="accountIds != null">
@@ -1194,7 +1184,6 @@
         left join (select material_id,clip_id,shot_id,plan_id,plane_id from ctop_material_ascription group by material_id) f on a.signature = f.material_id
         where stat_datetime &gt;= #{startDate}
         and stat_datetime &lt;= #{endDate}
-        <!-- and a.company_id = #{companyId}  -->
         and f.material_id is not null
         and f.plan_id = #{userId}
         <if test="accountIds != null">
@@ -1220,7 +1209,6 @@
         left join (select material_id,clip_id,shot_id,plan_id,plane_id from ctop_material_ascription group by material_id) f on a.signature = f.material_id
         where stat_datetime &gt;= #{startDate}
         and stat_datetime &lt;= #{endDate}
-        <!-- and a.company_id = #{companyId}  -->
         and f.material_id is not null
         and f.clip_id = #{userId}
         <if test="accountIds != null">
@@ -1268,5 +1256,4 @@
             </foreach>
         )
     </select>
-
 </mapper>

+ 0 - 261
performance-appraisal/src/main/java/cn/com/ctop/huananvideoreport/controller/HuananVideoReportController.java

@@ -1,261 +0,0 @@
-package cn.com.ctop.huananvideoreport.controller;
-
-import cn.com.ctop.common.module.annotation.AutoLog;
-import cn.com.ctop.huananvideoreport.entity.HuananVideoReport;
-import cn.com.ctop.huananvideoreport.service.IHuananVideoReportService;
-import cn.com.ctop.userefficientvideomap.entity.UserDto2;
-import com.alibaba.fastjson.JSON;
-import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
-import com.baomidou.mybatisplus.core.metadata.IPage;
-import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
-import io.swagger.annotations.Api;
-import io.swagger.annotations.ApiOperation;
-import lombok.extern.slf4j.Slf4j;
-import org.jeecg.common.api.vo.Result;
-import org.jeecg.common.system.query.QueryGenerator;
-import org.jeecg.common.util.oConvertUtils;
-import org.jeecgframework.poi.excel.ExcelImportUtil;
-import org.jeecgframework.poi.excel.def.NormalExcelConstants;
-import org.jeecgframework.poi.excel.entity.ExportParams;
-import org.jeecgframework.poi.excel.entity.ImportParams;
-import org.jeecgframework.poi.excel.view.JeecgEntityExcelView;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.web.bind.annotation.*;
-import org.springframework.web.multipart.MultipartFile;
-import org.springframework.web.multipart.MultipartHttpServletRequest;
-import org.springframework.web.servlet.ModelAndView;
-
-import javax.servlet.http.HttpServletRequest;
-import javax.servlet.http.HttpServletResponse;
-import java.io.IOException;
-import java.io.UnsupportedEncodingException;
-import java.net.URLDecoder;
-import java.text.ParseException;
-import java.util.Arrays;
-import java.util.List;
-import java.util.Map;
-
-/**
- * 华南视频报表类
- *
- * @author jeecg-boot
- * @version V1.0
- * @date 2020-04-28
- */
-@Slf4j
-@Api(tags = "华南视频报表类")
-@RestController
-@RequestMapping("/huananvideoreport/huananVideoReport")
-public class HuananVideoReportController {
-    @Autowired
-    private IHuananVideoReportService huananVideoReportService;
-
-    /**
-     * 分页列表查询
-     *
-     * @param huananVideoReport
-     * @param pageNo
-     * @param pageSize
-     * @param req
-     * @return
-     */
-    @AutoLog(value = "华南视频报表类-分页列表查询")
-    @ApiOperation(value = "华南视频报表类-分页列表查询", notes = "华南视频报表类-分页列表查询")
-    @GetMapping(value = "/list")
-    public Result<IPage<HuananVideoReport>> queryPageList(HuananVideoReport huananVideoReport,
-                                                          @RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
-                                                          @RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize,
-                                                          HttpServletRequest req) {
-        Result<IPage<HuananVideoReport>> result = new Result<IPage<HuananVideoReport>>();
-        QueryWrapper<HuananVideoReport> queryWrapper = QueryGenerator.initQueryWrapper(huananVideoReport, req.getParameterMap());
-        Page<HuananVideoReport> page = new Page<HuananVideoReport>(pageNo, pageSize);
-        IPage<HuananVideoReport> pageList = huananVideoReportService.page(page, queryWrapper);
-        result.setSuccess(true);
-        result.setResult(pageList);
-        return result;
-    }
-
-    /**
-     * 添加
-     *
-     * @param huananVideoReport
-     * @return
-     */
-    @AutoLog(value = "华南视频报表类-添加")
-    @ApiOperation(value = "华南视频报表类-添加", notes = "华南视频报表类-添加")
-    @PostMapping(value = "/add")
-    public Result<HuananVideoReport> add(@RequestBody HuananVideoReport huananVideoReport) {
-        Result<HuananVideoReport> result = new Result<HuananVideoReport>();
-        try {
-            huananVideoReportService.save(huananVideoReport);
-            result.success("添加成功!");
-        } catch (Exception e) {
-            log.error(e.getMessage(), e);
-            result.error500("操作失败");
-        }
-        return result;
-    }
-
-    /**
-     * 编辑
-     *
-     * @param huananVideoReport
-     * @return
-     */
-    @AutoLog(value = "华南视频报表类-编辑")
-    @ApiOperation(value = "华南视频报表类-编辑", notes = "华南视频报表类-编辑")
-    @PutMapping(value = "/edit")
-    public Result<HuananVideoReport> edit(@RequestBody HuananVideoReport huananVideoReport) {
-        Result<HuananVideoReport> result = new Result<HuananVideoReport>();
-        HuananVideoReport huananVideoReportEntity = huananVideoReportService.getById(huananVideoReport.getId());
-        if (huananVideoReportEntity == null) {
-            result.error500("未找到对应实体");
-        } else {
-            boolean ok = huananVideoReportService.updateById(huananVideoReport);
-            if (ok) {
-                result.success("修改成功!");
-            }
-        }
-
-        return result;
-    }
-
-    /**
-     * 通过id删除
-     *
-     * @param id
-     * @return
-     */
-    @AutoLog(value = "华南视频报表类-通过id删除")
-    @ApiOperation(value = "华南视频报表类-通过id删除", notes = "华南视频报表类-通过id删除")
-    @DeleteMapping(value = "/delete")
-    public Result<?> delete(@RequestParam(name = "id", required = true) String id) {
-        try {
-            huananVideoReportService.removeById(id);
-        } catch (Exception e) {
-            log.error("删除失败", e.getMessage());
-            return Result.error("删除失败!");
-        }
-        return Result.ok("删除成功!");
-    }
-
-    /**
-     * 批量删除
-     *
-     * @param ids
-     * @return
-     */
-    @AutoLog(value = "华南视频报表类-批量删除")
-    @ApiOperation(value = "华南视频报表类-批量删除", notes = "华南视频报表类-批量删除")
-    @DeleteMapping(value = "/deleteBatch")
-    public Result<HuananVideoReport> deleteBatch(@RequestParam(name = "ids", required = true) String ids) {
-        Result<HuananVideoReport> result = new Result<HuananVideoReport>();
-        if (ids == null || "".equals(ids.trim())) {
-            result.error500("参数不识别!");
-        } else {
-            this.huananVideoReportService.removeByIds(Arrays.asList(ids.split(",")));
-            result.success("删除成功!");
-        }
-        return result;
-    }
-
-    /**
-     * 通过id查询
-     *
-     * @param id
-     * @return
-     */
-    @AutoLog(value = "华南视频报表类-通过id查询")
-    @ApiOperation(value = "华南视频报表类-通过id查询", notes = "华南视频报表类-通过id查询")
-    @GetMapping(value = "/queryById")
-    public Result<HuananVideoReport> queryById(@RequestParam(name = "id", required = true) String id) {
-        Result<HuananVideoReport> result = new Result<HuananVideoReport>();
-        HuananVideoReport huananVideoReport = huananVideoReportService.getById(id);
-        if (huananVideoReport == null) {
-            result.error500("未找到对应实体");
-        } else {
-            result.setResult(huananVideoReport);
-            result.setSuccess(true);
-        }
-        return result;
-    }
-
-    /**
-     * 导出excel
-     *
-     * @param request
-     * @param response
-     */
-    @RequestMapping(value = "/exportXls")
-    public ModelAndView exportXls(HttpServletRequest request, HttpServletResponse response) {
-        // Step.1 组装查询条件
-        QueryWrapper<HuananVideoReport> queryWrapper = null;
-        try {
-            String paramsStr = request.getParameter("paramsStr");
-            if (oConvertUtils.isNotEmpty(paramsStr)) {
-                String deString = URLDecoder.decode(paramsStr, "UTF-8");
-                HuananVideoReport huananVideoReport = JSON.parseObject(deString, HuananVideoReport.class);
-                queryWrapper = QueryGenerator.initQueryWrapper(huananVideoReport, request.getParameterMap());
-            }
-        } catch (UnsupportedEncodingException e) {
-            e.printStackTrace();
-        }
-
-        //Step.2 AutoPoi 导出Excel
-        ModelAndView mv = new ModelAndView(new JeecgEntityExcelView());
-        List<HuananVideoReport> pageList = huananVideoReportService.list(queryWrapper);
-        //导出文件名称
-        mv.addObject(NormalExcelConstants.FILE_NAME, "华南视频报表类列表");
-        mv.addObject(NormalExcelConstants.CLASS, HuananVideoReport.class);
-        mv.addObject(NormalExcelConstants.PARAMS, new ExportParams("华南视频报表类列表数据", "导出人:Jeecg", "导出信息"));
-        mv.addObject(NormalExcelConstants.DATA_LIST, pageList);
-        return mv;
-    }
-
-    /**
-     * 通过excel导入数据
-     *
-     * @param request
-     * @param response
-     * @return
-     */
-    @RequestMapping(value = "/importExcel", method = RequestMethod.POST)
-    public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
-        MultipartHttpServletRequest multipartRequest = (MultipartHttpServletRequest) request;
-        Map<String, MultipartFile> fileMap = multipartRequest.getFileMap();
-        for (Map.Entry<String, MultipartFile> entity : fileMap.entrySet()) {
-            MultipartFile file = entity.getValue();
-            ImportParams params = new ImportParams();
-            params.setTitleRows(2);
-            params.setHeadRows(1);
-            params.setNeedSave(true);
-            try {
-                List<HuananVideoReport> listHuananVideoReports = ExcelImportUtil.importExcel(file.getInputStream(), HuananVideoReport.class, params);
-                huananVideoReportService.saveBatch(listHuananVideoReports);
-                return Result.ok("文件导入成功!数据行数:" + listHuananVideoReports.size());
-            } catch (Exception e) {
-                log.error(e.getMessage(), e);
-                return Result.error("文件导入失败:" + e.getMessage());
-            } finally {
-                try {
-                    file.getInputStream().close();
-                } catch (IOException e) {
-                    e.printStackTrace();
-                }
-            }
-        }
-        return Result.ok("文件导入失败!");
-    }
-
-
-    @AutoLog(value = "头条优化季度绩效报表")
-    @ApiOperation(value = "头条优化季度绩效报表", notes = "头条优化季度绩效报表")
-    @PostMapping(value = "/getHuananMaterialInfo")
-    public Result getHuananMaterialInfo(HttpServletRequest req) throws ParseException {
-        Result<List<UserDto2>> result = new Result<List<UserDto2>>();
-        huananVideoReportService.getHuananMaterialInfo("2020-05-01", "2020-05-07");
-        result.setSuccess(true);
-        return result;
-    }
-
-}

+ 0 - 17
performance-appraisal/src/main/java/cn/com/ctop/huananvideoreport/dto/HuananVideoReportDTO.java

@@ -1,17 +0,0 @@
-package cn.com.ctop.huananvideoreport.dto;
-
-import lombok.Data;
-
-/**
- * 华南视频报表类
- *
- * @author jeecg-boot
- * @version V1.0
- * @date 2020-04-28
- */
-@Data
-public class HuananVideoReportDTO {
-
-    private String accountId;
-    private String authName;
-}

+ 0 - 121
performance-appraisal/src/main/java/cn/com/ctop/huananvideoreport/entity/HuananVideoReport.java

@@ -1,121 +0,0 @@
-package cn.com.ctop.huananvideoreport.entity;
-
-import com.baomidou.mybatisplus.annotation.IdType;
-import com.baomidou.mybatisplus.annotation.TableId;
-import com.baomidou.mybatisplus.annotation.TableName;
-import io.swagger.annotations.ApiModel;
-import io.swagger.annotations.ApiModelProperty;
-import lombok.Data;
-import lombok.EqualsAndHashCode;
-import lombok.experimental.Accessors;
-import org.jeecgframework.poi.excel.annotation.Excel;
-
-import java.util.Date;
-
-/**
- * 华南视频报表类
- *
- * @author jeecg-boot
- * @version V1.0
- * @date 2020-04-28
- */
-@Data
-@TableName("bytedance_huanan_video_report")
-@EqualsAndHashCode(callSuper = false)
-@Accessors(chain = true)
-@ApiModel(value = "bytedance_huanan_video_report对象", description = "华南视频报表类")
-public class HuananVideoReport {
-
-    /**
-     * id
-     */
-    @TableId(type = IdType.AUTO)
-    @ApiModelProperty(value = "id")
-    private Integer id;
-    /**
-     * accountId
-     */
-    @Excel(name = "accountId", width = 15)
-    @ApiModelProperty(value = "accountId")
-    private String accountId;
-    /**
-     * authName
-     */
-    @Excel(name = "authName", width = 15)
-    @ApiModelProperty(value = "authName")
-    private String authName;
-    /**
-     * projectId
-     */
-    @Excel(name = "projectId", width = 15)
-    @ApiModelProperty(value = "projectId")
-    private Integer projectId;
-    /**
-     * projectName
-     */
-    @Excel(name = "projectName", width = 15)
-    @ApiModelProperty(value = "projectName")
-    private String projectName;
-    /**
-     * advertiserId
-     */
-    @Excel(name = "advertiserId", width = 15)
-    @ApiModelProperty(value = "advertiserId")
-    private String advertiserId;
-    /**
-     * advertiserName
-     */
-    @Excel(name = "advertiserName", width = 15)
-    @ApiModelProperty(value = "advertiserName")
-    private String advertiserName;
-    /**
-     * cost
-     */
-    @Excel(name = "cost", width = 15)
-    @ApiModelProperty(value = "cost")
-    private java.math.BigDecimal cost;
-    /**
-     * signature
-     */
-    @Excel(name = "signature", width = 15)
-    @ApiModelProperty(value = "signature")
-    private String signature;
-    /**
-     * videoUrl
-     */
-    @Excel(name = "videoUrl", width = 15)
-    @ApiModelProperty(value = "videoUrl")
-    private String videoUrl;
-    /**
-     * 环比
-     */
-    @Excel(name = "环比", width = 15)
-    @ApiModelProperty(value = "环比")
-    private java.math.BigDecimal huanbi;
-    /**
-     * 素材名称
-     */
-    @Excel(name = "素材名称", width = 15)
-    @ApiModelProperty(value = "素材名称")
-    private String materialName;
-    /**
-     * 1头条2快手
-     */
-    @Excel(name = "1头条2快手", width = 15)
-    @ApiModelProperty(value = "1头条2快手")
-    private Integer appType;
-    /**
-     * createTime
-     */
-    @ApiModelProperty(value = "createTime")
-    private Date createTime;
-    /**
-     * updateTime
-     */
-    @ApiModelProperty(value = "updateTime")
-    private Date updateTime;
-
-    private Long materialId;
-
-    private String statDatetime;
-}

+ 0 - 24
performance-appraisal/src/main/java/cn/com/ctop/huananvideoreport/mapper/HuananVideoReportMapper.java

@@ -1,24 +0,0 @@
-package cn.com.ctop.huananvideoreport.mapper;
-
-import java.util.List;
-
-import cn.com.ctop.huananvideoreport.dto.HuananVideoReportDTO;
-import org.apache.ibatis.annotations.Param;
-import cn.com.ctop.huananvideoreport.entity.HuananVideoReport;
-import com.baomidou.mybatisplus.core.mapper.BaseMapper;
-
-/**
- * 华南视频报表类
- *
- * @author: jeecg-boot
- * @date: 2020-04-28
- * @cersion: V1.0
- */
-public interface HuananVideoReportMapper extends BaseMapper<HuananVideoReport> {
-
-    List<HuananVideoReport> getHuananMaterialInfo(@Param("startDate") String startDate, @Param("endDate") String endDate);
-
-    HuananVideoReport selectByDateAndId(@Param("materialId") Long materialId, @Param("statDate") String statDate);
-
-    HuananVideoReportDTO getAccountConcatInfo(@Param("materialId") Long materialId);
-}

+ 0 - 294
performance-appraisal/src/main/java/cn/com/ctop/huananvideoreport/mapper/xml/HuananVideoReportMapper.xml

@@ -1,294 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
-<mapper namespace="cn.com.ctop.huananvideoreport.mapper.HuananVideoReportMapper">
-
-
-    <select id="getHuananMaterialInfo" resultType="cn.com.ctop.huananvideoreport.entity.HuananVideoReport">
-        select
-        a.material_id as materialId,
-        b.project_id as projectId,
-        b.project_name as projectName,
-        b.advertiser_id as advertiserId,
-        b.advertiser_name as advertiserName,
-        a.stat_datetime as statDatetime,
-        sum(a.cost) as cost,
-        d.signature as signature,
-        d.video_url as video_url,
-        e.url as url,
-        e.material_name as materialName,
-        1 as appType
-        from ctop_bytedance_report_material_daily a
-        left join ctop_user_allocation b on a.account_id = b.account_id
-        left join user_company c on b.user_id = c.user_id
-        left join ctop_bytedance_video_info d on a.material_id = d.material_id
-        left join (select code,url,material_name from ctop_material_info group by code) e on d.signature = e.code
-        where c.company_id = '6608ed13c0dd42de93c790dbdf124234'
-        and a.image_mode in ('CREATIVE_IMAGE_MODE_VIDEO',
-        'CREATIVE_IMAGE_MODE_VIDEO_VERTICAL')
-        and date_format(stat_datetime,'%Y-%m-%d') &gt;= #{startDate}
-        and date_format(stat_datetime,'%Y-%m-%d') &lt;= #{endDate}
-        group by `statDatetime`,`materialId`
-        order by `statDatetime`,`projectId`,`materialId`
-    </select>
-
-    <select id="selectByDateAndId" resultType="cn.com.ctop.huananvideoreport.entity.HuananVideoReport">
-        select
-        *
-        from
-        bytedance_huanan_video_report
-        where material_id = #{materialId}
-        and stat_datetime = #{statDate}
-
-    </select>
-
-    <select id="getAccountConcatInfo" resultType="cn.com.ctop.huananvideoreport.dto.HuananVideoReportDTO">
-        select
-        group_concat(distinct(b.account_id)) as accountId,
-        group_concat(distinct(b.auth_name)) as authName
-        from
-        ctop_bytedance_report_material_daily a
-        left join ctop_user_allocation b on a.account_id = b.account_id
-        where a.material_id = #{materialId}
-    </select>
-
-    <select id="getHuananVideoInfo" resultType="cn.com.ctop.huananvideoreport.entity.HuananVideoReport">
-        select
-        a.material_id as materialId,
-        b.project_id as projectId,
-        b.project_name as projectName,
-        b.advertiser_id as advertiserId,
-        b.advertiser_name as advertiserName,
-        a.stat_datetime as statDatetime,
-        sum(a.cost) as cost,
-        d.signature as signature,
-        d.video_url as video_url,
-        e.url as url,
-        e.material_name as materialName,
-        1 as appType
-        from ctop_bytedance_report_material_daily a
-        left join ctop_user_allocation b on a.account_id = b.account_id
-        left join user_company c on b.user_id = c.user_id
-        left join ctop_bytedance_video_info d on a.material_id = d.material_id
-        left join (select code,url,material_name from ctop_material_info group by code) e on d.signature = e.code
-        where c.company_id = '6608ed13c0dd42de93c790dbdf124234'
-        and a.image_mode in ('CREATIVE_IMAGE_MODE_VIDEO',
-        'CREATIVE_IMAGE_MODE_VIDEO_VERTICAL')
-        and date_format(stat_datetime,'%Y-%m-%d') &gt;= #{startDate}
-        and date_format(stat_datetime,'%Y-%m-%d') &lt;= #{endDate}
-        group by `statDatetime`,`signature`
-        order by `statDatetime`,`projectId`,`materialId`
-    </select>
-
-    <select id="videoInfoList" resultType="cn.com.ctop.huananvideoreport.entity.HuananVideoReport">
-        select
-        a.material_id as materialId,
-        b.project_id as projectId,
-        b.project_name as projectName,
-        b.advertiser_id as advertiserId,
-        b.advertiser_name as advertiserName,
-        a.stat_datetime as statDatetime,
-        sum(a.cost) as cost,
-        d.signature as signature,
-        d.video_url as videoUrl,
-        e.url as url,
-        e.material_name as materialName,
-        1 as appType,
-        sum(a.click) as click,
-
-        case
-        when sum(a.total_play) != 0
-        then sum(a.play25_feed_break)/sum(a.total_play)
-        else 0 end as play25FeedBreakRate,
-
-        case
-        when sum(a.total_play) != 0
-        then sum(a.play_over)/sum(a.total_play)
-        else 0 end as playOverRate,
-
-        case
-        when sum(a.click) != 0
-        then sum(a.convert_material)/sum(a.click)
-        else 0 end as convertRate,
-        sum(a.active) as active,
-        sum(a.download_finish) as downloadFinish,
-        sum(a.download_start) as downloadStart,
-        sum(a.install_finish) as installFinish,
-        sum(a.register) as register,
-        sum(a.pay_count) as payCount,
-        sum(a.in_app_uv) as inAppUv,
-        sum(a.in_app_detail_uv) as inAppDetailUv,
-        sum(a.in_app_cart) as inAppCart,
-        sum(a.in_app_order) as inAppOrder,
-        sum(a.in_app_pay) as inAppPay,
-        sum(a.phone) as phone,
-        sum(a.form) as form,
-        sum(a.map_search) as mapSearch,
-        sum(a.button) as button,
-        sum(a.view_material) as viewMaterial,
-        sum(a.qq) as qq,
-        sum(a.lottery) as lottery,
-        sum(a.vote) as vote,
-        sum(a.redirect) as redirect,
-        sum(a.shopping) as shopping,
-        sum(a.consult) as consult,
-        sum(a.wechat) as wechat,
-        sum(a.phone_confirm) as phoneConfirm,
-        sum(a.phone_connect) as phoneConnect,
-        sum(a.consult_effective) as consultEffective,
-        sum(a.total_play) as totalPlay,
-        sum(a.valid_play) as validPlay,
-        sum(a.wifi_play) as wifiPlay,
-        sum(a.play25_feed_break) as play25FeedBreak,
-        sum(a.play50_feed_break) as play50FeedBreak,
-        sum(a.play75_feed_break) as play75FeedBreak,
-        sum(a.play100_feed_break) as play100FeedBreak,
-        sum(a.advanced_creative_phone_click) as advancedCreativePhoneClick,
-        sum(a.vanced_creative_counsel_click) as vancedCreativeCounselClick,
-        sum(a.advanced_creative_form_click) as advancedCreativeFormClick,
-        sum(a.share_material) as shareMaterial,
-        sum(a.comment_material) as commentMaterial,
-        sum(a.follow) as follow,
-        sum(a.home_visited) as homeVisited,
-        sum(a.ies_challenge_click) as iesChallengeClick,
-        sum(a.ies_music_click) as iesMusicClick,
-        sum(a.next_day_open) as nextDayOpen,
-        case
-        when sum(a.active) != 0
-        then sum(a.next_day_open)/sum(a.active)
-        else 0 end as nextDayOpenRate,
-
-        case
-        when sum(a.next_day_open) != 0
-        then sum(a.cost)/sum(a.next_day_open)
-        else 0 end as nextDayOpenCost,
-
-        sum(a.active_pay_amount) as activePayAmount,
-
-        case
-        when sum(a.cost) != 0
-        then sum(a.cost)/sum(a.valid_play)
-        else 0 end validPlayCost,
-        sum(a.advanced_creative_coupon_addition) as advancedCreativeCouponAddition,
-        sum(a.convert_material) as convertMaterial,
-
-        case
-        when sum(a.cost) != 0
-        then sum(a.cost)/sum(a.active_pay_amount)
-        else 0 end as activePayCost,
-        sum(a.download) as download,
-        sum(a.cpc) as cpc,
-        sum(a.location_click) as locationClick,
-        sum(a.play_over_rate) as playOverRate,
-
-        case
-        when sum(a.show_material) != 0
-        then sum(a.click)/sum(a.show_material)
-        else 0 end as ctr,
-
-        case
-        when sum(a.cost) != 0
-        then sum(a.cost)/sum(a.show_material)*1000
-        else 0 end cpm,
-        sum(a.wifi_play_rate) as wifiPlayRate,
-        sum(a.like_material) as likeMaterial,
-
-        case
-        when sum(a.cost) != 0
-        then sum(a.cost)/sum(a.active)
-        else 0 end activeCost,
-
-        case
-        when sum(a.cost) != 0
-        then sum(a.cost)/sum(a.game_addiction)
-        else 0 end as gameAddictionCost,
-        sum(a.game_addiction) as gameAddiction,
-
-        case
-        when sum(a.active) != 0
-        then sum(a.active)/sum(a.click)
-        else 0 end as activeRate,
-
-        case
-        when sum(a.active) != 0
-        then sum(a.game_addiction)/sum(a.active)
-        else 0 end gameAddictionRate,
-
-        case
-        when sum(a.active) != 0
-        then sum(a.register)/sum(a.active)
-        else 0 end as activeRegisterRate,
-
-
-        case
-        when sum(a.download_finish) != 0
-        then sum(a.cost)/sum(a.download_finish)
-        else 0 end as downloadFinishCost,
-
-
-        case
-        when sum(a.register) != 0
-        then sum(a.cost)/sum(a.register)
-        else 0 end as activeRegisterCost,
-        sum(a.show_material) as showMaterial,
-
-        case
-        when sum(a.click) != 0
-        then sum(a.convert_material)/sum(a.click)
-        else 0 end as convertRate,
-
-        case
-        when sum(a.download_start) != 0
-        then sum(a.download_finish)/sum(a.download_start)
-        else 0 end as downloadFinishRate,
-
-        case
-        when sum(a.download_finish) != 0
-        then sum(a.install_finish)/sum(a.download_finish)
-        else 0 end as installFinishRate,
-        sum(a.coupon) as coupon,
-        sum(a.coupon_single_page) as couponSinglePage,
-        sum(a.play_over) as playOver,
-
-        case
-        when sum(a.download_start) != 0
-        then sum(a.cost)/sum(a.download_start)
-        else 0 end as downloadStartCost,
-        sum(a.message) as message,
-
-
-        case
-        when sum(a.valid_play) != 0
-        then sum(a.valid_play)/sum(a.show_material)
-        else 0 end as validPlayRate,
-        sum(a.average_play_time_per_play) as averagePlayTimePerPlay,
-
-        case
-        when sum(a.convert_material) != 0
-        then sum(a.cost)/sum(a.convert_material)
-        else 0 end as convertCost,
-
-
-        case
-        when sum(a.install_finish) != 0
-        then sum(a.cost)/sum(a.install_finish)
-        else 0 end as installFinishCost,
-
-        case
-        when sum(a.click) != 0
-        then sum(a.download_start)/sum(a.click)
-        else 0 end as downloadStartRate,
-        from ctop_bytedance_report_material_daily a
-        left join ctop_user_allocation b on a.account_id = b.account_id
-        left join user_company c on b.user_id = c.user_id
-        left join ctop_bytedance_video_info d on a.material_id = d.material_id
-        left join (select code,url,material_name from ctop_material_info group by code) e on d.signature = e.code
-        where c.company_id = '6608ed13c0dd42de93c790dbdf124234'
-        and a.image_mode in ('CREATIVE_IMAGE_MODE_VIDEO',
-        'CREATIVE_IMAGE_MODE_VIDEO_VERTICAL')
-        and date_format(stat_datetime,'%Y-%m-%d') &gt;= #{startDate}
-        and date_format(stat_datetime,'%Y-%m-%d') &lt;= #{endDate}
-        group by `statDatetime`,`signature`
-        order by `statDatetime`,`projectId`,`signature`
-    </select>
-
-</mapper>

+ 0 - 17
performance-appraisal/src/main/java/cn/com/ctop/huananvideoreport/service/IHuananVideoReportService.java

@@ -1,17 +0,0 @@
-package cn.com.ctop.huananvideoreport.service;
-
-import cn.com.ctop.huananvideoreport.entity.HuananVideoReport;
-import com.baomidou.mybatisplus.extension.service.IService;
-
-import java.text.ParseException;
-
-/**
- * 华南视频报表类
- *
- * @author jeecg-boot
- * @version V1.0
- * @date 2020-04-28
- */
-public interface IHuananVideoReportService extends IService<HuananVideoReport> {
-    void getHuananMaterialInfo(String startDate, String endDate) throws ParseException;
-}

+ 0 - 65
performance-appraisal/src/main/java/cn/com/ctop/huananvideoreport/service/impl/HuananVideoReportServiceImpl.java

@@ -1,65 +0,0 @@
-package cn.com.ctop.huananvideoreport.service.impl;
-
-import cn.com.ctop.common.module.entity.MaterialInfo;
-import cn.com.ctop.huananvideoreport.dto.HuananVideoReportDTO;
-import cn.com.ctop.huananvideoreport.entity.HuananVideoReport;
-import cn.com.ctop.huananvideoreport.mapper.HuananVideoReportMapper;
-import cn.com.ctop.huananvideoreport.service.IHuananVideoReportService;
-import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
-import org.assertj.core.util.DateUtil;
-import org.jeecg.common.util.DateUtils;
-import org.springframework.beans.factory.annotation.Autowired;
-import org.springframework.stereotype.Service;
-
-import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
-
-import java.math.BigDecimal;
-import java.text.ParseException;
-import java.util.List;
-
-/**
- * 华南视频报表类
- *
- * @author jeecg-boot
- * @version V1.0
- * @date 2020-04-28
- */
-@Service
-public class HuananVideoReportServiceImpl extends ServiceImpl<HuananVideoReportMapper, HuananVideoReport> implements IHuananVideoReportService {
-
-    @Autowired
-    private HuananVideoReportMapper huananVideoReportMapper;
-
-    public void getHuananMaterialInfo(String startDate, String endDate) throws ParseException {
-
-        List<HuananVideoReport> mList = huananVideoReportMapper.getHuananMaterialInfo(startDate, endDate);
-
-        for (HuananVideoReport m : mList) {
-            huananVideoReportMapper.insert(m);
-        }
-
-
-        QueryWrapper<HuananVideoReport> queryWrapper = new QueryWrapper<>();
-        List<HuananVideoReport> mList2 = huananVideoReportMapper.selectList(queryWrapper);
-
-        for (HuananVideoReport m : mList2) {
-            String statDate = DateUtils.addDay(m.getStatDatetime(), -1);
-            HuananVideoReport mb = huananVideoReportMapper.selectByDateAndId(m.getMaterialId(), statDate);
-
-            BigDecimal huanbi = BigDecimal.ZERO;
-            if (mb != null && mb.getCost().compareTo(BigDecimal.ZERO) > 0) {
-                huanbi = m.getCost().subtract(mb.getCost()).divide(mb.getCost(), 7, BigDecimal.ROUND_HALF_UP);
-            }
-            HuananVideoReportDTO accountConcatInfo = huananVideoReportMapper.getAccountConcatInfo(m.getMaterialId());
-
-            m.setAccountId(accountConcatInfo.getAccountId());
-            m.setAuthName(accountConcatInfo.getAuthName());
-            m.setHuanbi(huanbi);
-            huananVideoReportMapper.updateById(m);
-        }
-
-
-    }
-
-
-}

+ 61 - 91
performance-appraisal/src/main/java/cn/com/ctop/userefficientvideomap/mapper/xml/UserEfficientVideoMapMapper.xml

@@ -339,12 +339,12 @@
             resultType="cn.com.ctop.userefficientvideomap.entity.DesignMaterialInfo">    <!-- 素材、素材跑量、封面点击数、封面曝光数、行为数 -->
         select
         b.id as id,
-        b.url as videoUrl, <!-- 素材url -->
-        sum(a.photo_show) as pageExposureCount, <!-- 封面曝光数 -->
-        sum(a.photo_click) as pageClickCount, <!-- 封面点击数 -->
-        sum(a.aclick) as materialExposureCount, <!-- 素材曝光数 -->
-        sum(a.bclick) as behaviorCount,<!-- 行为数 -->
-        sum(a.charge) as totalCost <!-- 素材跑量 -->
+        b.url as videoUrl,
+        sum(a.photo_show) as pageExposureCount,
+        sum(a.photo_click) as pageClickCount,
+        sum(a.aclick) as materialExposureCount,
+        sum(a.bclick) as behaviorCount,
+        sum(a.charge) as totalCost
         from
         ctop_material_info b
         left join ctop_material_ascription c on b.id = c.material_id
@@ -371,7 +371,6 @@
             resultType="cn.com.ctop.userefficientvideomap.entity.DesignMaterialInfo">
         select
         a.account_id as accountId,
-        <!-- a.account_name as accountName, -->
         '快手' as platform,
         sum(charge) as totalCost
         from
@@ -456,9 +455,9 @@
         select
         user_id
         from sys_user_role
-        WHERE role_id = '8d3e2ed58bdedf17716f698ea674da27'   <!-- 设计师 -->
+        WHERE role_id = '8d3e2ed58bdedf17716f698ea674da27'
         )
-        and b.parent_id = '4e939124a5f541c88838e49d2a3ea72b'  <!-- 快手设计部 -->
+        and b.parent_id = '4e939124a5f541c88838e49d2a3ea72b'
     </select>
 
     <!-- 获取快手编导列表 -->
@@ -476,9 +475,9 @@
         select
         user_id
         from sys_user_role
-        WHERE role_id = '0214283aa16f943efbb149ea4bb18f18'    <!-- 编导 -->
+        WHERE role_id = '0214283aa16f943efbb149ea4bb18f18'
         )
-        and b.parent_id = '4e939124a5f541c88838e49d2a3ea72b'  <!-- 快手设计部 -->
+        and b.parent_id = '4e939124a5f541c88838e49d2a3ea72b'
     </select>
 
     <!-- 获取快手拍摄列表 -->
@@ -496,9 +495,9 @@
         select
         user_id
         from sys_user_role
-        WHERE role_id = '7bff9afed625aeeabca6bffe3c189183'   <!-- 拍摄 -->
+        WHERE role_id = '7bff9afed625aeeabca6bffe3c189183'
         )
-        and b.parent_id = '4e939124a5f541c88838e49d2a3ea72b'   <!-- 快手设计部 -->
+        and b.parent_id = '4e939124a5f541c88838e49d2a3ea72b'
     </select>
 
     <!-- 获取快手剪辑列表 -->
@@ -516,9 +515,9 @@
         select
         user_id
         from sys_user_role
-        WHERE role_id = 'f38d8d70cf7ec50d5357a749e4dbf8ee'   <!-- 拍摄 -->
+        WHERE role_id = 'f38d8d70cf7ec50d5357a749e4dbf8ee'
         )
-        and b.parent_id = '4e939124a5f541c88838e49d2a3ea72b'   <!-- 快手设计部 -->
+        and b.parent_id = '4e939124a5f541c88838e49d2a3ea72b'
     </select>
 
     <!-- 根据部门id -->
@@ -561,9 +560,9 @@
         select
         user_id
         from sys_user_role
-        WHERE role_id = '8d3e2ed58bdedf17716f698ea674da27'   <!-- 设计师 -->
+        WHERE role_id = '8d3e2ed58bdedf17716f698ea674da27'
         )
-        and b.parent_id = '26c10ecb5e0d416bb01f8ff983f4588c'  <!-- 头条设计部 -->
+        and b.parent_id = '26c10ecb5e0d416bb01f8ff983f4588c'
     </select>
 
     <!-- 获取toutiao编导列表 -->
@@ -581,9 +580,9 @@
         select
         user_id
         from sys_user_role
-        WHERE role_id = '0214283aa16f943efbb149ea4bb18f18'    <!-- 编导 -->
+        WHERE role_id = '0214283aa16f943efbb149ea4bb18f18'
         )
-        and b.parent_id = '26c10ecb5e0d416bb01f8ff983f4588c'  <!-- 头条设计部 -->
+        and b.parent_id = '26c10ecb5e0d416bb01f8ff983f4588c'
     </select>
 
     <!-- 获取toutiao拍摄列表 -->
@@ -601,9 +600,9 @@
         select
         user_id
         from sys_user_role
-        WHERE role_id = '7bff9afed625aeeabca6bffe3c189183'   <!-- 拍摄 -->
+        WHERE role_id = '7bff9afed625aeeabca6bffe3c189183'
         )
-        and b.parent_id = '26c10ecb5e0d416bb01f8ff983f4588c'   <!-- 头条设计部 -->
+        and b.parent_id = '26c10ecb5e0d416bb01f8ff983f4588c'
     </select>
 
     <!-- 获取toutiao剪辑列表 -->
@@ -621,16 +620,16 @@
         select
         user_id
         from sys_user_role
-        WHERE role_id = 'f38d8d70cf7ec50d5357a749e4dbf8ee'   <!-- 拍摄 -->
+        WHERE role_id = 'f38d8d70cf7ec50d5357a749e4dbf8ee'
         )
-        and b.parent_id = '26c10ecb5e0d416bb01f8ff983f4588c'   <!-- 头条设计部 -->
+        and b.parent_id = '26c10ecb5e0d416bb01f8ff983f4588c'
     </select>
 
     <!-- 头条有效视频用户关系绑定 -->
     <select id="getToutiaoUserVideoMap" resultType="cn.com.ctop.userefficientvideomap.entity.EffiVideoDTO">
         select
         c.signature as signature,
-        sum(a.cost) as charge, <!-- 总花费 -->
+        sum(a.cost) as charge,
         f1.id as clipId,
         f1.realname as clipName,
         f2.id as shotId,
@@ -914,7 +913,7 @@
         left join sys_user u on ud.user_id = u.id
         left join sys_user_role ur on u.id = ur.user_id
         left join sys_role r on ur.role_id = r.id
-        WHERE b.parent_id = '4e939124a5f541c88838e49d2a3ea72b'  <!-- 快手设计部 -->
+        WHERE b.parent_id = '4e939124a5f541c88838e49d2a3ea72b'
         and r.role_code in ('plan','clip','shot')
     </select>
 
@@ -931,7 +930,7 @@
         left join sys_user u on ud.user_id = u.id
         left join sys_user_role ur on u.id = ur.user_id
         left join sys_role r on ur.role_id = r.id
-        WHERE b.parent_id = '4e939124a5f541c88838e49d2a3ea72b'  <!-- 快手设计部 -->
+        WHERE b.parent_id = '4e939124a5f541c88838e49d2a3ea72b'
     </select>
 
     <!-- 获取北京头条设计部所有编导、剪辑、拍摄的信息 -->
@@ -946,7 +945,7 @@
         left join sys_user u on ud.user_id = u.id
         left join sys_user_role ur on u.id = ur.user_id
         left join sys_role r on ur.role_id = r.id
-        WHERE b.parent_id = '26c10ecb5e0d416bb01f8ff983f4588c'  <!-- 头条设计部 -->
+        WHERE b.parent_id = '26c10ecb5e0d416bb01f8ff983f4588c'
         and r.role_code in ('plan','clip','shot')
     </select>
 
@@ -962,7 +961,7 @@
         left join sys_user u on ud.user_id = u.id
         left join sys_user_role ur on u.id = ur.user_id
         left join sys_role r on ur.role_id = r.id
-        WHERE b.parent_id = '26c10ecb5e0d416bb01f8ff983f4588c'  <!-- 头条设计部 -->
+        WHERE b.parent_id = '26c10ecb5e0d416bb01f8ff983f4588c'
     </select>
 
     <!-- 获取北京快手运营部所有优化师得信息 -->
@@ -977,7 +976,7 @@
         left join sys_user u on ud.user_id = u.id
         left join sys_user_role ur on u.id = ur.user_id
         left join sys_role r on ur.role_id = r.id
-        WHERE b.parent_id = '024b0dc0840045afb048022a8c61253f'  <!-- 快手运营部 -->
+        WHERE b.parent_id = '024b0dc0840045afb048022a8c61253f'
         and (r.role_code in ('operator','kuaishouOperationManager','operationAssistant')
         or realname = '郭浩')
     </select>
@@ -994,24 +993,11 @@
         left join sys_user u on ud.user_id = u.id
         left join sys_user_role ur on u.id = ur.user_id
         left join sys_role r on ur.role_id = r.id
-        WHERE b.parent_id = '024b0dc0840045afb048022a8c61253f'  <!-- 快手运营部 -->
+        WHERE b.parent_id = '024b0dc0840045afb048022a8c61253f'
     </select>
 
     <!-- 获取北京头条运营部所有优化师得信息 -->
     <select id="getToutiaoYunyingDepartUserInfo" resultType="cn.com.ctop.userefficientvideomap.entity.UserDto2">
-        <!-- select u.id as userId,
-         u.realname as realname,
-         r.role_name as roleName,
-         r.role_code as roleCode,
-         r.id as roleId
-         FROM sys_user_depart ud
-         left join sys_depart b on ud.dep_id = b.id
-         left join sys_user u on ud.user_id = u.id
-         left join sys_user_role ur on u.id = ur.user_id
-         left join sys_role r on ur.role_id = r.id
-         WHERE b.parent_id = 'c869de6bedc44a50803e45a4611df05e'
-         and r.role_code = 'operator' -->
-
         select u.id as userId,
         u.realname as realname,
         r.role_name as roleName,
@@ -1022,7 +1008,7 @@
         left join sys_user u on ud.user_id = u.id
         left join sys_user_role ur on u.id = ur.user_id
         left join sys_role r on ur.role_id = r.id
-        WHERE b.parent_id = 'c869de6bedc44a50803e45a4611df05e'  <!-- 头条运营部 -->
+        WHERE b.parent_id = 'c869de6bedc44a50803e45a4611df05e'
         and r.role_code in ('operator','kuaishouOperationManager','operationAssistant')
     </select>
 
@@ -1038,7 +1024,7 @@
         left join sys_user u on ud.user_id = u.id
         left join sys_user_role ur on u.id = ur.user_id
         left join sys_role r on ur.role_id = r.id
-        WHERE b.parent_id = 'c869de6bedc44a50803e45a4611df05e'  <!-- 头条运营部 -->
+        WHERE b.parent_id = 'c869de6bedc44a50803e45a4611df05e'
     </select>
 
     <!-- 获取快手单个优化师当前账户下的总消耗 -->
@@ -1080,12 +1066,12 @@
     <!-- 获取头条单个优化师其下所有的账户下当前的消耗 -->
     <select id="getToutiaoAccountTotalCost" resultType="cn.com.ctop.userefficientvideomap.entity.AccountDTO">
         select
-        SUM(dailiAccount.cost) as totalCost,  <!-- 账户当前消耗 -->
-        allocation.account_id as accountId,  <!-- 账户id -->
-        allocation.user_name as userName,  <!-- 优化师 -->
-        allocation.advertiser_name as advertiserName,  <!-- 广告主名称 -->
-        allocation.project_name as projectName,  <!-- 项目名称 -->
-        allocation.auth_name as authName <!-- 授权名称 -->
+        SUM(dailiAccount.cost) as totalCost,
+        allocation.account_id as accountId,
+        allocation.user_name as userName,
+        allocation.advertiser_name as advertiserName,
+        allocation.project_name as projectName,
+        allocation.auth_name as authName
         from
         ctop_bytedance_report_advertiser_daily dailiAccount
         LEFT JOIN
@@ -1104,12 +1090,12 @@
     <!-- 获取快手单个优化师其下所有账户下当前的消耗 -->
     <select id="getKuaishouAccountTotalCost" resultType="cn.com.ctop.userefficientvideomap.entity.AccountDTO">
         SELECT
-        SUM(dailiAccount.charge) as totalCost,  <!-- 账户当前消耗 -->
-        allocation.account_id as accountId,  <!-- 账户id -->
-        allocation.user_name as userName,  <!-- 优化师 -->
-        allocation.advertiser_name as advertiserName,  <!-- 广告主名称 -->
-        allocation.project_name as projectName,  <!-- 项目名称 -->
-        allocation.auth_name as authName <!-- 授权名称 -->
+        SUM(dailiAccount.charge) as totalCost,
+        allocation.account_id as accountId,
+        allocation.user_name as userName,
+        allocation.advertiser_name as advertiserName,
+        allocation.project_name as projectName,
+        allocation.auth_name as authName
         FROM
         ctop_kuaishou_report_daily_account dailiAccount
         LEFT JOIN
@@ -1132,7 +1118,6 @@
         from
         ctop_user_efficient_video_map
         where user_id = #{userId}
-        <!-- and role_id = #{roleId}  -->
         and app_type = #{appType}
         and calc_date &lt;= #{endDate}
         and calc_date &gt;= #{startDate}
@@ -1146,8 +1131,8 @@
         i.url as url,
         i.material_name as materialName,
         i.watermark_material_name as watermarkMaterialName,
-        m.role_id as videoRoleCode,  <!-- 拍摄时候担任的角色 -->
-        r.role_name as originRoleName  <!-- 原本的角色 -->
+        m.role_id as videoRoleCode,
+        r.role_name as originRoleName
         from
         ctop_user_efficient_video_map m
         left join (select id,code,url,material_name,watermark_material_name from ctop_material_info group by code) i on
@@ -1169,8 +1154,8 @@
         i.url as url,
         i.material_name as materialName,
         i.watermark_material_name as watermarkMaterialName,
-        m.role_id as videoRoleCode,  <!-- 拍摄时候担任的角色 -->
-        r.role_name as originRoleName,  <!-- 原本的角色 -->
+        m.role_id as videoRoleCode,
+        r.role_name as originRoleName,
         su.realname as realname
         from
         ctop_user_efficient_video_map m
@@ -1305,20 +1290,6 @@
 
     <!-- 按时间段获取视频总量 -->
     <select id="getVideoByDates" resultType="string">
-        <!-- select
-         code
-         from (
-             select
-             code,
-             create_time
-             from
-             ctop_material_info
-             where
-             date_format(create_time, '%Y-%m-%d') &gt;= #{startDate} and
-             date_format(create_time, '%Y-%m-%d') &lt;= #{endDate}
-             order by create_time
-             ) a
-         group by code -->
         select
         b.signature
         from ctop_kuaishou_creative a
@@ -1405,8 +1376,8 @@
         i.url as url,
         i.material_name as materialName,
         i.watermark_material_name as watermarkMaterialName,
-        m.role_id as videoRoleCode,  <!-- 拍摄时候担任的角色 -->
-        r.role_name as originRoleName  <!-- 原本的角色 -->
+        m.role_id as videoRoleCode,
+        r.role_name as originRoleName
         from
         ctop_user_video_map m
         left join (
@@ -1490,7 +1461,7 @@
         left join sys_user u on ud.user_id = u.id
         left join sys_user_role ur on u.id = ur.user_id
         left join sys_role r on ur.role_id = r.id
-        WHERE b.parent_id = '024b0dc0840045afb048022a8c61253f'  <!-- 快手运营部 -->
+        WHERE b.parent_id = '024b0dc0840045afb048022a8c61253f'
         and r.role_code = 'kuaishouOperationManager'
     </select>
 
@@ -1507,7 +1478,7 @@
         left join sys_user u on ud.user_id = u.id
         left join sys_user_role ur on u.id = ur.user_id
         left join sys_role r on ur.role_id = r.id
-        WHERE b.parent_id = 'c869de6bedc44a50803e45a4611df05e'  <!-- 头条运营部 -->
+        WHERE b.parent_id = 'c869de6bedc44a50803e45a4611df05e'
         and r.role_code = 'toutiaoOperationManager'
     </select>
 
@@ -1604,9 +1575,9 @@
         select
         id as projectId,
         project_name as projectName,
-        advertiser_name as advertiserName,  <!-- 广告主 -->
-        responsible_name as responsibleName,  <!-- 负责人名称 -->
-        design_responsible_name as designResponsibleName, <!-- 设计负责人名称 -->
+        advertiser_name as advertiserName,
+        responsible_name as responsibleName,
+        design_responsible_name as designResponsibleName,
         (select sum(cost) from ctop_performance_account where account_id in (
         select
         account_id
@@ -1678,12 +1649,11 @@
         d4.realname as clip,
         d4.id as clipId
         from
-        (
-        select signature, sum(charge) as charge from ctop_kuaishou_report_daily_creative where creative_id in (
+        (select signature, sum(charge) as charge from ctop_kuaishou_report_daily_creative where creative_id in (
         select creative_id from ctop_kuaishou_creative where photo_id != 0 and account_id = #{accountId}
         )
-        and stat_date &gt;= #{startDate} and stat_date &lt;= #{endDate} <!-- and signature is not null --> group by
-        signature
+        and stat_date &gt;= #{startDate} and stat_date &lt;= #{endDate}
+         group by signature
         ) a
         left join (select id,url,code from ctop_material_info group by code) b on a.signature = b.code
         left join ctop_material_ascription c on b.id = c.material_id
@@ -1691,7 +1661,7 @@
         left join sys_user d2 on d2.id = c.plan_id
         left join sys_user d3 on d3.id = c.plane_id
         left join sys_user d4 on d4.id = c.clip_id
-        where b.url is not null <!-- TODO delete -->
+        where b.url is not null
     </select>
 
     <!-- 头条根据账户获取其下视频制作信息以及消耗 -->
@@ -1717,7 +1687,7 @@
         )
         and date_format(stat_datetime,'%Y-%m-%d') &gt;= #{startDate}
         and date_format(stat_datetime,'%Y-%m-%d') &lt;= #{endDate}
-        <!--and  signature is not null --> group by signature
+        group by signature
         ) a
         left join (select id,url,code from ctop_material_info group by code) b on a.signature = b.code
         left join ctop_material_ascription c on b.id = c.material_id
@@ -1725,7 +1695,7 @@
         left join sys_user d2 on d2.id = c.plan_id
         left join sys_user d3 on d3.id = c.plane_id
         left join sys_user d4 on d4.id = c.clip_id
-        where b.url is not null <!-- TODO delete -->
+        where b.url is not null
     </select>
 
     <!-- 根据设计师组员姓名获取组长姓名 -->
@@ -1737,7 +1707,7 @@
         left join sys_user_depart b on a.id = b.user_id
         left join sys_user_role c on a.id = c.user_id
         where b.dep_id = (select dep_id from sys_user_depart where user_id = #{userId})
-        and c.role_id = '8d3e2ed58bdedf17716f698ea674da27' <!-- 设计组长roleid -->
+        and c.role_id = '8d3e2ed58bdedf17716f698ea674da27'
     </select>
 
     <select id="getUserQuarterVideo" resultType="cn.com.ctop.userefficientvideomap.entity.VideoDTO">