| | |
| | | public R pageByComEvent(ComEvent comEvent, Page pagination,LoginUserInfoVO loginUserInfoVO) { |
| | | if (nonNull(comEvent.getUserType())){ |
| | | if (comEvent.getUserType().equals(1)){ |
| | | //个人账号权限 |
| | | comEvent.setRequestUserId(loginUserInfoVO.getUserId()); |
| | | }else if (comEvent.getUserType().equals(2)){ |
| | | }else if (comEvent.getUserType().equals(2) || loginUserInfoVO.getType().equals(13)){ |
| | | //专家账号权限 |
| | | ComSanshuoExpert expert = comSanShuoExpertService.getOne(new QueryWrapper<ComSanshuoExpert>().lambda().eq(ComSanshuoExpert::getPhone, loginUserInfoVO.getPhone())); |
| | | if (nonNull(expert)){ |
| | | comEvent.setSpecialistId(expert.getId()); |
| | | } |
| | | }else if (loginUserInfoVO.getType().equals(11)){ |
| | | //行业分中心权限 |
| | | comEvent.setUserType(3); |
| | | //获取行业分中心id |
| | | ComSanshuoIndustryCenter center = comSanShuoIndustryCenterService.getOne(new QueryWrapper<ComSanshuoIndustryCenter>().lambda().eq(ComSanshuoIndustryCenter::getAccount, loginUserInfoVO.getAccount())); |
| | | if (nonNull(center)){ |
| | | comEvent.setCenterId(center.getId().toString()); |
| | | } |
| | | }else if (loginUserInfoVO.getType().equals(3)){ |
| | | //社区后台权限 |
| | | comEvent.setCommunityId(loginUserInfoVO.getCommunityId()); |
| | | } |
| | | } |
| | | IPage<ComEvent> list = baseMapper.pageByComEvent(comEvent, pagination); |