Commit 8526c083 by jinxin

员工可能修改userId,需要拿到openUserId再去查询一次

parent 0d5ec2d7
......@@ -227,13 +227,16 @@ public class MessageApiServiceImpl implements MessageApiService {
if (oldStaff == null) {
//员工可能修改userId,需要拿到openUserId再去查询一次
WxEnterpriseQwDTO qwDTO = this.wxEnterpriseService.getQwInfo(wxEnterpriseId);
if (qwDTO != null){
if (qwDTO != null && (qwDTO.getWxSecurityType() == 1 || qwDTO.getWxSecurityType() == 3)){
String openUserid = getOpenUserid(userid, qwDTO);
oldStaff = this.staffService.selectByUserIdAndEnterpriseId(openUserid, wxEnterpriseId);
if (oldStaff == null){
log.error("成员同步更新失败,无历史员工数据:userid:{},wxEnterpriseId:{}", userid, wxEnterpriseId);
return;
}
}else {
log.error("成员同步更新失败,无历史员工数据:userid:{},wxEnterpriseId:{}", userid, wxEnterpriseId);
return;
}
}
TabHaobanStaff staff = new TabHaobanStaff();
......
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