| | |
| | | public AjaxResult addRemark(@ApiParam(value = "体检父项目备注集合") @RequestBody List<TjOrderRemark> remarklList) { |
| | | Long userId = Long.valueOf(SecurityUtils.getLoginUser().getUserId()); |
| | | SysUser sysUser = userService.getById(userId); |
| | | if (remarklList == null || remarklList.size() == 0) { |
| | | if (remarklList == null || remarklList.isEmpty()) { |
| | | return AjaxResult.success("操作失败"); |
| | | } |
| | | for (TjOrderRemark orderRemark : remarklList) { |
| | | List<String> summaryList = orderRemark.getSummaryList(); |
| | | if (null != summaryList && summaryList.size()>0 && !summaryList.contains(null) ) { |
| | | if (null != summaryList && !summaryList.isEmpty() && !summaryList.contains(null) ) { |
| | | orderRemark.setSummary(Joiner.on(";").join(orderRemark.getSummaryList())); |
| | | } |
| | | LambdaQueryWrapper<TjOrder> qw = new LambdaQueryWrapper<>(); |
| | |
| | | List<TjOrderDetail> tjOrderDetailList = orderRemark.getTjOrderDetailList(); |
| | | |
| | | final TjCustomer byId1 = customerService.getById(order.getUserId()); |
| | | if (null != tjOrderDetailList && tjOrderDetailList.size() > 0) { |
| | | if (null != tjOrderDetailList && !tjOrderDetailList.isEmpty()) { |
| | | //----------------------------------start |
| | | for (TjOrderDetail tjOrderDetail : tjOrderDetailList) { |
| | | final TjProject byId = projectService.getById(tjOrderDetail.getProId()); |
| | |
| | | remarkService.save(remark); |
| | | } else { |
| | | one.setRemark(orderRemark.getRemark()); |
| | | if (null != summaryList && summaryList.size()>0 && !summaryList.contains(null)) { |
| | | if (null != summaryList && !summaryList.isEmpty() && !summaryList.contains(null)) { |
| | | one.setSummary(Joiner.on(";").join(orderRemark.getSummaryList())); |
| | | } |
| | | // one.setDeptId(orderRemark.getDeptId()); |
| | |
| | | HashMap<String, Object> hisRequestParams = new HashMap<>(); |
| | | // 不在需要身份证号 |
| | | hisRequestParams.put("patientId",tjOrder.getCardId()); |
| | | AjaxResult queryPay = hisApiGetMethodService.getHISDataNew("QueryPay", hisRequestParams); |
| | | log.info("ltkj--- "+DateUtil.date()+"操作人id: "+userId+"操作科室: "+sysUser.getDeptId()+"操作的体检人: "+tjNumber); |
| | | AjaxResult queryPay = hisApiGetMethodService.getHISDataNew("QueryPay", hisRequestParams); |
| | | if (Integer.parseInt(queryPay.get("code").toString()) == 200) { |
| | | // List<Map<String, String>> data = (List<Map<String, String>>) queryPay.get("data"); |
| | | // BigDecimal cateFeeAll = BigDecimal.ZERO; |
| | |
| | | } |
| | | |
| | | @Transactional |
| | | private void extracted(TjOrder tjOrder, TjFlowingWater tjFlowingWater) { |
| | | public void extracted(TjOrder tjOrder, TjFlowingWater tjFlowingWater) { |
| | | tjFlowingWater.setPayStasus(1L); |
| | | tjFlowingWater.setPayType(0L); |
| | | tjFlowingWater.setTollCollectorId("148"); |
| | |
| | | /** |
| | | * 根据项目id获取建议 |
| | | */ |
| | | @GetMapping("/getDeptAdvice/{proId}") |
| | | @GetMapping("/getDeptAdvice") |
| | | @ApiOperation(value = "根据项目id获取建议") |
| | | public AjaxResult getDeptAdvice(@ApiParam(value = "父项目项目id") @PathVariable String proId) { |
| | | List<TjAdvice> list = new ArrayList<>(); |
| | | public AjaxResult getDeptAdvice(@ApiParam(value = "父项目项目id") @RequestParam(required = false) String proId, |
| | | @ApiParam(value = "内容") @RequestParam(required = false) String nr, |
| | | @ApiParam(value = "拼音码") @RequestParam(required = false) String pym, |
| | | @ApiParam(value = "页码") @RequestParam(defaultValue ="1") int page, |
| | | @ApiParam(value = "每页展示条数") @RequestParam(defaultValue ="10") int pageSize) { |
| | | LambdaQueryWrapper<TjAdvice> wq1 = new LambdaQueryWrapper<>(); |
| | | wq1.eq(TjAdvice::getProId, proId); |
| | | List<TjAdvice> list1 = tjAdviceService.list(wq1); |
| | | //如果没有项目id 就返回所有的建议集合 |
| | | if (list1.size() == 0) { |
| | | return AjaxResult.success(tjAdviceService.list()); |
| | | if(null !=proId){ |
| | | wq1.eq(TjAdvice::getProId, proId); |
| | | } |
| | | for (TjAdvice tjAdvice : list1) { |
| | | list.add(tjAdvice); |
| | | if(null !=nr && !nr.isEmpty()){ |
| | | wq1.like(TjAdvice::getTitle,nr); |
| | | }else if (null !=pym && !pym.isEmpty()){ |
| | | wq1.like(TjAdvice::getTitle,pym); |
| | | } |
| | | // else { |
| | | // wq1.last("limit 20"); |
| | | // } |
| | | Page<TjAdvice> pages=new Page<>(page,pageSize); |
| | | Page<TjAdvice> advicePage = tjAdviceService.page(pages, wq1); |
| | | Map<String,Object> map=new HashMap<>(); |
| | | map.put("list",advicePage.getRecords()); |
| | | map.put("total",advicePage.getTotal()); |
| | | // List<TjAdvice> list = tjAdviceService.list(wq1); |
| | | return AjaxResult.success(map); |
| | | } |
| | | |
| | | |
| | | |
| | | |
| | | @GetMapping("/getAdviceByTjNumAndPro") |
| | | @ApiOperation(value = "根据项目id和体检号获取建议") |
| | | public AjaxResult getAdviceByTjNumAndPro(@ApiParam(value = "父项目项目id") @RequestParam String proId, |
| | | @ApiParam(value = "体检号") @RequestParam String tjNum) { |
| | | LambdaQueryWrapper<TjOrderRemark> wq = new LambdaQueryWrapper<>(); |
| | | wq.eq(TjOrderRemark::getProId, proId); |
| | | wq.eq(TjOrderRemark::getTjNumber,tjNum); |
| | | TjOrderRemark remark = remarkService.getOne(wq); |
| | | List<TjAdvice> list =null; |
| | | if (null != remark && !StringUtils.isBlank(remark.getSummary())) { |
| | | String[] strings = StringUtils.split(remark.getSummary(), ";"); |
| | | if(null !=strings && strings.length>0){ |
| | | list = tjAdviceService.getAdviceStringByIds(strings); |
| | | } |
| | | } |
| | | return AjaxResult.success(list); |
| | | } |
| | | |
| | | |
| | | |
| | | /** |
| | | * 获取部门树列表 |
| | | */ |