| | |
| | | import java.util.*; |
| | | import java.util.concurrent.ExecutorService; |
| | | import java.util.concurrent.Executors; |
| | | import java.util.concurrent.TimeUnit; |
| | | import java.util.regex.Matcher; |
| | | import java.util.regex.Pattern; |
| | | import java.util.stream.Collectors; |
| | |
| | | @Override |
| | | @Async("async") |
| | | public void saveNewReservationConfirm(List<TjReservation> rightList) { |
| | | long l = System.currentTimeMillis(); |
| | | if(null !=rightList && rightList.size()>0){ |
| | | //创建线程池 |
| | | ExecutorService threadPool = Executors.newFixedThreadPool(rightList.size()); |
| | |
| | | }); |
| | | } |
| | | } |
| | | long ll = System.currentTimeMillis(); |
| | | |
| | | System.out.println("这段代码执行时间为"+ (ll-l)); |
| | | } |
| | | |
| | | @Override |
| | | @Async("async") |
| | | public void updateCheckType(String tjNum) { |
| | | // AjaxResult ajaxResult = getAjaxResult(tjNum); |
| | | redisCache.setCacheMapValue("updateCheckType"+tjNum,tjNum,getAjaxResult(tjNum)); |
| | | redisCache.setHashKeyExpireTime("updateCheckType"+tjNum,7L, TimeUnit.DAYS); |
| | | } |
| | | |
| | | @Override |
| | |
| | | }else { |
| | | redisCache.setCacheMapValue("getOrderDetailByProParentId"+tjNumber,proParentId,getOrderDetailByProParentId(proParentId,tjNumber)); |
| | | } |
| | | redisCache.setHashKeyExpireTime("getOrderDetailByProParentId"+tjNumber,7L,TimeUnit.DAYS); |
| | | |
| | | } |
| | | |
| | |
| | | return customerList; |
| | | } |
| | | //总检点击体检信息详情 |
| | | private AjaxResult getAjaxResult(String tjNumber) { |
| | | private List<Map<String, Object>> getAjaxResult(String tjNumber) { |
| | | List<Map<String, Object>> list = new ArrayList<>(); |
| | | TjOrder one = orderService.getOrderByTjNum(tjNumber); |
| | | |
| | | if (one == null) { |
| | | return AjaxResult.error("暂无数据!!"); |
| | | return list; |
| | | } |
| | | |
| | | TjCustomer customer = tjCustomerService.getById(one.getUserId()); |
| | | List<TjOrderRemark> remarkList = orderRemarkService.getRemarkListByTjNumAndType(tjNumber); |
| | | |
| | |
| | | if (null != tjOrderDetails && tjOrderDetails.size() > 0) { |
| | | for (TjOrderDetail tjOrderDetail : tjOrderDetails) { |
| | | final TjProject byId = projectService.selectTjProjectByProId(tjOrderDetail.getProId()); |
| | | if(null==byId){ |
| | | tjOrderDetailService.removeById(tjOrderDetail.getOrderDetailId()); |
| | | }else { |
| | | tjOrderDetail.setProject(byId); |
| | | } |
| | | List<TjStandard> list2 = tjStandardService.getTjStandardListByProId(String.valueOf(tjOrderDetail.getProId())); |
| | | if (list2.size() == 0) { |
| | | tjOrderDetail.setStandard(new TjStandard()); |
| | |
| | | parent.put("doctorName", userService.getById(remark.getDoctorName()).getNickName()); |
| | | } |
| | | list.add(parent); |
| | | } else { |
| | | return AjaxResult.success("该客户没有体检项目数据"); |
| | | } |
| | | // } |
| | | } |
| | | return AjaxResult.success(list); |
| | | } |
| | | return AjaxResult.success("该客户没有体检项目数据!"); |
| | | return list; |
| | | } |
| | | //已签收/未签收 |
| | | private List<Map<String, Object>> getYWqsResult(int a) { |