Explorar o código

修改广告组 广告创意

yumeng %!s(int64=5) %!d(string=hai) anos
pai
achega
da51a0a477
Modificáronse 21 ficheiros con 118 adicións e 1255 borrados
  1. 0 1
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/controller/KuaiShouCreateController.java
  2. 0 242
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/controller/KuaiShouGroupCreateController.java
  3. 28 0
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/controller/KuaiShouGroupCreateLogController.java
  4. 0 1
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/controller/KuaiShouVideoController.java
  5. 0 166
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/entity/KuaiShouGroupCreate.java
  6. 25 4
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/entity/KuaiShouGroupCreateLog.java
  7. 7 0
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/entity/KuaiShouImage.java
  8. 7 0
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/entity/KuaiShouVideo.java
  9. 0 14
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/mapper/KuaiShouGroupCreateMapper.java
  10. 0 5
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/mapper/xml/KuaiShouGroupCreateMapper.xml
  11. 0 14
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/service/IKuaiShouGroupCreateService.java
  12. 2 0
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/service/impl/KuaiShouCampaignTemplateServiceImpl.java
  13. 28 6
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/service/impl/KuaiShouCreateServiceImpl.java
  14. 0 19
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/service/impl/KuaiShouGroupCreateServiceImpl.java
  15. 1 0
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/service/impl/KuaiShouImageServiceImpl.java
  16. 1 0
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/service/impl/KuaiShouVideoServiceImpl.java
  17. 17 51
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/service/impl/KuaishouInterfaceServiceImpl.java
  18. 0 263
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/vue/KuaiShouGroupCreateList.vue
  19. 0 230
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/vue/modules/KuaiShouGroupCreateModal.vue
  20. 0 237
      jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/vue/modules/KuaiShouGroupCreateModal__Style#Drawer.vue
  21. 2 2
      module-kuaishou/src/main/java/constant/KuaishouInterfaceConstant.java

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

@@ -1,6 +1,5 @@
 package org.jeecg.modules.kuaishou.controller;
 
-import com.alibaba.fastjson.JSON;
 import com.alibaba.fastjson.JSONArray;
 import com.alibaba.fastjson.JSONObject;
 import org.jeecg.common.api.vo.Result;

+ 0 - 242
jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/controller/KuaiShouGroupCreateController.java

