jiangping
2025-03-27 7b51c9e1abc198a501f7858599da9c116130fd6f
server/visits/dmvisit_service/src/main/java/com/doumee/service/business/impl/PlatformJobServiceImpl.java
@@ -688,10 +688,13 @@
        savePlatformLog(Constants.PlatformJobLogType.SIGN.getKey(),oldPlatformJob,platformJob,
                Constants.PlatformJobLogType.SIGN.getInfo());
        //签到微信通知 2025年3月26日14:25:00
        if(!Constants.equalsInteger(platformJob.getSingType(),Constants.TWO)&&StringUtils.isNotBlank(platformGroup.getSignInNoticeUsers())){
        logger.info("签到微信通知=========================>开始====签到类型=>"+signInDTO.getSignType()+"===>人员主键=>"+platformGroup.getSignInNoticeUsers());
        if(!Constants.equalsInteger(signInDTO.getSignType(),Constants.TWO)&&
                StringUtils.isNotBlank(platformGroup.getSignInNoticeUsers())){
            logger.info("签到微信通知=========================>进入");
            List<SystemUser> systemUserList = systemUserMapper.selectList(new QueryWrapper<SystemUser>().lambda()
                    .eq(SystemUser::getDeleted,Constants.ZERO).eq(SystemUser::getStatus,Constants.ZERO).isNotNull(SystemUser::getOpenid)
                    .in(SystemUser::getId,Arrays.asList(platformGroup.getSignInNoticeUsers().split(",")))
                    .in(SystemUser::getMemberId,Arrays.asList(platformGroup.getSignInNoticeUsers().split(",")))
            );
            if (com.github.xiaoymin.knife4j.core.util.CollectionUtils.isNotEmpty(systemUserList)) {
                WxPlatNotice wxPlatNotice = new WxPlatNotice();
@@ -702,6 +705,7 @@
                );
            }
        }
        logger.info("签到微信通知=========================>结束");
    }
@@ -734,7 +738,7 @@
                    if(Objects.nonNull(platformGroup)){
                        List<SystemUser> systemUserList = systemUserMapper.selectList(new QueryWrapper<SystemUser>().lambda()
                                .eq(SystemUser::getDeleted,Constants.ZERO).eq(SystemUser::getStatus,Constants.ZERO).isNotNull(SystemUser::getOpenid)
                                .in(SystemUser::getId,Arrays.asList(platformGroup.getUnFinishNoticeUsers().split(",")))
                                .in(SystemUser::getMemberId,Arrays.asList(platformGroup.getUnFinishNoticeUsers().split(",")))
                        );
                        if (com.github.xiaoymin.knife4j.core.util.CollectionUtils.isNotEmpty(systemUserList)) {
                            WxPlatNotice wxPlatNotice = new WxPlatNotice();
@@ -1652,7 +1656,7 @@
        platformJob.setPlatformName(platform.getName());
        this.broadcastAndLEed(platformJob,
                //Constants.PlatformLedContent.DONE.getInfo(),
                Constants.PlatformLedContent.IDEL_CONTNET.getInfo(),
                StringUtils.isBlank(platform.getLedContent())?Constants.PlatformLedContent.IDEL_CONTNET.getInfo():platform.getLedContent(),
                Constants.PlatformBroadcastContent.DONE.getInfo());
        return platformJob;
    }
@@ -2426,5 +2430,33 @@
    }
    /**
     * 手动完成作业
     * @param jobIdList
     */
    @Override
    public void dealJobFinish(List<Integer> jobIdList){
        if(com.github.xiaoymin.knife4j.core.util.CollectionUtils.isNotEmpty(jobIdList)){
            List<PlatformJob> platformJobList = platformJobMapper.selectList(new QueryWrapper<PlatformJob>().lambda()
                    .eq(PlatformJob::getIsdeleted,Constants.ZERO)
                    .in(PlatformJob::getStatus,Constants.PlatformJobStatus.WAIT_CONFIRM,Constants.PlatformJobStatus.WART_SIGN_IN)
                    .in(PlatformJob::getId,jobIdList)
            );
            if(com.github.xiaoymin.knife4j.core.util.CollectionUtils.isNotEmpty(platformJobList)){
                platformJobMapper.update(null,new UpdateWrapper<PlatformJob>().lambda()
                        .set(PlatformJob::getStatus,Constants.PlatformJobStatus.DONE.getKey())
                        .set(PlatformJob::getDoneDate,new Date())
                        .in(PlatformJob::getStatus,Constants.PlatformJobStatus.WAIT_CONFIRM,Constants.PlatformJobStatus.WART_SIGN_IN)
                        .eq(PlatformJob::getIsdeleted,Constants.ZERO)
                        .in(PlatformJob::getId,platformJobList.stream().map(i->i.getId()).collect(Collectors.toList())));
            }
        }
    }
}