yumeng 4 gadi atpakaļ
vecāks
revīzija
9bab50d464

+ 3 - 0
module-job-kuaishou/src/main/java/cn/com/ctop/job/kuaishou/handler/KuaishouCreateCreativeJob.java

@@ -29,6 +29,9 @@ public class KuaishouCreateCreativeJob {
         templateQueryWrapper.orderByAsc("create_time");
         templateQueryWrapper.last("limit 20");
         List<KuaiShouGroupTemplate> list = groupTemplateService.list(templateQueryWrapper);
+        if (Check.isNull(list)) {
+            return;
+        }
         for (KuaiShouGroupTemplate template : list) {
             CtopOauthToken token = tokenService.getTokenByAccountId(template.getAccountId());
             if (Check.isNull(token)) {

+ 13 - 0
module-kuaishou/src/main/java/cn/com/ctop/kuaishou/modules/batch/controller/BatchController.java

@@ -1201,6 +1201,19 @@ public class BatchController {
         return result;
     }
 
+
+    @GetMapping(value = "/getActionBarTextByType")
+    public Result<List<KuaiShouActionBarText>> getActionBarTextByType(Integer type) {
+        Result<List<KuaiShouActionBarText>> result = new Result<>();
+        QueryWrapper<KuaiShouActionBarText> queryWrapper = new QueryWrapper<>();
+        queryWrapper.eq("type", type);
+        List<KuaiShouActionBarText> list = actionBarTextService.list(queryWrapper);
+        result.setSuccess(true);
+        result.setResult(list);
+        return result;
+    }
+
+
     /**
      * 创建创意
      *

+ 0 - 2
module-kuaishou/src/main/java/cn/com/ctop/kuaishou/modules/batch/controller/KuaiShouGroupTemplateController.java

@@ -102,14 +102,12 @@ public class KuaiShouGroupTemplateController {
      */
     @GetMapping(value = "/getApiCreateCount")
     public Result<Integer> getApiCreateCount(Long accountId) {
-
         Result<Integer> result = new Result<>();
         try {
             if (Check.isNull(accountId)) {
                 throw new Exception("accountId参数不能为空");
             }
             String date = DateUtils.getNowDate("yyyy-MM-dd");
-
             Integer count = kuaiShouGroupTemplateService.getApiCreateCount(accountId, date);
             result.setSuccess(true);
             result.setResult(count);

+ 1 - 1
module-kuaishou/src/main/java/cn/com/ctop/kuaishou/modules/batch/mapper/xml/KuaiShouGroupTemplateMapper.xml

@@ -24,7 +24,7 @@
     select count(1)
     from
     ctop_kuaishou_creative
-    where  aaccount_id = #{accountId}
+    where  account_id = #{accountId}
     and DATE_FORMAT(creative_create_time,'%Y-%m-%d') = #{date}
     </select>