Pu Zhibing
2025-02-27 f0a9a41697a8568e8b3bd3436c450e68b3298916
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
package com.panzhihua.timejob.jobhandler;
 
import javax.annotation.Resource;
 
import com.panzhihua.common.service.community.CommunityService;
import com.panzhihua.common.service.partybuilding.NewStriveForFeign;
import org.springframework.stereotype.Component;
 
import com.panzhihua.common.model.vos.R;
import com.panzhihua.common.service.user.UserService;
import com.xxl.job.core.biz.model.ReturnT;
import com.xxl.job.core.handler.annotation.XxlJob;
 
import lombok.extern.slf4j.Slf4j;
 
/**
 * @program: springcloud_k8s_panzhihuazhihuishequ
 * @description: 用户相关
 * @author: huang.hongfa weixin hhf9596 qq 959656820
 * @create: 2021-01-14 16:09
 **/
@Slf4j
@Component
public class UserJobHandler {
 
    @Resource
    private UserService userService;
 
    @Resource
    private CommunityService communityService;
 
    @Resource
    private NewStriveForFeign newStriveForFeign;
 
    /**
     * 维护用户持续登录天数
     * 
     * @return 维护个数
     * @throws Exception
     *             出现的异常
     */
    @XxlJob("timedTaskContinuousLandingDaysJobHandler")
    public ReturnT<String> timedTaskContinuousLandingDaysJobHandler(String param) throws Exception {
        log.info("维护用户持续登录天数");
        R r = userService.timedTaskContinuousLandingDays();
        log.info("执行结果【{}】", r.toString());
        return ReturnT.SUCCESS;
    }
 
    /**
     * 社区活动自动定时更新用户未签退时间
     * @param param
     * @return
     * @throws Exception
     */
    @XxlJob("comActActRegistUpdateEndTime")
    public ReturnT<String> comActActRegistUpdateEndTime(String param) throws Exception {
        log.info("社区活动自动定时更新用户未签退时间");
        R r = communityService.comActActRegistUpdateEndTime();
        log.info("执行结果【{}】", r.toString());
        return ReturnT.SUCCESS;
    }
 
    /**
     * 自动更新新双争双评需求问题清单未签退时间
     * @param param
     * @return
     * @throws Exception
     */
    @XxlJob("upNewFightNeedProblemClaimEndTime")
    public ReturnT<String> upNewFightNeedProblemClaimEndTime(String param) throws Exception {
        log.info("社区活动自动定时更新用户未签退时间");
        R r = newStriveForFeign.upNewFightNeedProblemClaimEndTime();
        log.info("执行结果【{}】", r.toString());
        return ReturnT.SUCCESS;
    }
 
 
 
 
 
}