forked from luyan/epmet-cloud-lingshan
1 changed files with 42 additions and 0 deletions
@ -0,0 +1,42 @@ |
|||
package com.epmet.task; |
|||
|
|||
|
|||
import com.alibaba.fastjson.JSON; |
|||
import com.epmet.commons.tools.utils.Result; |
|||
import com.epmet.dto.form.NatInfoScanTaskFormDTO; |
|||
import com.epmet.feign.EpmetThirdOpenFeignClient; |
|||
import com.epmet.feign.EpmetUserOpenFeignClient; |
|||
import com.epmet.feign.ThirdOpenFeignClient; |
|||
import lombok.extern.slf4j.Slf4j; |
|||
import org.apache.commons.lang3.StringUtils; |
|||
import org.springframework.beans.factory.annotation.Autowired; |
|||
import org.springframework.stereotype.Component; |
|||
|
|||
/** |
|||
* @author zxc |
|||
* @dscription 拉取yt用户信息和组织信息 |
|||
*/ |
|||
@Slf4j |
|||
@Component("YTUserAndOrgPullTask") |
|||
public class YTUserAndOrgPullTask implements ITask { |
|||
|
|||
@Autowired |
|||
private ThirdOpenFeignClient thirdOpenFeignClient; |
|||
|
|||
@Override |
|||
public void run(String params) { |
|||
Result<Boolean> yanTaiOrgInfo = thirdOpenFeignClient.getYanTaiOrgInfo(""); |
|||
if (yanTaiOrgInfo.success()) { |
|||
log.info("yt拉取组织信息定时任务执行成功"); |
|||
} else { |
|||
log.error("yt拉取组织信息定时任务执行失败:" + yanTaiOrgInfo.getMsg()); |
|||
} |
|||
|
|||
Result<Boolean> yanTaiUserInfo = thirdOpenFeignClient.getYanTaiUserInfo(""); |
|||
if (yanTaiUserInfo.success()) { |
|||
log.info("yt拉取用户信息定时任务执行成功"); |
|||
} else { |
|||
log.error("yt拉取用户信息定时任务执行失败:" + yanTaiUserInfo.getMsg()); |
|||
} |
|||
} |
|||
} |
Loading…
Reference in new issue