@@ -1,242 +0,0 @@
-package org.jeecg.modules.kuaishou.controller;
-
-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.aspect.annotation.AutoLog;
-import org.jeecg.common.system.query.QueryGenerator;
-import org.jeecg.common.util.oConvertUtils;
-import org.jeecg.modules.kuaishou.entity.KuaiShouGroupCreate;
-import org.jeecg.modules.kuaishou.service.IKuaiShouGroupCreateService;
-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.util.Arrays;
-import java.util.List;
-import java.util.Map;
-
- /**
-  * @Description: 快手-创建广告组信息
- * @Author: jeecg-boot
-  * @Date: 2019-07-24
- * @Version: V1.0
- */
-@Slf4j
-@Api(tags = "快手-创建广告组信息")
-@RestController
-@RequestMapping("/kuaishou/kuaiShouGroupCreate")
-public class KuaiShouGroupCreateController {
-	@Autowired
-    private IKuaiShouGroupCreateService kuaiShouGroupCreateService;
-	
-	/**
-	  * 分页列表查询
-     * @param kuaiShouGroupCreate
-	 * @param pageNo
-	 * @param pageSize
-	 * @param req
-	 * @return
-	 */
-    @AutoLog(value = "快手-创建广告组信息-分页列表查询")
-    @ApiOperation(value = "快手-创建广告组信息-分页列表查询", notes = "快手-创建广告组信息-分页列表查询")
-	@GetMapping(value = "/list")
-    public Result<IPage<KuaiShouGroupCreate>> queryPageList(KuaiShouGroupCreate kuaiShouGroupCreate,
-                                                            @RequestParam(name = "pageNo", defaultValue = "1") Integer pageNo,
-                                                            @RequestParam(name = "pageSize", defaultValue = "10") Integer pageSize,
-                                                            HttpServletRequest req) {
-        Result<IPage<KuaiShouGroupCreate>> result = new Result<IPage<KuaiShouGroupCreate>>();
-        QueryWrapper<KuaiShouGroupCreate> queryWrapper = QueryGenerator.initQueryWrapper(kuaiShouGroupCreate, req.getParameterMap());
-        Page<KuaiShouGroupCreate> page = new Page<KuaiShouGroupCreate>(pageNo, pageSize);
-        IPage<KuaiShouGroupCreate> pageList = kuaiShouGroupCreateService.page(page, queryWrapper);
-		result.setSuccess(true);
-		result.setResult(pageList);
-		return result;
-	}
-	
-	/**
-	  *   添加
-     * @param kuaiShouGroupCreate
-	 * @return
-	 */
-    @AutoLog(value = "快手-创建广告组信息-添加")
-    @ApiOperation(value = "快手-创建广告组信息-添加", notes = "快手-创建广告组信息-添加")
-	@PostMapping(value = "/add")
-    public Result<KuaiShouGroupCreate> add(@RequestBody KuaiShouGroupCreate kuaiShouGroupCreate) {
-        Result<KuaiShouGroupCreate> result = new Result<KuaiShouGroupCreate>();
-		try {
-            kuaiShouGroupCreateService.save(kuaiShouGroupCreate);
-			result.success("添加成功!");
-		} catch (Exception e) {
-			log.error(e.getMessage(),e);
-			result.error500("操作失败");
-		}
-		return result;
-	}
-	
-	/**
-	  *  编辑
-     * @param kuaiShouGroupCreate
-	 * @return
-	 */
-    @AutoLog(value = "快手-创建广告组信息-编辑")
-    @ApiOperation(value = "快手-创建广告组信息-编辑", notes = "快手-创建广告组信息-编辑")
-	@PutMapping(value = "/edit")
-    public Result<KuaiShouGroupCreate> edit(@RequestBody KuaiShouGroupCreate kuaiShouGroupCreate) {
-        Result<KuaiShouGroupCreate> result = new Result<KuaiShouGroupCreate>();
-        KuaiShouGroupCreate kuaiShouGroupCreateEntity = kuaiShouGroupCreateService.getById(kuaiShouGroupCreate.getId());
-        if (kuaiShouGroupCreateEntity == null) {
-			result.error500("未找到对应实体");
-		}else {
-            boolean ok = kuaiShouGroupCreateService.updateById(kuaiShouGroupCreate);
-			//TODO 返回false说明什么?
-			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 {
-            kuaiShouGroupCreateService.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<KuaiShouGroupCreate> deleteBatch(@RequestParam(name = "ids", required = true) String ids) {
-        Result<KuaiShouGroupCreate> result = new Result<KuaiShouGroupCreate>();
-		if(ids==null || "".equals(ids.trim())) {
-			result.error500("参数不识别!");
-		}else {
-            this.kuaiShouGroupCreateService.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<KuaiShouGroupCreate> queryById(@RequestParam(name = "id", required = true) String id) {
-        Result<KuaiShouGroupCreate> result = new Result<KuaiShouGroupCreate>();
-        KuaiShouGroupCreate kuaiShouGroupCreate = kuaiShouGroupCreateService.getById(id);
-        if (kuaiShouGroupCreate == null) {
-			result.error500("未找到对应实体");
-		}else {
-            result.setResult(kuaiShouGroupCreate);
-			result.setSuccess(true);
-		}
-		return result;
-	}
-
-  /**
-      * 导出excel
-   *
-   * @param request
-   * @param response
-   */
-  @RequestMapping(value = "/exportXls")
-  public ModelAndView exportXls(HttpServletRequest request, HttpServletResponse response) {
-      // Step.1 组装查询条件
-      QueryWrapper<KuaiShouGroupCreate> queryWrapper = null;
-      try {
-          String paramsStr = request.getParameter("paramsStr");
-          if (oConvertUtils.isNotEmpty(paramsStr)) {
-              String deString = URLDecoder.decode(paramsStr, "UTF-8");
-              KuaiShouGroupCreate kuaiShouGroupCreate = JSON.parseObject(deString, KuaiShouGroupCreate.class);
-              queryWrapper = QueryGenerator.initQueryWrapper(kuaiShouGroupCreate, request.getParameterMap());
-          }
-      } catch (UnsupportedEncodingException e) {
-          e.printStackTrace();
-      }
-
-      //Step.2 AutoPoi 导出Excel
-      ModelAndView mv = new ModelAndView(new JeecgEntityExcelView());
-      List<KuaiShouGroupCreate> pageList = kuaiShouGroupCreateService.list(queryWrapper);
-      //导出文件名称
-      mv.addObject(NormalExcelConstants.FILE_NAME, "快手-创建广告组信息列表");
-      mv.addObject(NormalExcelConstants.CLASS, KuaiShouGroupCreate.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<KuaiShouGroupCreate> listKuaiShouGroupCreates = ExcelImportUtil.importExcel(file.getInputStream(), KuaiShouGroupCreate.class, params);
-              kuaiShouGroupCreateService.saveBatch(listKuaiShouGroupCreates);
-              return Result.ok("文件导入成功!数据行数:" + listKuaiShouGroupCreates.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("文件导入失败!");
-  }
-
-}

+ 28 - 0
jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/controller/KuaiShouGroupCreateLogController.java

@@ -85,6 +85,34 @@ public class KuaiShouGroupCreateLogController {
         return result;
     }
 
+
+    /**
+     * 分页列表查询
+     *
+     * @param kuaiShouGroupCreateLog
+
+     * @param req
+     * @return
+     */
+    @AutoLog(value = "快手-批量创建广告组-分页列表查询")
+    @ApiOperation(value = "快手-批量创建广告组-分页列表查询", notes = "快手-批量创建广告组-分页列表查询")
+    @GetMapping(value = "/select/group")
+    public KuaiShouGroupCreateLog queryPageList(KuaiShouGroupCreateLog kuaiShouGroupCreateLog,
+                                                HttpServletRequest req) {
+        Result<IPage<KuaiShouGroupCreateLog>> result = new Result<IPage<KuaiShouGroupCreateLog>>();
+        QueryWrapper<KuaiShouGroupCreateLog> queryWrapper = QueryGenerator.initQueryWrapper(kuaiShouGroupCreateLog, req.getParameterMap());
+        LoginUser user = (LoginUser) SecurityUtils.getSubject().getPrincipal();
+        if (!Check.isNull(user)) {
+            queryWrapper.eq("login_id", user.getId());
+        }
+        queryWrapper.orderByDesc("create_time");
+        queryWrapper.last("limit 1");
+        KuaiShouGroupCreateLog groupCreateLog = (KuaiShouGroupCreateLog) kuaiShouGroupCreateLogService.getObj(queryWrapper);
+        System.err.println(groupCreateLog);
+
+        return groupCreateLog;
+    }
+
     /**
      * 添加
      *

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

@@ -57,7 +57,6 @@ public class KuaiShouVideoController {
 
     @PostMapping(value = "/insert")
     public Result<KuaiShouVideo> insert(@RequestBody JSONObject requestJson) {
-        System.err.println(requestJson);
         Result<KuaiShouVideo> result = new Result<>();
         try {
             kuaiShouVideoService.insert(requestJson);

+ 0 - 166
jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/entity/KuaiShouGroupCreate.java

@@ -1,166 +0,0 @@
-package org.jeecg.modules.kuaishou.entity;
-
-import com.baomidou.mybatisplus.annotation.IdType;
-import com.baomidou.mybatisplus.annotation.TableId;
-import com.baomidou.mybatisplus.annotation.TableName;
-import com.fasterxml.jackson.annotation.JsonFormat;
-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 org.springframework.format.annotation.DateTimeFormat;
-
-import java.util.Date;
-
-/**
- * @Description: 快手-创建广告组信息
- * @Author: jeecg-boot
- * @Date: 2019-07-24
- * @Version: V1.0
- */
-@Data
-@TableName("ctop_kuaishou_group_create")
-@EqualsAndHashCode(callSuper = false)
-@Accessors(chain = true)
-@ApiModel(value = "ctop_kuaishou_group_create对象", description = "快手-创建广告组信息")
-public class KuaiShouGroupCreate {
-
-    /**
-     * id
-     */
-    @TableId(type = IdType.AUTO)
-    @ApiModelProperty(value = "id")
-    private Long id;
-    /**
-     * 账户ID
-     */
-    @Excel(name = "账户ID", width = 15)
-    @ApiModelProperty(value = "账户ID")
-    private Long accountId;
-    /**
-     * 广告活动ID
-     */
-    @Excel(name = "广告活动ID", width = 15)
-    @ApiModelProperty(value = "广告活动ID")
-    private Long campaignId;
-    /**
-     * 广告组名称
-     */
-    @Excel(name = "广告组名称", width = 15)
-    @ApiModelProperty(value = "广告组名称")
-    private String unitName;
-    /**
-     * 出价类型
-     */
-    @Excel(name = "出价类型", width = 15)
-    @ApiModelProperty(value = "出价类型")
-    private Integer bidType;
-    /**
-     * 出价
-     */
-    @Excel(name = "出价", width = 15)
-    @ApiModelProperty(value = "出价")
-    private Integer bid;
-    /**
-     * OCPC出价
-     */
-    @Excel(name = "OCPC出价", width = 15)
-    @ApiModelProperty(value = "OCPC出价")
-    private Integer cpaBid;
-    /**
-     * 优化目标
-     */
-    @Excel(name = "优化目标", width = 15)
-    @ApiModelProperty(value = "优化目标")
-    private Integer ocpxActionType;
-    /**
-     * 深度转化目标
-     */
-    @Excel(name = "深度转化目标", width = 15)
-    @ApiModelProperty(value = "深度转化目标")
-    private Integer deepConversionType;
-    /**
-     * 资源位置
-     */
-    @Excel(name = "资源位置", width = 15)
-    @ApiModelProperty(value = "资源位置")
-    private Integer page;
-    /**
-     * 投放开始时间
-     */
-    @Excel(name = "投放开始时间", width = 15)
-    @ApiModelProperty(value = "投放开始时间")
-    private String beginTime;
-    /**
-     * 投放结束时间
-     */
-    @Excel(name = "投放结束时间", width = 15)
-    @ApiModelProperty(value = "投放结束时间")
-    private String endTime;
-    /**
-     * 投放时段
-     */
-    @Excel(name = "投放时段", width = 15)
-    @ApiModelProperty(value = "投放时段")
-    private String scheduleTime;
-    /**
-     * 单日预算
-     */
-    @Excel(name = "单日预算", width = 15)
-    @ApiModelProperty(value = "单日预算")
-    private Long dayBudget;
-    /**
-     * url类型 1:淘宝商品短链 2:淘宝商品 itemID
-     */
-    @Excel(name = "url类型 1:淘宝商品短链 2:淘宝商品 itemID", width = 15)
-    @ApiModelProperty(value = "url类型 1:淘宝商品短链 2:淘宝商品 itemID")
-    private Integer urlType;
-    /**
-     * 投放链接
-     */
-    @Excel(name = "投放链接", width = 15)
-    @ApiModelProperty(value = "投放链接")
-    private Object url;
-    /**
-     * APP ID
-     */
-    @Excel(name = "APP ID", width = 15)
-    @ApiModelProperty(value = "APP ID")
-    private Long appId;
-    /**
-     * 创意展现方式  1:轮播 2:优选
-     */
-    @Excel(name = "创意展现方式  1:轮播 2:优选", width = 15)
-    @ApiModelProperty(value = "创意展现方式  1:轮播 2:优选")
-    private Integer showModel;
-    /**
-     * 投放方式 1:快速投放 2:平滑投放
-     */
-    @Excel(name = "投放方式 1:快速投放 2:平滑投放", width = 15)
-    @ApiModelProperty(value = "投放方式 1:快速投放 2:平滑投放")
-    private Integer speed;
-    /**
-     * 广告组ID
-     */
-    @Excel(name = "广告组ID", width = 15)
-    @ApiModelProperty(value = "广告组ID")
-    private Long unitId;
-    /**
-     * 创建时间
-     */
-    @Excel(name = "创建时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
-    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
-    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
-    @ApiModelProperty(value = "创建时间")
-    private Date createTime;
-    /**
-     * 修改时间
-     */
-    @Excel(name = "修改时间", width = 20, format = "yyyy-MM-dd HH:mm:ss")
-    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
-    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
-    @ApiModelProperty(value = "修改时间")
-    private Date updateTime;
-}

+ 25 - 4
jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/entity/KuaiShouGroupCreateLog.java

@@ -69,13 +69,13 @@ public class KuaiShouGroupCreateLog {
      */
     @Excel(name = "出价", width = 15)
     @ApiModelProperty(value = "出价")
-    private Integer bid;
+    private Long bid;
     /**
      * OCPC出价
      */
     @Excel(name = "OCPC出价", width = 15)
     @ApiModelProperty(value = "OCPC出价")
-    private Integer cpaBid;
+    private Long cpaBid;
     /**
      * 优化目标
      */
@@ -85,21 +85,42 @@ public class KuaiShouGroupCreateLog {
     /**
      * 深度转化目标 null
      */
-    @Excel(name = "深度转化目标 null", width = 15)
+    @Excel(name = "深度转化目标", width = 15)
     @ApiModelProperty(value = "深度转化目标 null")
     private Integer deepConversionType;
+
+    /**
+     * 深度转化目标出价
+     */
+    @Excel(name = "出价", width = 15)
+    @ApiModelProperty(value = "出价")
+    private Long deepConversionBid;
+
     /**
      * 资源位置
      */
     @Excel(name = "资源位置", width = 15)
     @ApiModelProperty(value = "资源位置")
-    private Integer page;
+    private Integer sceneId;
     /**
      * 投放开始时间
      */
     @Excel(name = "投放开始时间", width = 15)
     @ApiModelProperty(value = "投放开始时间")
     private String beginTime;
+
+
+    /**
+     * 创意制作方式
+     */
+    @Excel(name = "投放开始时间", width = 15)
+    @ApiModelProperty(value = "创意制作方式")
+    private Integer unitType;
+
+
+
+
+
     /**
      * 投放结束时间
      */

+ 7 - 0
jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/entity/KuaiShouImage.java

@@ -63,6 +63,13 @@ public class KuaiShouImage {
     @Excel(name = "图片类型 1-竖版图片 2-横版图片", width = 15)
     @ApiModelProperty(value = "图片类型 1-竖版图片 2-横版图片")
     private String materialType;
+
+    /**
+     * 图片类型 1-普通 2-后贴片
+     */
+    @Excel(name = "素材类型 1-普通 2-后贴片", width = 15)
+    @ApiModelProperty(value = "图片类型 1-竖版图片 2-横版图片")
+    private String positionType;
     /**
      * 创建时间
      */

+ 7 - 0
jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/entity/KuaiShouVideo.java

@@ -69,6 +69,13 @@ public class KuaiShouVideo {
     @Excel(name = "视频类型 1-竖版视频 2-横版视频", width = 15)
     @ApiModelProperty(value = "视频类型 1-竖版视频 2-横版视频")
     private String materialType;
+
+    /**
+     * 视频类型 1-竖版视频 2-横版视频
+     */
+    @Excel(name = "素材类型 1-普通 2-后贴片", width = 15)
+    @ApiModelProperty(value = "视频类型 1-竖版视频 2-横版视频")
+    private String positionType;
     /**
      * 创建时间
      */

+ 0 - 14
jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/mapper/KuaiShouGroupCreateMapper.java

@@ -1,14 +0,0 @@
-package org.jeecg.modules.kuaishou.mapper;
-
-import com.baomidou.mybatisplus.core.mapper.BaseMapper;
-import org.jeecg.modules.kuaishou.entity.KuaiShouGroupCreate;
-
-/**
- * @Description: 快手-创建广告组信息
- * @Author: jeecg-boot
- * @Date: 2019-07-24
- * @Version: V1.0
- */
-public interface KuaiShouGroupCreateMapper extends BaseMapper<KuaiShouGroupCreate> {
-
-}

+ 0 - 5
jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/mapper/xml/KuaiShouGroupCreateMapper.xml

@@ -1,5 +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="org.jeecg.modules.kuaishou.mapper.KuaiShouGroupCreateMapper">
-
-</mapper>

+ 0 - 14
jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/service/IKuaiShouGroupCreateService.java

@@ -1,14 +0,0 @@
-package org.jeecg.modules.kuaishou.service;
-
-import org.jeecg.modules.kuaishou.entity.KuaiShouGroupCreate;
-import com.baomidou.mybatisplus.extension.service.IService;
-
-/**
- * @Description: 快手-创建广告组信息
- * @Author: jeecg-boot
- * @Date: 2019-07-24
- * @Version: V1.0
- */
-public interface IKuaiShouGroupCreateService extends IService<KuaiShouGroupCreate> {
-
-}

+ 2 - 0
jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/service/impl/KuaiShouCampaignTemplateServiceImpl.java

@@ -35,6 +35,8 @@ public class KuaiShouCampaignTemplateServiceImpl extends ServiceImpl<KuaiShouCam
         try {
             template.setDayBudget(template.getDayBudget() * 1000);
             campaignTemplateMapper.insert(template);
+
+
             resultMap.put("success", true);
             resultMap.put("message", "创建广告创意成功");
             resultMap.put("code", 0);

+ 28 - 6
jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/service/impl/KuaiShouCreateServiceImpl.java

@@ -26,7 +26,6 @@ import org.springframework.stereotype.Service;
 import java.util.HashMap;
 import java.util.List;
 import java.util.Map;
-import java.util.UUID;
 
 @Service
 public class KuaiShouCreateServiceImpl implements IKuaiShouCreateService {
@@ -177,9 +176,6 @@ public class KuaiShouCreateServiceImpl implements IKuaiShouCreateService {
             if (!Check.isNull(groupCreateTemplate.getDeepConversionType())) {
                 groupJson.put("deep_conversion_type", groupCreateTemplate.getDeepConversionType());
             }
-            if (!Check.isNull(groupCreateTemplate.getPage())) {
-                groupJson.put("page", groupCreateTemplate.getPage());
-            }
             if (!Check.isNull(groupCreateTemplate.getBeginTime())) {
                 groupJson.put("begin_time", groupCreateTemplate.getBeginTime());
             }
@@ -198,6 +194,24 @@ public class KuaiShouCreateServiceImpl implements IKuaiShouCreateService {
             if (!Check.isNull(groupCreateTemplate.getSpeed())) {
                 groupJson.put("speed", groupCreateTemplate.getSpeed());
             }
+            if (!Check.isNull(groupCreateTemplate.getSceneId())) {
+                JSONArray sceneIds = new JSONArray();
+                sceneIds.add(groupCreateTemplate.getSceneId());
+                groupJson.put("scene_id", sceneIds);
+            }
+            if (!Check.isNull(groupCreateTemplate.getUnitType())) {
+                groupJson.put("unit_type", groupCreateTemplate.getUnitType());
+            }
+
+            if (!Check.isNull(groupCreateTemplate.getDeepConversionType())) {
+                groupJson.put("deep_conversion_type", groupCreateTemplate.getDeepConversionType());
+            }
+
+            if (!Check.isNull(groupCreateTemplate.getDeepConversionBid()) && groupCreateTemplate.getDeepConversionBid() > 0) {
+                groupJson.put("deep_conversion_bid", groupCreateTemplate.getDeepConversionBid());
+            }
+
+
             JSONObject targetJson = new JSONObject();
             groupJson.put("target", targetJson);
 
@@ -283,7 +297,7 @@ public class KuaiShouCreateServiceImpl implements IKuaiShouCreateService {
 
             String videoUrl;
             String videoUploadType = requestJson.getString("videoUploadType");
-            if ("2".equals(videoUploadType)) {
+            if ("2".equals(videoUploadType)) { // 本地上传视频
                 videoUrl = videoService.localInsert(requestJson);
             } else {
                 videoUrl = requestJson.getString("videoUrl");
@@ -297,7 +311,7 @@ public class KuaiShouCreateServiceImpl implements IKuaiShouCreateService {
                 return returnMap;
             }
 
-            Map<String, Object> videoMap = kuaishouInterfaceService.videoUpload(accountId, accessToken, videoUrl);
+            Map<String, Object> videoMap = kuaishouInterfaceService.videoUpload(accountId, accessToken, videoUrl); // 上传视频到快手后台
             if ((Integer) videoMap.get("code") != 0) {
                 logger.error("上传视频失败,accountId:{}", accountId);
                 returnMap.put("code", -1);
@@ -321,6 +335,11 @@ public class KuaiShouCreateServiceImpl implements IKuaiShouCreateService {
             if (!Check.isNull(requestJson.getString("clickTrackUrl"))) {
                 createJson.put("click_track_url", requestJson.getString("clickTrackUrl"));
             }
+
+            if (!Check.isNull(requestJson.getString("showImpressionUrl"))) {
+                createJson.put("impression_url", requestJson.getString("showImpressionUrl"));
+            }
+
             JSONArray imageUrlArr = requestJson.getJSONArray("imageUrl");
             if (Check.isNull(imageUrlArr)) {
                 logger.error("请选择封面图,accountId:{}", accountId);
@@ -395,6 +414,9 @@ public class KuaiShouCreateServiceImpl implements IKuaiShouCreateService {
                 queryWrapper.eq("account_id", accountId).eq("campaign_id", campaignId).orderByDesc("create_time");
                 queryWrapper.last("limit 1");
                 KuaiShouCampaignCreate campaignCreate = campaignCreateMapper.selectOne(queryWrapper);
+                if(Check.isNull(campaignCreate)){
+                    continue;
+                }
                 optionsJson.put("label", campaignCreate.getCampaignName());
                 optionsJson.put("isLeaf", false);
                 result.add(optionsJson);

+ 0 - 19
jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/service/impl/KuaiShouGroupCreateServiceImpl.java

@@ -1,19 +0,0 @@
-package org.jeecg.modules.kuaishou.service.impl;
-
-import org.jeecg.modules.kuaishou.entity.KuaiShouGroupCreate;
-import org.jeecg.modules.kuaishou.mapper.KuaiShouGroupCreateMapper;
-import org.jeecg.modules.kuaishou.service.IKuaiShouGroupCreateService;
-import org.springframework.stereotype.Service;
-
-import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
-
-/**
- * @Description: 快手-创建广告组信息
- * @Author: jeecg-boot
- * @Date: 2019-07-24
- * @Version: V1.0
- */
-@Service
-public class KuaiShouGroupCreateServiceImpl extends ServiceImpl<KuaiShouGroupCreateMapper, KuaiShouGroupCreate> implements IKuaiShouGroupCreateService {
-
-}

+ 1 - 0
jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/service/impl/KuaiShouImageServiceImpl.java

@@ -45,6 +45,7 @@ public class KuaiShouImageServiceImpl extends ServiceImpl<KuaiShouImageMapper, K
                 image.setImageName(AesEncryptUtil.getURLDecoderString(fileNameStr));
                 image.setLoginId(requestJson.getString("loginId"));
                 image.setMaterialType(requestJson.getString("materialType"));
+                image.setPositionType(requestJson.getString("positionType"));
                 image.setLocalUrl(KuaishouInterfaceConstant.HTTPS_PREFIX + imageUrl);
                 imageMapper.insert(image);
 

+ 1 - 0
jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/service/impl/KuaiShouVideoServiceImpl.java

@@ -44,6 +44,7 @@ public class KuaiShouVideoServiceImpl extends ServiceImpl<KuaiShouVideoMapper, K
                 video.setVideoName(AesEncryptUtil.getURLDecoderString(fileNameStr));
                 video.setLocalUrl(KuaishouInterfaceConstant.HTTPS_PREFIX + url);
                 video.setMaterialType(requestJson.getString("materialType"));
+                video.setPositionType(requestJson.getString("positionType"));
                 kuaiShouVideoMapper.insert(video);
             }
         }

+ 17 - 51
jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/service/impl/KuaishouInterfaceServiceImpl.java

@@ -368,8 +368,7 @@ public class KuaishouInterfaceServiceImpl implements IKuaishouInterfaceService {
 
     @Autowired
     private KuaiShouGroupCreateTargetMapper groupCreateTargetMapper;
-    @Autowired
-    private KuaiShouGroupCreateMapper groupCreateMapper;
+
 
     @Override
     public Map<String, Object> adUnitCreate(String accessToken, Long advertiser_id, JSONObject requestJson) {
@@ -390,50 +389,7 @@ public class KuaishouInterfaceServiceImpl implements IKuaishouInterfaceService {
                 if (code == 0) {
                     JSONObject dataJson = resultJson.getJSONObject("data");
                     if (!Check.isNull(dataJson)) {
-                        KuaiShouGroupCreate groupCreate = new KuaiShouGroupCreate();
                         Long unitId = dataJson.getLong("unit_id");
-                        groupCreate.setUnitId(unitId);
-                        groupCreate.setAccountId(advertiser_id);
-                        groupCreate.setCampaignId(requestJson.getLong("campaign_id"));
-                        groupCreate.setUnitName(requestJson.getString("unit_name"));
-                        groupCreate.setBidType(requestJson.getInteger("bid_type"));
-                        groupCreate.setBid(requestJson.getInteger("bid"));
-                        groupCreate.setCpaBid(requestJson.getInteger("cpa_bid"));
-                        groupCreate.setOcpxActionType(requestJson.getInteger("ocpx_action_type"));
-                        groupCreate.setDeepConversionType(requestJson.getInteger("deep_conversion_type"));
-                        groupCreate.setPage(requestJson.getInteger("page"));
-                        groupCreate.setBeginTime(requestJson.getString("begin_time"));
-                        groupCreate.setEndTime(requestJson.getString("end_time"));
-                        groupCreate.setScheduleTime(requestJson.getString("schedule_time"));
-                        groupCreate.setDayBudget(requestJson.getLong("day_budget"));
-                        groupCreate.setUrlType(requestJson.getInteger("url_type"));
-                        groupCreate.setUrl(requestJson.getString("url"));
-                        groupCreate.setAppId(requestJson.getLong("app_id"));
-                        groupCreate.setShowModel(requestJson.getInteger("show_mode"));
-                        groupCreate.setSpeed(requestJson.getInteger("speed"));
-                        groupCreateMapper.insert(groupCreate);
-                        //定向信息
-                        JSONObject targetJson = requestJson.getJSONObject("target");
-                        if (!Check.isNull(targetJson)) {
-                            KuaiShouGroupCreateTarget groupCreateTarget = new KuaiShouGroupCreateTarget();
-                            groupCreateTarget.setAccountId(advertiser_id);
-                            groupCreateTarget.setUnitId(unitId);
-                            groupCreateTarget.setRegion(targetJson.getJSONArray("region"));
-                            JSONObject ageJson = targetJson.getJSONObject("age");
-                            if (!Check.isNull(ageJson)) {
-                                groupCreateTarget.setAgeMin(ageJson.getInteger("min"));
-                                groupCreateTarget.setAgeMax(ageJson.getInteger("max"));
-                            }
-                            groupCreateTarget.setGender(targetJson.getInteger("gender"));
-                            groupCreateTarget.setPlatformOs(targetJson.getInteger("platform_os"));
-                            groupCreateTarget.setAndroidOsv(targetJson.getInteger("android_osv"));
-                            groupCreateTarget.setIosOsv(targetJson.getInteger("ios_osv"));
-                            groupCreateTarget.setNetwork(targetJson.getInteger("network"));
-                            groupCreateTarget.setDeviceBrand(targetJson.getInteger("device_brand"));
-                            groupCreateTarget.setDevicePrice(targetJson.getJSONArray("device_price"));
-                            groupCreateTargetMapper.insert(groupCreateTarget);
-                        }
-
                         returnMap.put("code", 0);
                         returnMap.put("message", "success");
                         returnMap.put("unitId", unitId);
@@ -795,14 +751,13 @@ public class KuaishouInterfaceServiceImpl implements IKuaishouInterfaceService {
                         is_activate = dataJson.getInteger("is_activate");
                         is_form_submit = dataJson.getInteger("is_form_submit");
 
-
                         conversionInfos.setIsActivate(is_activate);
                         conversionInfos.setIsFormSubmit(is_form_submit);
                         conversionInfosMapper.insert(conversionInfos);
-                        JSONArray ConversionTypeArr = dataJson.getJSONArray("deep_conversion_types");
-                        if (!Check.isNull(ConversionTypeArr)) {
-                            for (int i = 0; i < ConversionTypeArr.size(); i++) {
-                                JSONObject conversionType = JSONObject.parseObject(ConversionTypeArr.get(i).toString());
+                        JSONArray conversionTypeArr = dataJson.getJSONArray("deep_conversion_types");
+                        if (!Check.isNull(conversionTypeArr)) {
+                            for (int i = 0; i < conversionTypeArr.size(); i++) {
+                                JSONObject conversionType = JSONObject.parseObject(conversionTypeArr.get(i).toString());
                                 if (!Check.isNull(conversionType)) {
                                     KuaiShouConversionTypes conversionTypes = new KuaiShouConversionTypes();
                                     conversionTypes.setAccountId(advertiserId);
@@ -811,13 +766,24 @@ public class KuaishouInterfaceServiceImpl implements IKuaishouInterfaceService {
                                     conversionTypesMapper.insert(conversionTypes);
                                 }
                             }
+
                         }
                     }
 
                     resultMap.put("code", 0);
                     resultMap.put("success", true);
-                    resultMap.put("isActivate", is_activate);
+                    resultMap.put("isActivate", 1);
                     resultMap.put("isFormSubmit", is_form_submit);
+                    JSONArray jsonArray = new JSONArray();
+                    JSONObject jsonObject = new JSONObject();
+                    jsonObject.put("deep_conversion_type",3);
+                    jsonObject.put("desc","付费");
+                    JSONObject jsonObject2 = new JSONObject();
+                    jsonObject2.put("deep_conversion_type",11);
+                    jsonObject2.put("desc","授信");
+                    jsonArray.add(jsonObject);
+                    jsonArray.add(jsonObject2);
+                    resultMap.put("deepConversionTypes", jsonArray);
 
                 } else {
                     logger.error("获取可选的深度转化类型返回异常,advertiserId:{},异常信息:{}", advertiserId, resultJson);

+ 0 - 263
jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/vue/KuaiShouGroupCreateList.vue

@@ -1,263 +0,0 @@
-<template>
-    <a-card :bordered="false">
-
-        <!-- 查询区域 -->
-        <div class="table-page-search-wrapper">
-            <a-form layout="inline">
-                <a-row :gutter="24">
-
-                    <a-col :md="6" :sm="8">
-                        <a-form-item label="账户ID">
-                            <a-input placeholder="请输入账户ID" v-model="queryParam.accountId"></a-input>
-                        </a-form-item>
-                    </a-col>
-                    <a-col :md="6" :sm="8">
-                        <a-form-item label="广告活动ID">
-                            <a-input placeholder="请输入广告活动ID" v-model="queryParam.campaignId"></a-input>
-                        </a-form-item>
-                    </a-col>
-                    <template v-if="toggleSearchStatus">
-                        <a-col :md="6" :sm="8">
-                            <a-form-item label="广告组名称">
-                                <a-input placeholder="请输入广告组名称" v-model="queryParam.unitName"></a-input>
-                            </a-form-item>
-                        </a-col>
-                        <a-col :md="6" :sm="8">
-                            <a-form-item label="出价类型">
-                                <a-input placeholder="请输入出价类型" v-model="queryParam.bidType"></a-input>
-                            </a-form-item>
-                        </a-col>
-                        <a-col :md="6" :sm="8">
-                            <a-form-item label="出价">
-                                <a-input placeholder="请输入出价" v-model="queryParam.bid"></a-input>
-                            </a-form-item>
-                        </a-col>
-                    </template>
-                    <a-col :md="6" :sm="8">
-            <span style="float: left;overflow: hidden;" class="table-page-search-submitButtons">
-              <a-button type="primary" @click="searchQuery" icon="search">查询</a-button>
-              <a-button type="primary" @click="searchReset" icon="reload" style="margin-left: 8px">重置</a-button>
-              <a @click="handleToggleSearch" style="margin-left: 8px">
-                {{ toggleSearchStatus ? '收起' : '展开' }}
-                <a-icon :type="toggleSearchStatus ? 'up' : 'down'"/>
-              </a>
-            </span>
-                    </a-col>
-
-                </a-row>
-            </a-form>
-        </div>
-
-        <!-- 操作按钮区域 -->
-        <div class="table-operator">
-            <a-button @click="handleAdd" type="primary" icon="plus">新增</a-button>
-            <a-button type="primary" icon="download" @click="handleExportXls('快手-创建广告组信息')">导出</a-button>
-            <a-upload name="file" :showUploadList="false" :multiple="false" :headers="tokenHeader"
-                      :action="importExcelUrl" @change="handleImportExcel">
-                <a-button type="primary" icon="import">导入</a-button>
-            </a-upload>
-            <a-dropdown v-if="selectedRowKeys.length > 0">
-                <a-menu slot="overlay">
-                    <a-menu-item key="1" @click="batchDel">
-                        <a-icon type="delete"/>
-                        删除
-                    </a-menu-item>
-                </a-menu>
-                <a-button style="margin-left: 8px"> 批量操作
-                    <a-icon type="down"/>
-                </a-button>
-            </a-dropdown>
-        </div>
-
-        <!-- table区域-begin -->
-        <div>
-            <div class="ant-alert ant-alert-info" style="margin-bottom: 16px;">
-                <i class="anticon anticon-info-circle ant-alert-icon"></i> 已选择 <a style="font-weight: 600">{{
-                selectedRowKeys.length }}</a>项
-                <a style="margin-left: 24px" @click="onClearSelected">清空</a>
-            </div>
-
-            <a-table
-                    ref="table"
-                    size="middle"
-                    bordered
-                    rowKey="id"
-                    :columns="columns"
-                    :dataSource="dataSource"
-                    :pagination="ipagination"
-                    :loading="loading"
-                    :rowSelection="{selectedRowKeys: selectedRowKeys, onChange: onSelectChange}"
-                    @change="handleTableChange">
-
-        <span slot="action" slot-scope="text, record">
-          <a @click="handleEdit(record)">编辑</a>
-
-          <a-divider type="vertical"/>
-          <a-dropdown>
-            <a class="ant-dropdown-link">更多 <a-icon type="down"/></a>
-            <a-menu slot="overlay">
-              <a-menu-item>
-                <a-popconfirm title="确定删除吗?" @confirm="() => handleDelete(record.id)">
-                  <a>删除</a>
-                </a-popconfirm>
-              </a-menu-item>
-            </a-menu>
-          </a-dropdown>
-        </span>
-
-            </a-table>
-        </div>
-        <!-- table区域-end -->
-
-        <!-- 表单区域 -->
-        <kuaiShouGroupCreate-modal ref="modalForm" @ok="modalFormOk"></kuaiShouGroupCreate-modal>
-    </a-card>
-</template>
-
-<script>
-    import KuaiShouGroupCreateModal from './modules/KuaiShouGroupCreateModal'
-    import {JeecgListMixin} from '@/mixins/JeecgListMixin'
-
-    export default {
-        name: "KuaiShouGroupCreateList",
-        mixins: [JeecgListMixin],
-        components: {
-            KuaiShouGroupCreateModal
-        },
-        data() {
-            return {
-                description: '快手-创建广告组信息管理页面',
-                // 表头
-                columns: [
-                    {
-                        title: '#',
-                        dataIndex: '',
-                        key: 'rowIndex',
-                        width: 60,
-                        align: "center",
-                        customRender: function (t, r, index) {
-                            return parseInt(index) + 1;
-                        }
-                    },
-                    {
-                        title: '账户ID',
-                        align: "center",
-                        dataIndex: 'accountId'
-                    },
-                    {
-                        title: '广告活动ID',
-                        align: "center",
-                        dataIndex: 'campaignId'
-                    },
-                    {
-                        title: '广告组名称',
-                        align: "center",
-                        dataIndex: 'unitName'
-                    },
-                    {
-                        title: '出价类型',
-                        align: "center",
-                        dataIndex: 'bidType'
-                    },
-                    {
-                        title: '出价',
-                        align: "center",
-                        dataIndex: 'bid'
-                    },
-                    {
-                        title: 'OCPC出价',
-                        align: "center",
-                        dataIndex: 'cpaBid'
-                    },
-                    {
-                        title: '优化目标',
-                        align: "center",
-                        dataIndex: 'ocpxActionType'
-                    },
-                    {
-                        title: '深度转化目标',
-                        align: "center",
-                        dataIndex: 'deepConversionType'
-                    },
-                    {
-                        title: '资源位置',
-                        align: "center",
-                        dataIndex: 'page'
-                    },
-                    {
-                        title: '投放开始时间',
-                        align: "center",
-                        dataIndex: 'beginTime'
-                    },
-                    {
-                        title: '投放结束时间',
-                        align: "center",
-                        dataIndex: 'endTime'
-                    },
-                    {
-                        title: '投放时段',
-                        align: "center",
-                        dataIndex: 'scheduleTime'
-                    },
-                    {
-                        title: '单日预算',
-                        align: "center",
-                        dataIndex: 'dayBudget'
-                    },
-                    {
-                        title: 'url类型 1:淘宝商品短链 2:淘宝商品 itemID',
-                        align: "center",
-                        dataIndex: 'urlType'
-                    },
-                    {
-                        title: '投放链接',
-                        align: "center",
-                        dataIndex: 'url'
-                    },
-                    {
-                        title: 'APP ID',
-                        align: "center",
-                        dataIndex: 'appId'
-                    },
-                    {
-                        title: '创意展现方式  1:轮播 2:优选',
-                        align: "center",
-                        dataIndex: 'showModel'
-                    },
-                    {
-                        title: '投放方式 1:快速投放 2:平滑投放',
-                        align: "center",
-                        dataIndex: 'speed'
-                    },
-                    {
-                        title: '广告组ID',
-                        align: "center",
-                        dataIndex: 'unitId'
-                    },
-                    {
-                        title: '操作',
-                        dataIndex: 'action',
-                        align: "center",
-                        scopedSlots: {customRender: 'action'},
-                    }
-                ],
-                url: {
-                    list: "/kuaishou/kuaiShouGroupCreate/list",
-                    delete: "/kuaishou/kuaiShouGroupCreate/delete",
-                    deleteBatch: "/kuaishou/kuaiShouGroupCreate/deleteBatch",
-                    exportXlsUrl: "kuaishou/kuaiShouGroupCreate/exportXls",
-                    importExcelUrl: "kuaishou/kuaiShouGroupCreate/importExcel",
-                },
-            }
-        },
-        computed: {
-            importExcelUrl: function () {
-                return `${window._CONFIG['domianURL']}/${this.url.importExcelUrl}`;
-            }
-        },
-        methods: {}
-    }
-</script>
-<style scoped>
-    @import '~@assets/less/common.less'
-</style>

+ 0 - 230
jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/vue/modules/KuaiShouGroupCreateModal.vue

@@ -1,230 +0,0 @@
-<template>
-    <a-modal
-            :title="title"
-            :width="800"
-            :visible="visible"
-            :confirmLoading="confirmLoading"
-            @ok="handleOk"
-            @cancel="handleCancel"
-            cancelText="关闭">
-
-        <a-spin :spinning="confirmLoading">
-            <a-form :form="form">
-
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="账户ID">
-                    <a-input placeholder="请输入账户ID" v-decorator="['accountId', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="广告活动ID">
-                    <a-input placeholder="请输入广告活动ID" v-decorator="['campaignId', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="广告组名称">
-                    <a-input placeholder="请输入广告组名称" v-decorator="['unitName', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="出价类型">
-                    <a-input-number v-decorator="[ 'bidType', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="出价">
-                    <a-input placeholder="请输入出价" v-decorator="['bid', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="OCPC出价">
-                    <a-input placeholder="请输入OCPC出价" v-decorator="['cpaBid', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="优化目标">
-                    <a-input-number v-decorator="[ 'ocpxActionType', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="深度转化目标">
-                    <a-input-number v-decorator="[ 'deepConversionType', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="资源位置">
-                    <a-input-number v-decorator="[ 'page', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="投放开始时间">
-                    <a-input placeholder="请输入投放开始时间" v-decorator="['beginTime', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="投放结束时间">
-                    <a-input placeholder="请输入投放结束时间" v-decorator="['endTime', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="投放时段">
-                    <a-input placeholder="请输入投放时段" v-decorator="['scheduleTime', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="单日预算">
-                    <a-input placeholder="请输入单日预算" v-decorator="['dayBudget', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="url类型 1:淘宝商品短链 2:淘宝商品 itemID">
-                    <a-input-number v-decorator="[ 'urlType', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="投放链接">
-                    <a-input placeholder="请输入投放链接" v-decorator="['url', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="APP ID">
-                    <a-input placeholder="请输入APP ID" v-decorator="['appId', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="创意展现方式  1:轮播 2:优选">
-                    <a-input-number v-decorator="[ 'showModel', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="投放方式 1:快速投放 2:平滑投放">
-                    <a-input-number v-decorator="[ 'speed', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="广告组ID">
-                    <a-input placeholder="请输入广告组ID" v-decorator="['unitId', {}]"/>
-                </a-form-item>
-
-            </a-form>
-        </a-spin>
-    </a-modal>
-</template>
-
-<script>
-    import {httpAction} from '@/api/manage'
-    import pick from 'lodash.pick'
-    import moment from "moment"
-
-    export default {
-        name: "KuaiShouGroupCreateModal",
-        data() {
-            return {
-                title: "操作",
-                visible: false,
-                model: {},
-                labelCol: {
-                    xs: {span: 24},
-                    sm: {span: 5},
-                },
-                wrapperCol: {
-                    xs: {span: 24},
-                    sm: {span: 16},
-                },
-
-                confirmLoading: false,
-                form: this.$form.createForm(this),
-                validatorRules: {},
-                url: {
-                    add: "/kuaishou/kuaiShouGroupCreate/add",
-                    edit: "/kuaishou/kuaiShouGroupCreate/edit",
-                },
-            }
-        },
-        created() {
-        },
-        methods: {
-            add() {
-                this.edit({});
-            },
-            edit(record) {
-                this.form.resetFields();
-                this.model = Object.assign({}, record);
-                this.visible = true;
-                this.$nextTick(() => {
-                    this.form.setFieldsValue(pick(this.model, 'accountId', 'campaignId', 'unitName', 'bidType', 'bid', 'cpaBid', 'ocpxActionType', 'deepConversionType', 'page', 'beginTime', 'endTime', 'scheduleTime', 'dayBudget', 'urlType', 'url', 'appId', 'showModel', 'speed', 'unitId'))
-                    //时间格式化
-                });
-
-            },
-            close() {
-                this.$emit('close');
-                this.visible = false;
-            },
-            handleOk() {
-                const that = this;
-                // 触发表单验证
-                this.form.validateFields((err, values) => {
-                    if (!err) {
-                        that.confirmLoading = true;
-                        let httpurl = '';
-                        let method = '';
-                        if (!this.model.id) {
-                            httpurl += this.url.add;
-                            method = 'post';
-                        } else {
-                            httpurl += this.url.edit;
-                            method = 'put';
-                        }
-                        let formData = Object.assign(this.model, values);
-                        //时间格式化
-
-                        console.log(formData)
-                        httpAction(httpurl, formData, method).then((res) => {
-                            if (res.success) {
-                                that.$message.success(res.message);
-                                that.$emit('ok');
-                            } else {
-                                that.$message.warning(res.message);
-                            }
-                        }).finally(() => {
-                            that.confirmLoading = false;
-                            that.close();
-                        })
-
-
-                    }
-                })
-            },
-            handleCancel() {
-                this.close()
-            },
-
-
-        }
-    }
-</script>
-
-<style lang="less" scoped>
-
-</style>

+ 0 - 237
jeecg-boot-module-system/src/main/java/org/jeecg/modules/kuaishou/vue/modules/KuaiShouGroupCreateModal__Style#Drawer.vue

@@ -1,237 +0,0 @@
-<template>
-    <a-drawer
-            :title="title"
-            :width="800"
-            placement="right"
-            :closable="false"
-            @close="close"
-            :visible="visible"
-    >
-
-        <a-spin :spinning="confirmLoading">
-            <a-form :form="form">
-
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="账户ID">
-                    <a-input placeholder="请输入账户ID" v-decorator="['accountId', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="广告活动ID">
-                    <a-input placeholder="请输入广告活动ID" v-decorator="['campaignId', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="广告组名称">
-                    <a-input placeholder="请输入广告组名称" v-decorator="['unitName', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="出价类型">
-                    <a-input-number v-decorator="[ 'bidType', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="出价">
-                    <a-input placeholder="请输入出价" v-decorator="['bid', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="OCPC出价">
-                    <a-input placeholder="请输入OCPC出价" v-decorator="['cpaBid', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="优化目标">
-                    <a-input-number v-decorator="[ 'ocpxActionType', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="深度转化目标">
-                    <a-input-number v-decorator="[ 'deepConversionType', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="资源位置">
-                    <a-input-number v-decorator="[ 'page', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="投放开始时间">
-                    <a-input placeholder="请输入投放开始时间" v-decorator="['beginTime', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="投放结束时间">
-                    <a-input placeholder="请输入投放结束时间" v-decorator="['endTime', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="投放时段">
-                    <a-input placeholder="请输入投放时段" v-decorator="['scheduleTime', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="单日预算">
-                    <a-input placeholder="请输入单日预算" v-decorator="['dayBudget', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="url类型 1:淘宝商品短链 2:淘宝商品 itemID">
-                    <a-input-number v-decorator="[ 'urlType', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="投放链接">
-                    <a-input placeholder="请输入投放链接" v-decorator="['url', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="APP ID">
-                    <a-input placeholder="请输入APP ID" v-decorator="['appId', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="创意展现方式  1:轮播 2:优选">
-                    <a-input-number v-decorator="[ 'showModel', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="投放方式 1:快速投放 2:平滑投放">
-                    <a-input-number v-decorator="[ 'speed', {}]"/>
-                </a-form-item>
-                <a-form-item
-                        :labelCol="labelCol"
-                        :wrapperCol="wrapperCol"
-                        label="广告组ID">
-                    <a-input placeholder="请输入广告组ID" v-decorator="['unitId', {}]"/>
-                </a-form-item>
-
-            </a-form>
-        </a-spin>
-        <a-button type="primary" @click="handleOk">确定</a-button>
-        <a-button type="primary" @click="handleCancel">取消</a-button>
-    </a-drawer>
-</template>
-
-<script>
-    import {httpAction} from '@/api/manage'
-    import pick from 'lodash.pick'
-    import moment from "moment"
-
-    export default {
-        name: "KuaiShouGroupCreateModal",
-        data() {
-            return {
-                title: "操作",
-                visible: false,
-                model: {},
-                labelCol: {
-                    xs: {span: 24},
-                    sm: {span: 5},
-                },
-                wrapperCol: {
-                    xs: {span: 24},
-                    sm: {span: 16},
-                },
-
-                confirmLoading: false,
-                form: this.$form.createForm(this),
-                validatorRules: {},
-                url: {
-                    add: "/kuaishou/kuaiShouGroupCreate/add",
-                    edit: "/kuaishou/kuaiShouGroupCreate/edit",
-                },
-            }
-        },
-        created() {
-        },
-        methods: {
-            add() {
-                this.edit({});
-            },
-            edit(record) {
-                this.form.resetFields();
-                this.model = Object.assign({}, record);
-                this.visible = true;
-                this.$nextTick(() => {
-                    this.form.setFieldsValue(pick(this.model, 'accountId', 'campaignId', 'unitName', 'bidType', 'bid', 'cpaBid', 'ocpxActionType', 'deepConversionType', 'page', 'beginTime', 'endTime', 'scheduleTime', 'dayBudget', 'urlType', 'url', 'appId', 'showModel', 'speed', 'unitId'))
-                    //时间格式化
-                });
-
-            },
-            close() {
-                this.$emit('close');
-                this.visible = false;
-            },
-            handleOk() {
-                const that = this;
-                // 触发表单验证
-                this.form.validateFields((err, values) => {
-                    if (!err) {
-                        that.confirmLoading = true;
-                        let httpurl = '';
-                        let method = '';
-                        if (!this.model.id) {
-                            httpurl += this.url.add;
-                            method = 'post';
-                        } else {
-                            httpurl += this.url.edit;
-                            method = 'put';
-                        }
-                        let formData = Object.assign(this.model, values);
-                        //时间格式化
-
-                        console.log(formData)
-                        httpAction(httpurl, formData, method).then((res) => {
-                            if (res.success) {
-                                that.$message.success(res.message);
-                                that.$emit('ok');
-                            } else {
-                                that.$message.warning(res.message);
-                            }
-                        }).finally(() => {
-                            that.confirmLoading = false;
-                            that.close();
-                        })
-
-
-                    }
-                })
-            },
-            handleCancel() {
-                this.close()
-            },
-
-
-        }
-    }
-</script>
-
-<style lang="less" scoped>
-    /** Button按钮间距 */
-    .ant-btn {
-        margin-left: 30px;
-        margin-bottom: 30px;
-        float: right;
-    }
-</style>

+ 2 - 2
module-kuaishou/src/main/java/constant/KuaishouInterfaceConstant.java

@@ -11,8 +11,8 @@ public class KuaishouInterfaceConstant {
     public static final String CAMPAIGN_LIST = "/rest/openapi/v1/campaign/list"; // 广告计划信息
     public static final String GROUP_LIST = "/rest/openapi/v1/ad_unit/list"; //广告组信息
     public static final String CREATIVE_LIST = "/rest/openapi/v1/creative/list"; //创意信息
-    public static final String CAMPAIGN_CREATE = "/rest/openapi/v1/campaign/create"; //创建广告计划
-    public static final String AD_UNIT_CREATE = "/rest/openapi/v1/ad_unit/create"; //创建广告组
+    public static final String CAMPAIGN_CREATE = "/rest/openapi/v2/campaign/create"; //创建广告计划
+    public static final String AD_UNIT_CREATE = "/rest/openapi/v2/ad_unit/create"; //创建广告组
     public static final String AD_CREATIVE_CREATE = "/rest/openapi/v1/creative/create"; //创建广告组