Commit abbf3a89 by jinxin

通讯录列表导出接口优化

parent d0067066
......@@ -152,7 +152,14 @@ public class StaffApiServiceImpl implements StaffApiService {
List<String> staffIds = new ArrayList<>();
//查询所属品牌成员id
if(StrUtil.isNotBlank(enterpriseIdParam)){
staffIds = staffClerkRelationService.listAllStaffIdByEnterpriseId(enterpriseIdParam, wxEnterpriseId);
//-1表示查询成员所属商户是无归属的
if ("-1".equals(enterpriseIdParam)){
staffIds = staffClerkRelationService.listByWxEnterpriseId(wxEnterpriseId);
relationFlag = 0;
}else {
staffIds = staffClerkRelationService.listAllStaffIdByEnterpriseId(enterpriseIdParam, wxEnterpriseId);
relationFlag = 1;
}
}else {
if (relationFlag != null) {
staffIds = staffClerkRelationService.listByWxEnterpriseId(wxEnterpriseId);
......@@ -163,6 +170,7 @@ public class StaffApiServiceImpl implements StaffApiService {
}
StaffListBO staffListBO = EntityUtil.changeEntityByJSON(StaffListBO.class, staffListDTO);
staffListBO.setStaffIds(staffIds);
staffListBO.setRelationFlag(relationFlag);
PageHelper.startPage(pageInfo.getPageNum(), pageInfo.getPageSize());
Page<StaffDTO> page = PageUtil.changePageHelperToCurrentPage(staffService.pageStaff(staffListBO), StaffDTO.class);
List<StaffDTO> staffDTOList = page.getResult();
......
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