yumeng 5 vuotta sitten
vanhempi
commit
b862e2413d

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

@@ -147,7 +147,7 @@ public class SampleTest {
     @Test
     public void testMail() throws Exception {
         // String accessToken, Long advertiserId, Date startDate, Date endDate, Integer page
-        kuaishouInterfaceService.getTargetingTags(23212L, "c1c5f8c03bd6981e85b677bb6cdc8beb");
+        kuaishouInterfaceService.getTargetingTags(23212L, "cbe8dfe599d36ff59417d5037bbc0a15");
     }
 
 

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

@@ -4,12 +4,10 @@ package cn.com.ctop.kuaishou.modules.batch.controller;
 import cn.com.ctop.common.module.entity.CtopOauthToken;
 import cn.com.ctop.common.module.service.ICtopOauthTokenService;
 import cn.com.ctop.common.module.utils.Check;
-import cn.com.ctop.kuaishou.modules.batch.entity.KuaiShouAppList;
-import cn.com.ctop.kuaishou.modules.batch.entity.KuaiShouCampaign;
-import cn.com.ctop.kuaishou.modules.batch.entity.KuaiShouGroup;
-import cn.com.ctop.kuaishou.modules.batch.entity.KuaiShouRegionListParent;
+import cn.com.ctop.kuaishou.modules.batch.entity.*;
 import cn.com.ctop.kuaishou.modules.batch.entity.vo.SpendVo;
 import cn.com.ctop.kuaishou.modules.batch.mapper.KuaiShouRegionListParentMapper;
+import cn.com.ctop.kuaishou.modules.batch.mapper.KuaiShouTargetingTagsMapper;
 import cn.com.ctop.kuaishou.modules.batch.service.*;
 import com.alibaba.fastjson.JSONArray;
 import com.alibaba.fastjson.JSONObject;
@@ -52,6 +50,8 @@ public class BatchController {
     private KuaiShouRegionListParentMapper regionListParentMapper;
     @Autowired
     private IKuaiShouAppListService kuaiShouAppListService;
+    @Autowired
+    private KuaiShouTargetingTagsMapper targetingTagsMapper;
 
 
     /**
@@ -402,4 +402,31 @@ public class BatchController {
     }
 
 
+    /**
+     * 获取商业兴趣
+     *
+     * @param kuaiShouTargetingTags BUSINESS_INTEREST:商业兴趣
+     *                              APP_INTEREST:APP行为
+     *                              FANS_STAR:网红类别
+     *                              INTEREST_VIDEO:兴趣视频
+     * @param req
+     * @return
+     */
+    @GetMapping(value = "/getTargetList")
+    public Result<List<KuaiShouTargetingTags>> getTargetList(KuaiShouTargetingTags kuaiShouTargetingTags, HttpServletRequest req) {
+        Result<List<KuaiShouTargetingTags>> result = new Result<>();
+        try {
+            QueryWrapper<KuaiShouTargetingTags> queryWrapper = QueryGenerator.initQueryWrapper(kuaiShouTargetingTags, req.getParameterMap());
+            queryWrapper.orderByAsc("tag_id");
+            List<KuaiShouTargetingTags> targetingTagList = targetingTagsMapper.selectList(queryWrapper);
+            result.setSuccess(true);
+            result.setResult(targetingTagList);
+        } catch (Exception e) {
+            e.printStackTrace();
+            result.setSuccess(false);
+        }
+        return result;
+    }
+
+
 }