|
@@ -17,11 +17,7 @@ import org.springframework.transaction.annotation.Transactional;
|
|
|
public class SyncSapUserToWxService extends BaseService {
|
|
|
|
|
|
@Autowired
|
|
|
- private WxUserService wxUserService;
|
|
|
- @Autowired
|
|
|
private SapUserService sapUserService;
|
|
|
- @Autowired
|
|
|
- private WxDepartService wxDepartService;
|
|
|
|
|
|
@Transactional
|
|
|
public SyncWeixinUserOutput syncWeixinUser() throws Exception {
|
|
@@ -44,13 +40,8 @@ public class SyncSapUserToWxService extends BaseService {
|
|
|
return SyncWeixinUserOutput.builder().state("正在同步,请稍等").build();
|
|
|
}
|
|
|
|
|
|
- @Transactional
|
|
|
public void taskBiz() throws Exception {
|
|
|
WebConstants.CACHE.put(WebConstants.CACHE_SYNC_SAP, DateUtil.getTime());
|
|
|
- // 更新微信部门
|
|
|
- wxDepartService.saveWxDeparts();
|
|
|
- // 更新微信用户
|
|
|
- wxUserService.saveWxUsers();
|
|
|
// 更新所有数据无效
|
|
|
sapUserService.updateAllDelFlag(DelFlagEnum.UNABLE.getCode());
|
|
|
// 保存SAP用户数据-数据没变化的result状态保持不变
|