| | |
| | | String resultMsg = ""; |
| | | if (null != baoGaoDans && !baoGaoDans.isEmpty()) { |
| | | Date dates = new Date(); |
| | | Map<String, Object> map = new HashMap<>(); |
| | | map.put("his_registration_id", order.getCardId()); |
| | | map.put("ksbm", ""); |
| | | map.put("pationid", ""); |
| | | map.put("ksrq", DateUtil.format(DateUtil.beginOfDay(order.getCreateTime()), "yyyy-MM-dd HH:mm:ss")); |
| | | map.put("jsrq", DateUtil.format(DateUtil.endOfDay(dates), "yyyy-MM-dd HH:mm:ss")); |
| | | map.put("pagecount", 10); |
| | | map.put("page", 1); |
| | | AjaxResult result = controller.Getlabreportinfo(map); |
| | | String jytbfs = configService.selectConfigByKey("jytbfs"); |
| | | AjaxResult result; |
| | | if (StrUtil.isNotBlank(jytbfs) && jytbfs.equalsIgnoreCase("Y")){ |
| | | Map<String, Object> map = new HashMap<>(); |
| | | map.put("his_registration_id", order.getCardId()); |
| | | map.put("ksbm", ""); |
| | | map.put("pationid", ""); |
| | | map.put("ksrq", DateUtil.format(DateUtil.beginOfDay(order.getCreateTime()), "yyyy-MM-dd HH:mm:ss")); |
| | | map.put("jsrq", DateUtil.format(DateUtil.endOfDay(dates), "yyyy-MM-dd HH:mm:ss")); |
| | | map.put("pagecount", 10); |
| | | map.put("page", 1); |
| | | result = controller.Getlabreportinfo(map); |
| | | }else { |
| | | result = ltkjHysqdService.getAsyncDataByPro("体检中心", order.getCardId(), "''", 100, 1, "'1'"); |
| | | } |
| | | log.info("检验项目查询返回值: " + JSONUtil.toJsonStr(result)); |
| | | |
| | | String result1 = getAjaxResult(result); |
| | | JSONObject object = getJSONObject(result1); |
| | | String code = object.getStr("ResultCode"); |
| | |
| | | boolean isInsertHysqd = false; |
| | | LtkjHysqd hysqd = new LtkjHysqd(); |
| | | hysqd.setTjh(order.getCardId()); |
| | | hysqd.setTmh(jsonObject.getStr("JYBGID")); |
| | | hysqd.setBbbh(jsonObject.getStr("BBDM")); |
| | | hysqd.setBbmc(jsonObject.getStr("BBMC")); |
| | | hysqd.setXmid(jsonObject.getStr("JYXMDM")); |
| | | hysqd.setXmmc(jsonObject.getStr("JYXMMC")); |
| | | hysqd.setSqsj(jsonObject.getStr("SQRQ")); |
| | | hysqd.setSqys(jsonObject.getStr("SQRBH")); |
| | | hysqd.setJgsj(jsonObject.getStr("JYBGRQ")); |
| | | hysqd.setSqrxm(jsonObject.getStr("SQRXM")); |
| | | hysqd.setSqdh(jsonObject.getStr("SQDBH")); |
| | | hysqd.setShrdm(jsonObject.getStr("JYYSBH")); |
| | | hysqd.setShrxm(jsonObject.getStr("JYYSQM")); |
| | | hysqd.setJybgjg(jsonObject.getStr("JYBGJG")); |
| | | hysqd.setTmh(jsonObject.getStr("JYBGID"));// 检验报告 ID |
| | | hysqd.setBbbh(jsonObject.getStr("BBDM"));// 标本代码 |
| | | hysqd.setBbmc(jsonObject.getStr("BBMC"));// 标本名称 |
| | | hysqd.setXmid(jsonObject.getStr("JYXMDM"));// 检验项目代码 |
| | | hysqd.setXmmc(jsonObject.getStr("JYXMMC"));// 检验项目名称 |
| | | hysqd.setSqsj(jsonObject.getStr("SQRQ"));// 申请时间 |
| | | hysqd.setSqys(jsonObject.getStr("SQRBH"));// 申请医生编号 |
| | | hysqd.setJgsj(jsonObject.getStr("JYBGRQ"));// 报告日期 |
| | | hysqd.setSqrxm(jsonObject.getStr("SQRXM"));// 申请医生姓名 |
| | | hysqd.setSqdh(jsonObject.getStr("SQDBH"));// 申请医生代码,字典代码 |
| | | hysqd.setShrdm(jsonObject.getStr("JYYSBH"));// 审核人员代码,字典代码 |
| | | hysqd.setShrxm(jsonObject.getStr("JYYSQM"));// 审核人员姓名 |
| | | hysqd.setJybgjg(jsonObject.getStr("JYBGJG"));// 检验报告结果 |
| | | hysqd.setCreateTime(new Date()); |
| | | QueryWrapper<LtkjHysqd> queryWrapper = new QueryWrapper<>(hysqd); |
| | | List<LtkjHysqd> list = ltkjHysqdService.list(queryWrapper); |
| | |
| | | results = jcsqdService.getTjJcProByHisCall("体检中心", order.getCardId(), "''", 100, 1, "'1'"); |
| | | DynamicDataSourceContextHolder.clearDataSourceType(); |
| | | } |
| | | log.info("检查项目查询返回值: " + results.toString()); |
| | | log.info("检查项目查询返回值: " + JSONUtil.toJsonStr(results)); |
| | | if (Integer.parseInt(results.get("code").toString()) == 200) { |
| | | List<Map<String, Object>> datas = (List<Map<String, Object>>) results.get("data"); |
| | | if (null != datas && !datas.isEmpty()) { |
| | |
| | | jcbgdService.save(jcbgd); |
| | | } |
| | | jcsqdService.saveLtkjExamJcsqd(order.getCardId()); |
| | | List<LtkjExamJcsqd> jcsqdList = jcsqdService.getLtkjJcsqdByTjh(order.getCardId()); |
| | | jcycxmService.deletedByTjh(order.getTjNumber()); |
| | | if(!jcsqdList.isEmpty()){ |
| | | for (LtkjExamJcsqd jcsqd : jcsqdList) { |
| | | if(StringUtil.isNotBlank(jcsqd.getJgzt())){ |
| | | String[] split = jcsqd.getJgzt().replaceAll("\n", "").split("。|;|;|,|,"); |
| | | for (String jg : split) { |
| | | if(StringUtil.isNotBlank(jg) && !jg.contains("未见异常") |
| | | && !jg.contains("未见明显异常") && !jg.contains("未见占位") && !jg.contains("未见") |
| | | && !jg.contains("未见明显")&& !jg.contains("正常")&& !jg.contains("双侧椎间孔无狭窄")){ |
| | | TjJcycxm jcycxm=new TjJcycxm(); |
| | | jcycxm.setTjh(order.getTjNumber()); |
| | | jcycxm.setYqid("jczyy"); |
| | | String[] split1 = jcsqd.getJcxmid().split(";"); |
| | | jcycxm.setProId(split1[0]); |
| | | jcycxm.setProName(jcsqd.getJcxmmc()); |
| | | jcycxm.setCreateTime(new Date()); |
| | | jcycxm.setJcjg(jg); |
| | | jcycxmService.save(jcycxm); |
| | | } |
| | | } |
| | | } |
| | | } |
| | | } |
| | | // List<LtkjExamJcsqd> jcsqdList = jcsqdService.getLtkjJcsqdByTjh(order.getCardId()); |
| | | // jcycxmService.deletedByTjh(order.getTjNumber()); |
| | | // if(!jcsqdList.isEmpty()){ |
| | | // for (LtkjExamJcsqd jcsqd : jcsqdList) { |
| | | // if(StringUtil.isNotBlank(jcsqd.getJgzt())){ |
| | | // String[] split = jcsqd.getJgzt().replaceAll("\n", "").split("。|;|;|,|,"); |
| | | // for (String jg : split) { |
| | | // if(StringUtil.isNotBlank(jg) && !jg.contains("未见异常") |
| | | // && !jg.contains("未见明显异常") && !jg.contains("未见占位") && !jg.contains("未见") |
| | | // && !jg.contains("未见明显")&& !jg.contains("正常")&& !jg.contains("双侧椎间孔无狭窄")){ |
| | | // TjJcycxm jcycxm=new TjJcycxm(); |
| | | // jcycxm.setTjh(order.getTjNumber()); |
| | | // jcycxm.setYqid("jczyy"); |
| | | // String[] split1 = jcsqd.getJcxmid().split(";"); |
| | | // jcycxm.setProId(split1[0]); |
| | | // jcycxm.setProName(jcsqd.getJcxmmc()); |
| | | // jcycxm.setCreateTime(new Date()); |
| | | // jcycxm.setJcjg(jg); |
| | | // jcycxmService.save(jcycxm); |
| | | // } |
| | | // } |
| | | // } |
| | | // } |
| | | // } |
| | | configController.tjjcycxm(tjNumber, "0"); |
| | | testMapper.updateDetailByTjJcCall(order.getCardId(), String.valueOf(order.getOrderId()), order.getTjNumber(), doctorId); |
| | | } else { |
| | | resultMsg += "\n检查项目暂时未出结果,请稍后同步!!!"; |