| | |
| | | import cn.hutool.core.date.DateTime; |
| | | import cn.hutool.core.date.DateUtil; |
| | | import cn.hutool.extra.pinyin.PinyinUtil; |
| | | import cn.hutool.json.JSONUtil; |
| | | import com.ltkj.common.core.domain.entity.SysMenu; |
| | | import com.ltkj.common.utils.SecurityUtils; |
| | | import com.ltkj.framework.datasource.DynamicDataSourceContextHolder; |
| | |
| | | try { |
| | | List<Aws> awsList = testMapper.getWsxmLtkjHysqdByLisViBySLAVEWS(s); |
| | | if(null !=awsList && !awsList.isEmpty()){ |
| | | log.info("外送项目个数->{} 结果",awsList.size()); |
| | | log.info(awsList.toString()); |
| | | testMapper.delWsxmjg(s); |
| | | log.info("删除外送项目成功"); |
| | |
| | | log.info("保存外送项目成功"); |
| | | } |
| | | List<LtkjHysqd> hysqdList = testMapper.getCcXZxYyLtkjHysqdByLisVi(s); |
| | | log.info("原hysqdList->{} 结果", JSONUtil.parseObj(hysqdList)); |
| | | List<LtkjHysqd> wssq = testMapper.getWsxmLtkjHysqdByLisVi(s); |
| | | if(null !=wssq && !wssq.isEmpty())hysqdList.addAll(wssq); |
| | | if(null !=wssq && !wssq.isEmpty()){ |
| | | log.info("外送项个->{} 结果",wssq.toString()); |
| | | hysqdList.addAll(wssq); |
| | | } |
| | | if (null != hysqdList && !hysqdList.isEmpty()) { |
| | | log.info("现hysqdList->{} 结果", JSONUtil.parseObj(hysqdList)); |
| | | for (LtkjHysqd hysqd : hysqdList) { |
| | | LtkjHysqd jybgid = ltkjHysqdService.getLtkjHysqdByTjhAndTmh(hysqd.getTjh(), hysqd.getTmh()); |
| | | if (null != jybgid) { |
| | |
| | | tjOrderService.tjQiandaodengji(tjOrder.getTjNumber()); |
| | | return result; |
| | | } |
| | | } finally { |
| | | }catch (Exception e){ |
| | | log.error(String.valueOf(e)); |
| | | } |
| | | finally { |
| | | lock.unlock(); |
| | | } |
| | | return AjaxResult.error(); |
| | |
| | | // 查询 对接Lis、Pacs申请如果类型包含在配置内则使用对接lis、pacs |
| | | |
| | | if (lisApiMethod.isUseLisAndPacsRegister(tjOrder)) { |
| | | log.info("签到登记进入未收费方法"); |
| | | // 这是上面个人方法引入数据 |
| | | tjFlowingWater.setPayStasus(1L); |
| | | newSaveextracted(tjOrder, tjCustomer, discount, sysUser, tjReservation, tjFlowingWater); |
| | |
| | | List<TjXdPicture> xdPictureList = xdPictureService.saveTjXdPicture(tjOrder.getTjNumber()); |
| | | xdPictureService.saveBatch(xdPictureList); |
| | | List<TjOrderDetail> detailList = tjOrderDetailService.getCaiYangDengJi(tjOrder.getOrderId()); |
| | | log.info("签到登记:采样数据查询个数"+detailList.size()); |
| | | addCaiYangDengJi(detailList, !detailList.isEmpty(), tjOrder, sysUser, null); |
| | | return AjaxResult.success(tjNumber); |
| | | } else { |
| | |
| | | } |
| | | |
| | | |
| | | |
| | | @GetMapping("/addCaiYangDengJi") |
| | | @ApiOperation(value = "手动添加采样记录接口") |
| | | public AjaxResult addCaiYangDengJi(@RequestParam("tjNum") String tjNum){ |
| | | |
| | | try { |
| | | TjOrder order = tjOrderService.getOrderByTjNum(tjNum); |
| | | if(null !=order){ |
| | | Long userId = Long.valueOf(SecurityUtils.getLoginUser().getUserId()); |
| | | SysUser sysUser = userService.getById(userId); |
| | | List<TjOrderDetail> detailList = tjOrderDetailService.getCaiYangDengJi(order.getOrderId()); |
| | | log.info("签到登记:采样数据查询个数"+detailList.size()); |
| | | addCaiYangDengJi(detailList, !detailList.isEmpty(), order, sysUser, null); |
| | | } |
| | | } catch (NumberFormatException e) { |
| | | log.error(String.valueOf(e)); |
| | | } |
| | | |
| | | return AjaxResult.success(); |
| | | } |
| | | |
| | | |
| | | @PostMapping("/addPlOrderAndDetail") |
| | | @ApiOperation(value = "体检批量签到登记接口") |
| | | // @Transactional //(切换数据库出错,所以注释) |
| | |
| | | |
| | | @GetMapping("/revocationReport/{TjNumber}") |
| | | @ApiOperation(value = "撤销生成体检报告") |
| | | @Transactional |
| | | public AjaxResult revocationReport(@PathVariable("TjNumber") String tjNumber) { |
| | | //逻辑删除数据库里的报告 |
| | | QueryWrapper<TjReport> wq1 = new QueryWrapper<>(); |
| | | wq1.select("re_id"); |
| | | wq1.eq("tj_number", tjNumber); |
| | | wq1.eq("type", "体检报告"); |
| | | TjReport tjReport = tjReportService.getOne(wq1); |
| | | if (null != tjReport) { |
| | | // 不在使用逻辑删除 逻辑删除导致打印报告生成 查询sql缓慢 |
| | | int i = tjReportService.deleteTjReportByReId(tjReport.getReId()); |
| | | if (i == 0) { |
| | | return AjaxResult.error("暂无体检报告,请撤回到总检未审核页面,需总检医生重新审核并生成报告!"); |
| | | } |
| | | } |
| | | |
| | | TjOrder one = tjOrderService.getOrderByTjNum(tjNumber); |
| | | if(null !=one){ |
| | |
| | | one.setPrintLastTime(null); |
| | | one.setDownloadLastTime(null); |
| | | if (tjOrderService.updateById(one)) { |
| | | |
| | | //逻辑删除数据库里的报告 |
| | | QueryWrapper<TjReport> wq1 = new QueryWrapper<>(); |
| | | wq1.select("re_id"); |
| | | wq1.eq("tj_number", tjNumber); |
| | | wq1.eq("type", "体检报告"); |
| | | TjReport tjReport = tjReportService.getOne(wq1); |
| | | if (null != tjReport) { |
| | | // 不在使用逻辑删除 逻辑删除导致打印报告生成 查询sql缓慢 |
| | | int i = tjReportService.deleteTjReportByReId(tjReport.getReId()); |
| | | if (i == 0) { |
| | | return AjaxResult.error("暂无体检报告,请撤回到总检未审核页面,需总检医生重新审核并生成报告!"); |
| | | } |
| | | } |
| | | |
| | | return AjaxResult.success("撤回成功!"); |
| | | } |
| | | } |
New file |
| | |
| | | # 项目相关配置 |
| | | ltkj: |
| | | # 名称 |
| | | name: ltkj |
| | | # 版本 |
| | | version: 1.0.1 |
| | | # 版权年份 |
| | | copyrightYear: 2022 |
| | | # 实例演示开关 |
| | | demoEnabled: true |
| | | # 文件路径 示例( Windows配置D:/ltkj/uploadPath,Linux配置 /home/ltkj/uploadPath) |
| | | # 用户换头像后的图片存储地址 测试:D:\ltkj\uploadPath\avatar\2022\12\14 |
| | | #profile: D:/ltkj/uploadPath |
| | | # profile: https://ltpeis.xaltjdkj.cn:5502/uploadPath |
| | | profile: http://192.168.0.5:5502/uploadPath |
| | | |
| | | # 获取ip地址开关 |
| | | addressEnabled: true |
| | | # 验证码类型 math 数组计算 char 字符验证 |
| | | captchaType: math |
| | | # 开发环境配置 |
| | | server: |
| | | # 服务器的HTTP端口,默认为8080 |
| | | port: 5002 |
| | | servlet: |
| | | # 应用的访问路径 |
| | | context-path: /ltkj-admin |
| | | tomcat: |
| | | # tomcat的URI编码 |
| | | uri-encoding: UTF-8 |
| | | # 连接数满后的排队数,默认为100 |
| | | accept-count: 1000 |
| | | threads: |
| | | # tomcat最大线程数,默认为200 |
| | | max: 800 |
| | | # Tomcat启动初始化的线程数,默认值10 |
| | | min-spare: 100 |
| | | |
| | | # 日志配置 |
| | | #logging: |
| | | # level: |
| | | # com.ltkj: debug |
| | | # org.springframework: warn |
| | | |
| | | # 用户配置 |
| | | user: |
| | | password: |
| | | # 密码最大错误次数 |
| | | maxRetryCount: 5 |
| | | # 密码锁定时间(默认10分钟) |
| | | lockTime: 10 |
| | | |
| | | # Spring配置 |
| | | spring: |
| | | # 资源信息 |
| | | messages: |
| | | # 国际化资源文件路径 |
| | | basename: i18n/messages |
| | | # 文件上传 |
| | | servlet: |
| | | multipart: |
| | | # 单个文件大小 |
| | | max-file-size: 2GB |
| | | # 设置总上传的文件大小 |
| | | max-request-size: 2GB |
| | | # 服务模块 |
| | | devtools: |
| | | restart: |
| | | # 热部署开关 |
| | | enabled: true |
| | | cache: |
| | | type: redis |
| | | |
| | | # redis 配置 |
| | | # redis: |
| | | # # 地址 |
| | | ## host: 101.42.27.146 |
| | | # host: localhost |
| | | # # 端口,默认为6379 |
| | | # port: 6379 |
| | | # # 数据库索引 |
| | | # database: 0 |
| | | # # 密码 |
| | | ## password: 654321 |
| | | # password: 123456 |
| | | # # 连接超时时间 |
| | | # timeout: 120s |
| | | # lettuce: |
| | | # pool: |
| | | # # 连接池中的最小空闲连接 |
| | | # min-idle: 0 |
| | | # # 连接池中的最大空闲连接 |
| | | # max-idle: 8 |
| | | # # 连接池的最大数据库连接数 |
| | | # max-active: 8 |
| | | # # #连接池最大阻塞等待时间(使用负值表示没有限制) |
| | | # max-wait: -1ms |
| | | # 邮件 |
| | | mail: |
| | | # from 要和 username 一致, 否则报错 |
| | | from: 1138758025@qq.com |
| | | # 邮件服务地址 |
| | | host: smtp.qq.com |
| | | # 用户名 |
| | | username: 1138758025@qq.com |
| | | # 授权码 (设置 - 账户 - POP3/SMTP服务) |
| | | password: lwsbmlbqgpaqfgdb |
| | | # QQ邮箱加密端口,不同邮箱的端口不一样 |
| | | port: 465 |
| | | properties: |
| | | mail: |
| | | smtp: |
| | | socketFactory: |
| | | class: javax.net.ssl.SSLSocketFactory |
| | | ssl: |
| | | trust: smtp.qq.com |
| | | # 是否需要用户认证 |
| | | auth: true |
| | | starttls: |
| | | # 启用TLS加密 |
| | | enable: true |
| | | required: true |
| | | datasource: |
| | | druid: |
| | | stat-view-servlet: |
| | | enabled: true |
| | | url-pattern: /druid/* |
| | | login-username: 10001 |
| | | login-password: admin123 |
| | | reset-enable: true |
| | | allow: |
| | | filters: stat,wall,log4j # 启用日志和监控过滤器 |
| | | stat: |
| | | mergeSql: true # 合并SQL统计信息 |
| | | slowSqlMillis: 3000 # 配置 SQL 慢查询阈值,单位是毫秒,3秒即 3000ms |
| | | |
| | | # token配置 |
| | | token: |
| | | # 令牌自定义标识 |
| | | header: Authorization |
| | | # 令牌密钥 |
| | | secret: xaltjdkjyxgs_sjh&1987 |
| | | |
| | | secret_key: ltkj_xaltjdkjsjh |
| | | # 令牌有效期(默认30分钟) |
| | | expireTime: 180 |
| | | # 是否允许账户多终端同时登录(true允许 false不允许) |
| | | soloLogin: true |
| | | #是否开启登录时判断商户秘钥是否过期 |
| | | secret_key_login: true |
| | | |
| | | # MyBatis Plus配置 |
| | | mybatis-plus: |
| | | # 搜索指定包别名 |
| | | typeAliasesPackage: com.ltkj.**.domain |
| | | # 配置mapper的扫描,找到所有的mapper.xml映射文件 |
| | | mapperLocations: classpath*:mapper/**/*Mapper.xml |
| | | # 加载全局的配置文件 |
| | | configLocation: classpath:mybatis/mybatis-config.xml |
| | | global-config: |
| | | db-config: |
| | | logic-not-delete-value: 0 |
| | | logic-delete-value: 1 |
| | | update-strategy: not_null |
| | | |
| | | |
| | | # PageHelper分页插件 |
| | | pagehelper: |
| | | helperDialect: mysql |
| | | supportMethodsArguments: true |
| | | params: count=countSql |
| | | |
| | | # Swagger配置 |
| | | swagger: |
| | | # 是否开启swagger |
| | | enabled: true |
| | | # 请求前缀 |
| | | pathMapping: / |
| | | |
| | | # 防止XSS攻击 |
| | | xss: |
| | | # 过滤开关 |
| | | enabled: true |
| | | # 排除链接(多个用逗号分隔) |
| | | excludes: /system/notice,/system/package |
| | | # 匹配链接 |
| | | urlPatterns: /system/*,/monitor/*,/tool/* |
| | | |
| | | |
| | | # 体检报告模板和报告临时生成存储的文件夹路径 |
| | | path: |
| | | filePath: C:\Tjreport\chkwyy |
| | | # nginx图片服务器 |
| | | reportServer: https://ltpeis.xaltjdkj.cn:5516/ |
| | | |
| | | |
| | | # 体检套餐和轮播图存储路径 |
| | | photoPath: C:\AppPhoto\uploadPath\ |
| | | # nginx图片服务器 |
| | | #photoServer: https://ltpeis.xaltjdkj.cn:5502/uploadPath/ |
| | | photoServer: http://192.168.0.5:5502/uploadPath/ |
| | | |
| | | |
| | | |
| | | # 微信小程序appid secret |
| | | xcx: |
| | | appid: wx40a545f1a8eb1d9d |
| | | secret: c86c1ff7f91c16380111878e9a259237 |
| | | msgDataFormat: JSON |
| | | token: token # 微信小程序消息服务器配置的token |
| | | aesKey: aesKey # 微信小程序消息服务器配置的EncodingAESKey |
| | | # 开发者应该设置成自己的wx相关信息 |
| | | wx: |
| | | # 小程序 |
| | | miniapp: |
| | | appid: wx40a545f1a8eb1d9d |
| | | secret: c86c1ff7f91c16380111878e9a259237 |
| | | msg-data-format: XML |
| | | pay: |
| | | #appid |
| | | app-id: wx40a545f1a8eb1d9d |
| | | mch-id: 1642930999 #商户号 |
| | | mch-key: Xianlutaikeji666888999shijihongL #密钥 |
| | | #key-path: E:\mycode\apppwd\1643225121_20230427_cert\apiclient_cert.p12 #本地证书路径,在微信商户后台下载 |
| | | key-path: D:\WXCertUtil\tjcert\apiclient_cert.p12 #服务器证书路径,在微信商户后台下载 |
| | | # pay-score-notify-url: http://192.168.0.101:5011/cus/order/pay-notify #微信支付回调地址 |
| | | # pay-score-notify-url: https://ltpeis.xaltjdkj.cn:5011/ltkj-admin/cus/order/pay-notify #微信支付回调地址 |
| | | pay-score-notify-url: https://ltpeis.xaltjdkj.cn:5021/ltkj-admin/cus/order/pay-notify #微信支付回调地址 |
| | | |
| | | #积木报表访问地址 |
| | | jimu: |
| | | # path: https://ltpeis.xaltjdkj.cn:5011/ltkj-admin |
| | | # path: https://ltpeis.xaltjdkj.cn:5021/ltkj-admin |
| | | path: http://192.168.0.5:5000/ltkj-admin |
| | | # path: http://10.168.0.9:5011 |
| | | # path: http://192.168.0.105:5011 |
| | | # path: http://192.168.1.113:5011 |
| | | |
| | | |
| | | jeecg : |
| | | jmreport: |
| | | # 打印纸张配置 title描述 size宽高 |
| | | printPaper: |
| | | - title: 小票打印 |
| | | size: |
| | | - 40 |
| | | - 60 |
| | | # ip = 101.42.27.146 |
| | | # prot = 3306 |
| | | # name = ltkjpeis10 |
| | | # username = root |
| | | # password = Root_ltkj123 |
| | | config: |
| | | properties: C:\ltkjprojectconf\chkwyy-config.properties |
| | | path: C:\ltkjprojectconf |
| | |
| | | " create_id,\n" + |
| | | " pro_type) \n" + |
| | | " \n" + |
| | | " SELECT #{orderId},a.pro_id,IFNULL(trim(b.pro_default),null),'0',SYSDATE(),#{userName},b.is_sampling,#{userId},IFNULL(a.pac_id,0)" + |
| | | " SELECT #{orderId},a.pro_id,IFNULL(trim(b.pro_default),null),IF(b.need_report<>'Y',1,0),SYSDATE(),#{userName},b.is_sampling,#{userId},IFNULL(a.pac_id,0)" + |
| | | " FROM tb_transition a LEFT JOIN tj_project b ON a.pro_id=b.pro_id WHERE a.cus_id=#{cusId} AND a.card_id=#{cardId} \n" + |
| | | "\t\t\n" + |
| | | "\tUNION\n" + |
| | | " \n" + |
| | | "\tSELECT #{orderId},a.parent_pro_id,IFNULL(trim(b.pro_default),null),'0',SYSDATE(),#{userName},b.is_sampling,#{userId},IFNULL(a.pac_id,0) " + |
| | | "\tSELECT #{orderId},a.parent_pro_id,IFNULL(trim(b.pro_default),null),IF(b.need_report<>'Y',1,0),SYSDATE(),#{userName},b.is_sampling,#{userId},IFNULL(a.pac_id,0) " + |
| | | "FROM tb_transition a LEFT JOIN tj_project b ON a.parent_pro_id=b.pro_id WHERE a.cus_id=#{cusId} AND a.card_id=#{cardId} GROUP BY a.parent_pro_id") |
| | | boolean saveTjOrderDetailsByCusId(@Param("cusId")String cusId,@Param("orderId")String orderId,@Param("userName")String userName,@Param("userId") String userId,@Param("cardId") String cardId); |
| | | |
| | |
| | | "tj_number,\n" + |
| | | "update_by,\n" + |
| | | "update_time,\n" + |
| | | "update_id\n" + |
| | | "update_id,\n" + |
| | | "type\n" + |
| | | ")\n" + |
| | | "\n" + |
| | | "SELECT b.pro_id,b.dept_id,SYSDATE(),#{userName},#{userId},#{tjNumber},#{userName},SYSDATE(),#{userId} FROM tj_order_detail a " + |
| | | "SELECT b.pro_id,b.dept_id,SYSDATE(),#{userName},#{userId},#{tjNumber},#{userName},SYSDATE(),#{userId},IF(b.need_report<>'Y',1,0) FROM tj_order_detail a " + |
| | | "LEFT JOIN tj_project b ON a.pro_id=b.pro_id WHERE a.order_id=#{orderId} AND\n" + |
| | | "b.pro_parent_id=0") |
| | | boolean saveTjOrderRemarkByOrderId(@Param("tjNumber")String tjNumber,@Param("userName") String userName,@Param("userId") String userId,@Param("orderId")String orderId); |
| | |
| | | " LEFT JOIN sys_user us ON us.user_id = re.doctor_name\n" + |
| | | " WHERE\n" + |
| | | // " re.type != 2 AND\n" + |
| | | " re.tj_number = #{tjNumber} and re.dept_id !=532 and pro.pro_name not like '%费%'" + |
| | | " re.tj_number = #{tjNumber} and re.dept_id !=532 and pro.pro_name not like '%费%' and pro.need_report='Y'" + |
| | | " <when test='sfzpacs == true'> " + |
| | | " AND dep.org_type = 2"+ |
| | | " </when>"+ |