Commit 7c5236a6 authored by 吴泽佳's avatar 吴泽佳

bug 修复

parent 56b4b430
...@@ -377,7 +377,7 @@ public class OrgSyncByWxcpJob { ...@@ -377,7 +377,7 @@ public class OrgSyncByWxcpJob {
//更新 //更新
String status = wxCpUser.getStatus() == 1 ? "on" : "off"; String status = wxCpUser.getStatus() == 1 ? "on" : "off";
if (!employee.getName().equals(wxCpUser.getName()) || !employee.getMail().equals(wxCpUser.getEmail()) || if (!employee.getName().equals(wxCpUser.getName()) || !employee.getMail().equals(wxCpUser.getEmail()) ||
StrUtil.isBlankIfStr(employee.getBoundWechat()) || !employee.getStatus().equals(status)) { StrUtil.isBlank(employee.getBoundWechat()) || !employee.getStatus().equals(status)) {
employee.setName(wxCpUser.getName()); employee.setName(wxCpUser.getName());
employee.setMail(wxCpUser.getEmail()); employee.setMail(wxCpUser.getEmail());
if (StrUtil.isBlankIfStr(employee.getBoundWechat())) { if (StrUtil.isBlankIfStr(employee.getBoundWechat())) {
...@@ -398,6 +398,7 @@ public class OrgSyncByWxcpJob { ...@@ -398,6 +398,7 @@ public class OrgSyncByWxcpJob {
employee.setMail(wxCpUser.getEmail()); employee.setMail(wxCpUser.getEmail());
employee.setNumber(null); employee.setNumber(null);
employee.setOrgId(orgId); employee.setOrgId(orgId);
employee.setBoundWechat(orgId + "_" + wxCpUser.getUserId());
employee.setStatus(wxCpUser.getStatus() == 1 ? "on" : "off"); employee.setStatus(wxCpUser.getStatus() == 1 ? "on" : "off");
insertList.add(employee); insertList.add(employee);
} }
......
...@@ -50,7 +50,7 @@ public class OrgSyncByWxcpService { ...@@ -50,7 +50,7 @@ public class OrgSyncByWxcpService {
userInfoMapper.updateById(userInfo); userInfoMapper.updateById(userInfo);
} }
List<UserInfo> workUserInfoDeleteList = workUserInfo.getDeleteList(); List<UserInfo> workUserInfoDeleteList = workUserInfo.getDeleteList();
for (UserInfo userInfo : workUserInfoUpdateList) { for (UserInfo userInfo : workUserInfoDeleteList) {
userInfo.setUpdateby("SYS"); userInfo.setUpdateby("SYS");
userInfo.setUpdatetime(now); userInfo.setUpdatetime(now);
userInfo.setDeletetag("1"); userInfo.setDeletetag("1");
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment