Commit 33efee85 by 墨竹

fix:企业刷新更新状态

parent a3509c97
...@@ -157,17 +157,20 @@ public class WxEnterpriseController extends WebBaseController { ...@@ -157,17 +157,20 @@ public class WxEnterpriseController extends WebBaseController {
return resultResponse(HaoBanErrCode.ERR_10012); return resultResponse(HaoBanErrCode.ERR_10012);
} }
QywxCorpInfoDTO dto = qywxTokenManageService.getCorpInfo(wxEnterpriseDTO.getCorpid(), config.getWxSuiteid()); QywxCorpInfoDTO dto = qywxTokenManageService.getCorpInfo(wxEnterpriseDTO.getCorpid(), config.getWxSuiteid());
Long verifiedEndTime = dto.getVerifiedEndTime();
if (dto == null) { if (dto == null) {
return resultResponse(HaoBanErrCode.ERR_10012); return resultResponse(HaoBanErrCode.ERR_10012);
} }
Long verifiedEndTime = dto.getVerifiedEndTime();
logger.info("【企业同步】dto={}", JSON.toJSONString(dto)); logger.info("【企业同步】dto={}", JSON.toJSONString(dto));
WxEnterpriseDTO wxDTO = EntityUtil.changeEntityByJSON(WxEnterpriseDTO.class, dto); WxEnterpriseDTO wxDTO = EntityUtil.changeEntityByJSON(WxEnterpriseDTO.class, dto);
if (verifiedEndTime != null) { if (verifiedEndTime != null) {
wxDTO.setVerifiedEndTime(new Date(verifiedEndTime * 1000)); wxDTO.setVerifiedEndTime(new Date(verifiedEndTime * 1000));
} }
wxDTO.setWxEnterpriseId(wxEnterpriseId); wxDTO.setWxEnterpriseId(wxEnterpriseId);
wxDTO.setContactFlag(1); Integer contactFlag = wxEnterpriseDTO.getContactFlag();
if (contactFlag == 0) {
wxDTO.setContactFlag(1);
}
wxEnterpriseApiService.update(wxDTO); wxEnterpriseApiService.update(wxDTO);
return resultResponse(HaoBanErrCode.ERR_1, wxEnterpriseDTO); return resultResponse(HaoBanErrCode.ERR_1, wxEnterpriseDTO);
} }
......
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