Jelajahi Sumber

fix 推送任务

zhaotx 3 bulan lalu
induk
melakukan
c3c0cd343e

+ 1 - 2
job-bytedance/src/main/java/cn/com/ctop/job/bytedance/controller/FeishuController.java

@@ -62,8 +62,7 @@ public class FeishuController {
     IUserLoginRecordService userLoginRecordService;
     @PostMapping("/test")
     public void test(@RequestBody String str) throws Exception {
-        ztPolicyRunService.test();
-
+        cutGroupRankPushService.test();
     }
 
     private void sendFs(){

+ 2 - 0
job-bytedance/src/main/java/cn/com/ctop/job/bytedance/data/mapper/xml/ReportsAdPushMapper.xml

@@ -684,6 +684,7 @@
         left join tidb.deepthink.sys_dept c
         on b.dept_id=c.dept_id
         where dept_name is not null
+        and b.user_id in (select distinct user_id from tidb.deepthink.sys_user_role where role_id in (103,104))
         group by dept_name
     </select>
     <select id="cutUserRank" resultType="java.util.Map">
@@ -698,6 +699,7 @@
         left join tidb.deepthink.sys_dept c
         on b.dept_id=c.dept_id
         where stat_datetime=${date} and b.dept_id=${deptId} and b.status=0 and b.del_flag=0
+        and b.user_id in (select distinct user_id from tidb.deepthink.sys_user_role where role_id in (103,104))
     </select>
     <select id="allBusinessPushData" resultType="java.util.Map">
         select

+ 2 - 0
job-bytedance/src/main/java/cn/com/ctop/job/bytedance/data/service/ICutGroupRankPushService.java

@@ -8,5 +8,7 @@ public interface ICutGroupRankPushService
 {
     void send();
 
+    void test();
+
     void send(List<FeishuSendObject> sendObjects);
 }

+ 10 - 0
job-bytedance/src/main/java/cn/com/ctop/job/bytedance/data/service/impl/CutGroupRankPushServiceImpl.java

@@ -38,6 +38,16 @@ public class CutGroupRankPushServiceImpl implements ICutGroupRankPushService {
 
 
     @Override
+    public void test() {
+        List<String> userIds = Arrays.asList(
+                "HR-00446"
+        );
+        List<String> chatids = Arrays.asList(
+        );
+        send(userIds, chatids);
+    }
+
+    @Override
     public void send() {
         List<String> userIds = Arrays.asList(
                 "HR-00446"