| | |
| | | import com.baomidou.mybatisplus.extension.plugins.pagination.Page; |
| | | import com.google.common.base.Joiner; |
| | | import com.ltkj.common.core.domain.TreeSelect; |
| | | import com.ltkj.common.core.domain.entity.SysRole; |
| | | import com.ltkj.common.core.domain.entity.SysUser; |
| | | import com.ltkj.common.core.redis.RedisCache; |
| | | import com.ltkj.common.core.text.Convert; |
| | | import com.ltkj.common.utils.SecurityUtils; |
| | | import com.ltkj.common.utils.bean.BeanUtils; |
| | | import com.ltkj.framework.config.MatchUtils; |
| | |
| | | import com.ltkj.hosp.service.*; |
| | | import com.ltkj.system.domain.SysPost; |
| | | import com.ltkj.system.domain.SysUserPost; |
| | | import com.ltkj.system.service.ISysPostService; |
| | | import com.ltkj.system.service.ISysUserPostService; |
| | | import com.ltkj.system.service.ISysUserService; |
| | | import com.ltkj.system.service.*; |
| | | import io.swagger.annotations.Api; |
| | | import io.swagger.annotations.ApiOperation; |
| | | import io.swagger.annotations.ApiParam; |
| | |
| | | import com.ltkj.common.core.domain.entity.SysDept; |
| | | import com.ltkj.common.enums.BusinessType; |
| | | import com.ltkj.common.utils.StringUtils; |
| | | import com.ltkj.system.service.ISysDeptService; |
| | | |
| | | import javax.annotation.Resource; |
| | | |
| | |
| | | public RedisTemplate<Object,Object> redisTemplate; |
| | | @Resource |
| | | private TestMapper testMapper; |
| | | |
| | | @Autowired |
| | | private ISysConfigService configService; |
| | | |
| | | /** |
| | | * 该体检科室下客户列表显示接口 |
| | |
| | | if (null != summaryList && summaryList.size()>0 && !summaryList.contains(null)) { |
| | | one.setSummary(Joiner.on(";").join(orderRemark.getSummaryList())); |
| | | } |
| | | one.setDeptId(orderRemark.getDeptId()); |
| | | // one.setDeptId(orderRemark.getDeptId()); |
| | | one.setDoctorName(orderRemark.getDoctorName()); |
| | | one.setType(1); |
| | | remarkService.updateById(one); |
| | |
| | | } |
| | | ksId = Math.toIntExact(sysUser.getDeptId()); |
| | | } |
| | | |
| | | String config = configService.selectConfigByKey("qt_open_xdt"); |
| | | String byKey = configService.selectConfigByKey("qt_kjksid"); |
| | | List<Integer> split = new ArrayList<>(); // 存放转换后的integer类型结果 |
| | | if("Y".equals(config)){ |
| | | List<SysRole> roles = SecurityUtils.getLoginUser().getUser().getRoles(); |
| | | if(null !=roles && roles.size()>0){ |
| | | List<SysRole> list = roles.stream().filter(item -> item.getRoleName().contains("前台")).collect(Collectors.toList()); |
| | | if(list.size()>0){ |
| | | if(null !=ksId && ksId==100){ |
| | | ksId=999; |
| | | } |
| | | if(null !=byKey && !"".equals(byKey)){ |
| | | String[] arr = byKey.split(","); // 根据逗号进行切割 |
| | | for (String s : arr) { |
| | | int num = Integer.parseInt(s); // 将每个子字符串转换为integer类型 |
| | | split.add(num); // 添加到列表中 |
| | | } |
| | | } |
| | | }else { |
| | | split.add(ksId); |
| | | } |
| | | }else { |
| | | split.add(ksId); |
| | | } |
| | | }else { |
| | | split.add(ksId); |
| | | } |
| | | |
| | | //判断当前登陆的人是不是管理员。管理员可以看当前体检号下所有项目 |
| | | // if (sysUser.getUserName().equals("10001")) { |
| | | // QueryWrapper<TjOrderRemark> wqq = new QueryWrapper<>(); |
| | |
| | | // } |
| | | LambdaQueryWrapper<TjProject> wq2 = new LambdaQueryWrapper<>(); |
| | | if ((null != sysUser && !sysUser.getUserName().equals("10001")) && 100!=ksId) { |
| | | wq2.eq(TjProject::getDeptId, ksId); |
| | | wq2.in(TjProject::getDeptId,split); |
| | | } |
| | | //判断该项目是否需要打印报告 |
| | | wq2.eq(TjProject::getNeedReport,"Y"); |
| | |
| | | wqq.eq(TjOrderDetail::getOrderId, one.getOrderId()); |
| | | wqq.isNotNull(TjOrderDetail::getFlowingWaterId); |
| | | wqq.in(TjOrderDetail::getProId, proIdList); |
| | | wqq.notIn(TjOrderDetail::getProId, proIdList,projectService.getNneedReprotProId()); |
| | | List<TjOrderDetail> detailList = detailService.list(wqq); |
| | | if (detailList != null && detailList.size() > 0) { |
| | | List<Long> collect = detailList.stream().map(TjOrderDetail::getProId).collect(Collectors.toList()); |
| | |
| | | wq.eq("tj_number", tjNumber); |
| | | wq.in("pro_id", collect); |
| | | wq.ne("type", 2); |
| | | wq.ne("dept_id",241); |
| | | wq.notIn("pro_id", proIdList,projectService.getNneedReprotProId()); |
| | | List<TjOrderRemark> list = remarkService.list(wq); |
| | | if (list.size() == 0) { |
| | | return AjaxResult.success("该科室下无项目!"); |
| | |
| | | // } |
| | | |
| | | TjOrderRemark remark = remarkService.getTjOrderRemarkByTjNumAndProParentId(tjNumber, proParentId); |
| | | List<TjProject> proParentList = projectService.getTjProjectListBySoneId(proParentId); |
| | | |
| | | // List<TjProject> proParentList = projectService.getTjProjectListBySoneId(proParentId); |
| | | List<TjProject> proParentList = projectService.getTjProjectListByTbTransition(proParentId,tjNumber); |
| | | |
| | | if (null == proParentList || proParentList.size()==0) { |
| | | Map<String, Object> map = new HashMap<>(); |
| | | map.put("xiaoJieIds", null); |