Commit 68820e56 by huangZW

Merge branch 'developer' of http://115.159.76.241/haoban3.0/haoban-manage3.0.git into developer

parents c2ee89bf cfba8a14
......@@ -14,4 +14,6 @@ public interface WxEnterpriseRelatedApiService {
boolean enterpriseUseNew(String enterpriseId);
EnterpriseDetailDTO getByEnterpriseId(String enterpriseId);
List<EnterpriseDetailDTO> queryAllHasGicEnterpriseId();
}
......@@ -21,4 +21,6 @@ public interface WxEnterpriseRelatedMapper {
TabHaobanWxEnterpriseRelated findOneByEnterpriseId(String enterpriseId);
List<TabHaobanWxEnterpriseRelated> queryAllHasGicEnterpriseId();
}
\ No newline at end of file
......@@ -69,9 +69,18 @@ public class MemberUnionidRelatedApiServiceImpl implements MemberUnionidRelatedA
break;
}
}
String unionIdJson = qywxUserApiService.getExternalUseridInfo(dto.getCorpid(), dto.getSuiteid(), dto.getExternalUserid());
String unionId = "";
if(StringUtils.isNotBlank(unionIdJson)){
JSONObject jo = JSON.parseObject(unionIdJson);
unionId = jo.getString("unionid");
}
if(member != null){
dto.setMemberId(member.getMemberId());
}
dto.setWxEnterpriseId(wxEnterprise.getWxEnterpriseId());
dto.setUnionid(unionId);
this.getExternalUserUnionid(dto);
return memberUnionRelatedService.addMemberUnionidRelated(dto);
}
......
......@@ -111,4 +111,18 @@ public class WxEnterpriseRelatedApiServiceImpl implements WxEnterpriseRelatedApi
return detail;
}
@Override
public List<EnterpriseDetailDTO> queryAllHasGicEnterpriseId() {
List<TabHaobanWxEnterpriseRelated> relatedList = wxEnterpriseRelatedMapper.queryAllHasGicEnterpriseId();
List<EnterpriseDetailDTO> result = EntityUtil.changeEntityListByJSON(EnterpriseDetailDTO.class, relatedList);
for (EnterpriseDetailDTO enterpriseDetailDTO : result) {
String enterpriseId = enterpriseDetailDTO.getEnterpriseId();
int gicAllCount = storeGroupService.gicDepartmentCount(enterpriseId);
int syncCount = departmentService.countSyncDepartmentByEnterpriseId(enterpriseId);
int nodeCount = gicAllCount - syncCount;
enterpriseDetailDTO.setNodeCount(nodeCount);
}
return result;
}
}
......@@ -129,4 +129,11 @@
where enterprise_id = #{enterpriseId,jdbcType=VARCHAR}
and status_flag = 1
</select>
<select id="queryAllHasGicEnterpriseId" resultMap="BaseResultMap" >
select
<include refid="Base_Column_List" />
from tab_haoban_wx_enterprise_related
where status_flag = 1
</select>
</mapper>
\ No newline at end of file
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