|
@@ -17,6 +17,7 @@ import com.ydtech.modules.admin.model.SysUserRole;
|
|
|
import com.ydtech.modules.admin.model.SysUserRoleKzt;
|
|
import com.ydtech.modules.admin.model.SysUserRoleKzt;
|
|
|
import com.ydtech.modules.admin.model.dto.*;
|
|
import com.ydtech.modules.admin.model.dto.*;
|
|
|
import com.ydtech.modules.admin.model.report.user.*;
|
|
import com.ydtech.modules.admin.model.report.user.*;
|
|
|
|
|
+import com.ydtech.modules.admin.model.vo.AppCustomerManagementQueryVo;
|
|
|
import com.ydtech.modules.admin.model.vo.HouLinePersonnelReportVo;
|
|
import com.ydtech.modules.admin.model.vo.HouLinePersonnelReportVo;
|
|
|
import com.ydtech.modules.admin.model.vo.QxFrontlineAgentVo;
|
|
import com.ydtech.modules.admin.model.vo.QxFrontlineAgentVo;
|
|
|
import com.ydtech.modules.admin.model.vo.SysUserBaseVO;
|
|
import com.ydtech.modules.admin.model.vo.SysUserBaseVO;
|
|
@@ -267,6 +268,7 @@ public class UserReportServiceImpl implements UserReportService {
|
|
|
}
|
|
}
|
|
|
userIds.add(userId);
|
|
userIds.add(userId);
|
|
|
userItem.setIds(userIds);
|
|
userItem.setIds(userIds);
|
|
|
|
|
+ userItem.setTotalManpower(userIds.size()+"");
|
|
|
//出单人力
|
|
//出单人力
|
|
|
QxFrontlineAgentDto qxFrontlineAgentDto = new QxFrontlineAgentDto();
|
|
QxFrontlineAgentDto qxFrontlineAgentDto = new QxFrontlineAgentDto();
|
|
|
qxFrontlineAgentDto.setIds(userIds);
|
|
qxFrontlineAgentDto.setIds(userIds);
|
|
@@ -529,125 +531,52 @@ public class UserReportServiceImpl implements UserReportService {
|
|
|
public HttpResult<EsmUserCountVO> queryQxFrontlineDetails(QxFrontlineAgentVo qxFrontlineAgentVo) {
|
|
public HttpResult<EsmUserCountVO> queryQxFrontlineDetails(QxFrontlineAgentVo qxFrontlineAgentVo) {
|
|
|
try {
|
|
try {
|
|
|
EsmUserCountVO esmUserCountVO = new EsmUserCountVO();
|
|
EsmUserCountVO esmUserCountVO = new EsmUserCountVO();
|
|
|
- List<EsmTeamPolicyVO> hzList = new ArrayList<>();
|
|
|
|
|
- List<EsmUserPolicyVO> userPolicyList = new ArrayList<>();
|
|
|
|
|
- List<EsmUserPolicyVO> userPolicyList0 = new ArrayList<>();
|
|
|
|
|
- List<EsmUserPolicyVO> userPolicyList1 = new ArrayList<>();
|
|
|
|
|
- List<EsmUserPolicyVO> userPolicyList2 = new ArrayList<>();
|
|
|
|
|
- List<EsmUserPolicyVO> userPolicyList3 = new ArrayList<>();
|
|
|
|
|
- EsmUserReferrer esmUserReferrer = esmUserReferrerMapper.selectById(qxFrontlineAgentVo.getUserId());
|
|
|
|
|
- if (esmUserReferrer != null) {
|
|
|
|
|
- List<String> userList1 = new ArrayList<>();
|
|
|
|
|
- List<String> userList2 = new ArrayList<>();
|
|
|
|
|
- List<String> userList3 = new ArrayList<>();
|
|
|
|
|
- //本级信息
|
|
|
|
|
- //明细数据加工
|
|
|
|
|
- List<String> userList0 = new ArrayList<>();
|
|
|
|
|
- userList0.add(esmUserReferrer.getId());
|
|
|
|
|
- userPolicyList0 = esmUserReferrerMapper.queryOrderCount(userList0, null, null);
|
|
|
|
|
- //汇总数据加工
|
|
|
|
|
- EsmTeamPolicyVO esmTeamPolicyVO0 = esmUserReferrerMapper.queryOrderCountHzNew(userList0, null, null);
|
|
|
|
|
- EsmTeamPolicyVO esmTeamPolicyVO1 = new EsmTeamPolicyVO();
|
|
|
|
|
- EsmTeamPolicyVO esmTeamPolicyVO2 = new EsmTeamPolicyVO();
|
|
|
|
|
- EsmTeamPolicyVO esmTeamPolicyVO3 = new EsmTeamPolicyVO();
|
|
|
|
|
- esmTeamPolicyVO2.setTeamlevel("二级团队");
|
|
|
|
|
- esmTeamPolicyVO3.setTeamlevel("三级团队");
|
|
|
|
|
- if (esmTeamPolicyVO0 == null) {
|
|
|
|
|
- esmTeamPolicyVO0 = new EsmTeamPolicyVO();
|
|
|
|
|
- esmTeamPolicyVO0.setSumpremium(0);
|
|
|
|
|
- esmTeamPolicyVO0.setUsernum(0);
|
|
|
|
|
- } else {
|
|
|
|
|
- esmTeamPolicyVO0.setUsernum(1);
|
|
|
|
|
- }
|
|
|
|
|
- esmTeamPolicyVO0.setTeamlevel("本人");
|
|
|
|
|
- esmTeamPolicyVO0.setTeamnum(1);
|
|
|
|
|
-
|
|
|
|
|
- // 一级团队信息
|
|
|
|
|
- userList1 = esmUserReferrerMapper.getIdDown_1(esmUserReferrer.getId());
|
|
|
|
|
- esmTeamPolicyVO1.setTeamlevel("一级团队");
|
|
|
|
|
- if (userList1 != null && userList1.size() > 0) {
|
|
|
|
|
- userPolicyList1 = esmUserReferrerMapper.queryOrderCount(userList1, null, null);
|
|
|
|
|
- EsmTeamPolicyVO esmTeamPolicyVO1_t = esmUserReferrerMapper.queryOrderCountHzNew(userList1, null,
|
|
|
|
|
- null);
|
|
|
|
|
- if (esmTeamPolicyVO1_t != null) {
|
|
|
|
|
- esmTeamPolicyVO1.setSumpremium(esmTeamPolicyVO1_t.getSumpremium());
|
|
|
|
|
- esmTeamPolicyVO1.setUsernum(userPolicyList1.size());//出单人力
|
|
|
|
|
- }
|
|
|
|
|
- esmTeamPolicyVO1.setTeamnum(userList1.size());//团队人数
|
|
|
|
|
- // 二级团队信息
|
|
|
|
|
- userList2 = esmUserReferrerMapper.getIdDown_2(esmUserReferrer.getId());
|
|
|
|
|
-
|
|
|
|
|
- esmTeamPolicyVO2.setTeamlevel("二级团队");
|
|
|
|
|
- if (userList2 != null && userList2.size() > 0) {
|
|
|
|
|
- userPolicyList2 = esmUserReferrerMapper.queryOrderCount(userList2, null, null);
|
|
|
|
|
- EsmTeamPolicyVO esmTeamPolicyVO2_t = esmUserReferrerMapper.queryOrderCountHzNew(userList2, null,
|
|
|
|
|
- null);
|
|
|
|
|
- if (esmTeamPolicyVO2_t != null) {
|
|
|
|
|
- esmTeamPolicyVO2.setSumpremium(esmTeamPolicyVO2_t.getSumpremium());
|
|
|
|
|
- esmTeamPolicyVO2.setUsernum(userPolicyList2.size());
|
|
|
|
|
- }
|
|
|
|
|
- esmTeamPolicyVO2.setTeamnum(userList2.size());
|
|
|
|
|
- // 三级团队信息
|
|
|
|
|
- userList3 = esmUserReferrerMapper.getIdDown_3(esmUserReferrer.getId());
|
|
|
|
|
- if(userList3!=null && userList3.size()>0){
|
|
|
|
|
- userPolicyList3=esmUserReferrerMapper.queryOrderCount(userList3,null, null);
|
|
|
|
|
- EsmTeamPolicyVO esmTeamPolicyVO3_t=esmUserReferrerMapper.queryOrderCountHzNew(userList3,null, null);
|
|
|
|
|
- esmTeamPolicyVO3.setTeamlevel("三级团队");
|
|
|
|
|
- esmTeamPolicyVO3.setTeamnum(userList3.size());
|
|
|
|
|
- if (esmTeamPolicyVO2_t != null) {
|
|
|
|
|
- esmTeamPolicyVO3.setSumpremium(esmTeamPolicyVO3_t.getSumpremium());
|
|
|
|
|
- esmTeamPolicyVO3.setUsernum(userPolicyList3.size());
|
|
|
|
|
- }
|
|
|
|
|
|
|
+ List<EsmTeamPolicyVO> list =new ArrayList<>();
|
|
|
|
|
+ qxFrontlineAgentVo.setType("0");
|
|
|
|
|
+ EsmTeamPolicyVO vo_0 = getVo(getStrings(qxFrontlineAgentVo), "汇总");
|
|
|
|
|
+ list.add(vo_0);
|
|
|
|
|
|
|
|
- }
|
|
|
|
|
- }
|
|
|
|
|
|
|
+ qxFrontlineAgentVo.setType("1");
|
|
|
|
|
+ EsmTeamPolicyVO vo_1 = getVo(getStrings(qxFrontlineAgentVo), "本人");
|
|
|
|
|
+ list.add(vo_1);
|
|
|
|
|
|
|
|
- }
|
|
|
|
|
|
|
+ qxFrontlineAgentVo.setType("2");
|
|
|
|
|
+ EsmTeamPolicyVO vo_2 = getVo(getStrings(qxFrontlineAgentVo), "一级团队");
|
|
|
|
|
+ list.add(vo_2);
|
|
|
|
|
|
|
|
- //临时团队
|
|
|
|
|
- List<String> registList = esmUserReferrerMapper.getIdDown3_regist(qxFrontlineAgentVo.getUserId());
|
|
|
|
|
- EsmTeamPolicyVO esmTeamPolicyVO9 = new EsmTeamPolicyVO();
|
|
|
|
|
- esmTeamPolicyVO9.setTeamlevel("临时团队");
|
|
|
|
|
- esmTeamPolicyVO9.setTeamnum(registList == null ? 0 : registList.size());
|
|
|
|
|
-
|
|
|
|
|
- //汇总
|
|
|
|
|
- List<String> userList = new ArrayList<>();
|
|
|
|
|
- userList.addAll(userList0);
|
|
|
|
|
- userList.addAll(userList1);
|
|
|
|
|
- userList.addAll(userList2);
|
|
|
|
|
- userList.addAll(userList3);
|
|
|
|
|
- userList.addAll(registList);
|
|
|
|
|
- userPolicyList = esmUserReferrerMapper.queryOrderCount(userList, null, null);
|
|
|
|
|
- EsmTeamPolicyVO esmTeamPolicyVO = new EsmTeamPolicyVO();
|
|
|
|
|
- EsmTeamPolicyVO esmTeamPolicyVO_t = esmUserReferrerMapper.queryOrderCountHzNew(userList, null, null);
|
|
|
|
|
- if (esmTeamPolicyVO_t != null) {
|
|
|
|
|
- esmTeamPolicyVO.setSumpremium(esmTeamPolicyVO_t.getSumpremium());
|
|
|
|
|
- esmTeamPolicyVO.setUsernum(userPolicyList.size());
|
|
|
|
|
- }
|
|
|
|
|
- esmTeamPolicyVO.setTeamlevel("汇总");
|
|
|
|
|
- esmTeamPolicyVO.setTeamnum(userList.size());
|
|
|
|
|
- hzList.add(esmTeamPolicyVO);
|
|
|
|
|
- hzList.add(esmTeamPolicyVO0);
|
|
|
|
|
- hzList.add(esmTeamPolicyVO1);
|
|
|
|
|
- hzList.add(esmTeamPolicyVO2);
|
|
|
|
|
- hzList.add(esmTeamPolicyVO3);
|
|
|
|
|
- hzList.add(esmTeamPolicyVO9);
|
|
|
|
|
- esmUserCountVO.setHzList(hzList);
|
|
|
|
|
- esmUserCountVO.setUserPolicyList(userPolicyList);
|
|
|
|
|
- esmUserCountVO.setUserPolicyList0(userPolicyList0);
|
|
|
|
|
- esmUserCountVO.setUserPolicyList1(userPolicyList1);
|
|
|
|
|
- esmUserCountVO.setUserPolicyList2(userPolicyList2);
|
|
|
|
|
- esmUserCountVO.setUserPolicyList3(userPolicyList3);
|
|
|
|
|
- } else {
|
|
|
|
|
- throw new SystemException("内部错误");
|
|
|
|
|
- }
|
|
|
|
|
|
|
+ qxFrontlineAgentVo.setType("3");
|
|
|
|
|
+ EsmTeamPolicyVO vo_3 = getVo(getStrings(qxFrontlineAgentVo), "二级团队");
|
|
|
|
|
+ list.add(vo_3);
|
|
|
|
|
+
|
|
|
|
|
+ qxFrontlineAgentVo.setType("4");
|
|
|
|
|
+ EsmTeamPolicyVO vo_4 = getVo(getStrings(qxFrontlineAgentVo), "三级团队");
|
|
|
|
|
+ list.add(vo_4);
|
|
|
|
|
+
|
|
|
|
|
+ qxFrontlineAgentVo.setType("5");
|
|
|
|
|
+ EsmTeamPolicyVO vo_5 = getVo(getStrings(qxFrontlineAgentVo), "临时团队");
|
|
|
|
|
+ list.add(vo_5);
|
|
|
|
|
+
|
|
|
|
|
+ esmUserCountVO.setHzList(list);
|
|
|
return HttpResult.ok(esmUserCountVO);
|
|
return HttpResult.ok(esmUserCountVO);
|
|
|
} catch (Exception e) {
|
|
} catch (Exception e) {
|
|
|
e.printStackTrace();
|
|
e.printStackTrace();
|
|
|
return HttpResult.error("查询异常");
|
|
return HttpResult.error("查询异常");
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
-
|
|
|
|
|
|
|
+ public EsmTeamPolicyVO getVo(List<String> userIds,String levelName){
|
|
|
|
|
+ EsmTeamPolicyVO vo =new EsmTeamPolicyVO();
|
|
|
|
|
+ vo.setTeamlevel(levelName);
|
|
|
|
|
+ vo.setTeamnum(userIds.size());
|
|
|
|
|
+ if(userIds!=null && userIds.size()>0){
|
|
|
|
|
+ TaskStatisticsDto taskStatisticsDto = insAreaCompanyMapper.numberQuotationsByUserIds(userIds,null);
|
|
|
|
|
+ vo.setSumpremium(Double.valueOf(taskStatisticsDto.getTotalPremium()));
|
|
|
|
|
+ vo.setUsernum(Integer.valueOf(taskStatisticsDto.getUnderwritingCount().toString()));
|
|
|
|
|
+ }else{
|
|
|
|
|
+ vo.setSumpremium(0);
|
|
|
|
|
+ vo.setUsernum(0);
|
|
|
|
|
+ }
|
|
|
|
|
+ return vo;
|
|
|
|
|
+ }
|
|
|
|
|
|
|
|
private void qxFrontlineDetails(TeamManagementDto thisLevelDto, EsmUserReferrerDTO item, Map<String, EsmUserReferrerDTO> collect, Set<String> visited, List<String> ids,List<TeamManagementDto> teamManagementDtoList) {
|
|
private void qxFrontlineDetails(TeamManagementDto thisLevelDto, EsmUserReferrerDTO item, Map<String, EsmUserReferrerDTO> collect, Set<String> visited, List<String> ids,List<TeamManagementDto> teamManagementDtoList) {
|
|
|
visited.clear();
|
|
visited.clear();
|
|
@@ -670,44 +599,102 @@ public class UserReportServiceImpl implements UserReportService {
|
|
|
@Override
|
|
@Override
|
|
|
public HttpResult<IPage<QxFrontlineAgentDto>> queryQxFrontlineDetailsUser(QxFrontlineAgentVo qxFrontlineAgentVo) {
|
|
public HttpResult<IPage<QxFrontlineAgentDto>> queryQxFrontlineDetailsUser(QxFrontlineAgentVo qxFrontlineAgentVo) {
|
|
|
try {
|
|
try {
|
|
|
-
|
|
|
|
|
- PageVo<SettlementDocumentaryFeesSumEntity> pageVo = new PageVo<>();
|
|
|
|
|
- Page page = new Page(qxFrontlineAgentVo.getPageNum(), qxFrontlineAgentVo.getPageSize());
|
|
|
|
|
|
|
+ PageVo<QxFrontlineAgentDto> pageVo = new PageVo<>();
|
|
|
|
|
+ Page<QxFrontlineAgentDto> page = new Page(qxFrontlineAgentVo.getPageNum(), qxFrontlineAgentVo.getPageSize());
|
|
|
pageVo.setPageNum(qxFrontlineAgentVo.getPageNum());
|
|
pageVo.setPageNum(qxFrontlineAgentVo.getPageNum());
|
|
|
pageVo.setPageSize(qxFrontlineAgentVo.getPageSize());
|
|
pageVo.setPageSize(qxFrontlineAgentVo.getPageSize());
|
|
|
- HashMap<String, List<String>> humanResourcesIdList = new HashMap<>();
|
|
|
|
|
- IPage<QxFrontlineAgentDto> userResultPage = new Page<>();
|
|
|
|
|
- //关系表
|
|
|
|
|
- List<EsmUserReferrerDTO> employeeIncreaseReportDtos = esmUserReferrerMapper.getbyUserNextLevel(null);
|
|
|
|
|
- Map<String, EsmUserReferrerDTO> collect = employeeIncreaseReportDtos.stream().collect(Collectors.toMap(EsmUserReferrerDTO::getId, Function.identity()));
|
|
|
|
|
- Set<String> visited = new HashSet<>();
|
|
|
|
|
- List<String> strings = new ArrayList<>();
|
|
|
|
|
- for (EsmUserReferrerDTO item : employeeIncreaseReportDtos) {
|
|
|
|
|
- List<String> ids = new ArrayList<>();
|
|
|
|
|
- humanResourcesIdList.put(item.getId(), this.nextLevelUserList(item.getId(), collect, visited, ids));
|
|
|
|
|
- }
|
|
|
|
|
- if (humanResourcesIdList.containsKey(qxFrontlineAgentVo.getUserId())) {
|
|
|
|
|
- strings = humanResourcesIdList.get(qxFrontlineAgentVo.getUserId());
|
|
|
|
|
- }
|
|
|
|
|
- if(!CollectionUtils.isEmpty(strings)){
|
|
|
|
|
- qxFrontlineAgentVo.setIds(strings);
|
|
|
|
|
- userResultPage = sysUserMapper.getByIdsList(page, qxFrontlineAgentVo);
|
|
|
|
|
- List<QxFrontlineAgentDto> records = userResultPage.getRecords();
|
|
|
|
|
- for (QxFrontlineAgentDto userItem : records) {
|
|
|
|
|
- TaskStatisticsDto taskStatisticsDto = insAreaCompanyMapper.NumberQuotations(userItem.getUserId());
|
|
|
|
|
- userItem.setUnderwritingCount(taskStatisticsDto.getUnderwritingCount().toString());
|
|
|
|
|
- userItem.setOrderNumber(taskStatisticsDto.getOrderNumber());
|
|
|
|
|
- userItem.setQutationInsureCount(taskStatisticsDto.getQutationInsureCount());
|
|
|
|
|
- userItem.setTotalPremium(taskStatisticsDto.getTotalPremium());
|
|
|
|
|
|
|
+ //通过查询条件查询代理人数据
|
|
|
|
|
+ List<String> userIds = getStrings(qxFrontlineAgentVo);
|
|
|
|
|
+ qxFrontlineAgentVo.setIds(userIds);
|
|
|
|
|
+ //查詢所有的人员数据
|
|
|
|
|
+ Page<QxFrontlineAgentDto> pages =new Page<QxFrontlineAgentDto>();
|
|
|
|
|
+ if(userIds!=null && userIds.size()>0){
|
|
|
|
|
+ pages = sysUserMapper.findUserListByParam(page,qxFrontlineAgentVo);
|
|
|
|
|
+ List<QxFrontlineAgentDto> newList = new ArrayList<QxFrontlineAgentDto>();
|
|
|
|
|
+ List<QxFrontlineAgentDto> records = pages.getRecords();
|
|
|
|
|
+ if(records!=null && records.size()>0){
|
|
|
|
|
+ for(QxFrontlineAgentDto dto : records){
|
|
|
|
|
+ int rzCount=0;
|
|
|
|
|
+ int wrzCount=0;
|
|
|
|
|
+ List<SysUserTeamDto> users = esmUserReferrerMapper.getUserIdsByUserId(dto.getUserId());
|
|
|
|
|
+ for(SysUserTeamDto vo :users){
|
|
|
|
|
+ if("1".equals(vo.getStatus())){
|
|
|
|
|
+ rzCount++;
|
|
|
|
|
+ }else if("2".equals(vo.getStatus())){
|
|
|
|
|
+ wrzCount++;
|
|
|
|
|
+ }
|
|
|
|
|
+ }
|
|
|
|
|
+ if("1".equals(dto.getStatus())){
|
|
|
|
|
+ rzCount++;
|
|
|
|
|
+ }else if("2".equals(dto.getStatus())){
|
|
|
|
|
+ wrzCount++;
|
|
|
|
|
+ }
|
|
|
|
|
+ if(users!=null && users.size()>0){
|
|
|
|
|
+ userIds = users.stream().map(SysUserTeamDto::getId).collect(Collectors.toList());
|
|
|
|
|
+ }
|
|
|
|
|
+ userIds.add(dto.getUserId());
|
|
|
|
|
+ dto.setIsFactorVerify(rzCount+"");
|
|
|
|
|
+ dto.setIsNotFactorVerify(wrzCount+"");
|
|
|
|
|
+ dto.setTotalManpower(userIds.size()+"");
|
|
|
|
|
+ userIds.add(dto.getUserId());
|
|
|
|
|
+ TaskStatisticsDto taskStatisticsDto = insAreaCompanyMapper.numberQuotationsByUserIds(userIds,qxFrontlineAgentVo.getMonth());
|
|
|
|
|
+ dto.setOrderNumber(taskStatisticsDto.getOrderNumber());
|
|
|
|
|
+ dto.setUnderwritingCount(taskStatisticsDto.getUnderwritingCount().toString());
|
|
|
|
|
+ dto.setQutationInsureCount(taskStatisticsDto.getQutationInsureCount());
|
|
|
|
|
+ dto.setTotalPremium(taskStatisticsDto.getTotalPremium());
|
|
|
|
|
+ newList.add(dto);
|
|
|
|
|
+ }
|
|
|
}
|
|
}
|
|
|
|
|
+ pages.setRecords(newList);
|
|
|
}
|
|
}
|
|
|
- return HttpResult.ok(userResultPage);
|
|
|
|
|
|
|
+
|
|
|
|
|
+ return HttpResult.ok(pages);
|
|
|
} catch (Exception e) {
|
|
} catch (Exception e) {
|
|
|
e.printStackTrace();
|
|
e.printStackTrace();
|
|
|
return HttpResult.error("查询异常");
|
|
return HttpResult.error("查询异常");
|
|
|
}
|
|
}
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
|
|
+ private List<String> getStrings(QxFrontlineAgentVo qxFrontlineAgentVo) {
|
|
|
|
|
+ String type = qxFrontlineAgentVo.getType();
|
|
|
|
|
+ String status ="";
|
|
|
|
|
+ String level ="";
|
|
|
|
|
+ if("0".equals(type)){
|
|
|
|
|
+ //汇总 查询所有的代理人数据
|
|
|
|
|
+ status =null;
|
|
|
|
|
+ level =null;
|
|
|
|
|
+ }else if("1".equals(type)){
|
|
|
|
|
+ status ="1";
|
|
|
|
|
+ level ="0";
|
|
|
|
|
+ }
|
|
|
|
|
+ else if("2".equals(type)){
|
|
|
|
|
+ status ="1";
|
|
|
|
|
+ level ="1";
|
|
|
|
|
+ }
|
|
|
|
|
+ else if("3".equals(type)){
|
|
|
|
|
+ status ="1";
|
|
|
|
|
+ level ="2";
|
|
|
|
|
+ }
|
|
|
|
|
+ else if("4".equals(type)){
|
|
|
|
|
+ status ="1";
|
|
|
|
|
+ level ="3";
|
|
|
|
|
+ }
|
|
|
|
|
+ else if("5".equals(type)){
|
|
|
|
|
+ status ="2";
|
|
|
|
|
+ level =null;
|
|
|
|
|
+ }
|
|
|
|
|
+ List<String> userIds=new ArrayList<String>();
|
|
|
|
|
+ List<SysUserTeamDto> userList = esmUserReferrerMapper.getByTeamByLevel(qxFrontlineAgentVo.getUserId(), level, status);
|
|
|
|
|
+ if(userList!=null && userList.size()>0) {
|
|
|
|
|
+ userIds = userList.stream().map(SysUserTeamDto::getId).collect(Collectors.toList());
|
|
|
|
|
+ }
|
|
|
|
|
+ if ("0".equals(type)) {
|
|
|
|
|
+ userIds.add(qxFrontlineAgentVo.getUserId());
|
|
|
|
|
+ } else if ("1".equals(type)) {
|
|
|
|
|
+ userIds.add(qxFrontlineAgentVo.getUserId());
|
|
|
|
|
+ }
|
|
|
|
|
+ return userIds;
|
|
|
|
|
+ }
|
|
|
@Override
|
|
@Override
|
|
|
public QxFrontlineAgentDto getByUserId(String userId) {
|
|
public QxFrontlineAgentDto getByUserId(String userId) {
|
|
|
SysUserBaseVO sysUserBaseVO = sysUserMapper.selectUserById(userId);
|
|
SysUserBaseVO sysUserBaseVO = sysUserMapper.selectUserById(userId);
|