Merge remote-tracking branch 'origin/master'

This commit is contained in:
tangw 2025-12-25 20:14:31 +08:00
commit b1bbb726cd
25 changed files with 463 additions and 46 deletions

View File

@ -15,5 +15,7 @@ public class LabInputmdl {
private Integer qsybh; private Integer qsybh;
private Integer jsybh; private Integer jsybh;
private String yblx; private String yblx;
private String oldMbmc;
} }

View File

@ -14,4 +14,5 @@ public class LabInputmdlDetail {
private String xmdh; private String xmdh;
private String mrz; private String mrz;
private String xmmc; private String xmmc;
private String oldMbmc;
} }

View File

@ -18,4 +18,6 @@ public class XmReqitemVsReportitem {
private String tdh; private String tdh;
private String mrz; private String mrz;
private String def; private String def;
private String xmmc;
private String sl;
} }

View File

@ -29,5 +29,5 @@ public class SysLogConstants {
public static final String XMMEDINSTR_LOG = "抗生素通道号设定"; public static final String XMMEDINSTR_LOG = "抗生素通道号设定";
public static final String XMMEDMAIN_LOG = "细菌抗生素组对照"; public static final String XMMEDMAIN_LOG = "细菌抗生素组对照";
public static final String XMKNOWLEDGE_LOG = "知识库"; public static final String XMKNOWLEDGE_LOG = "知识库";
public static final String LABCHECKRULES_LOG = "高级审核条件";
} }

View File

@ -1,5 +1,6 @@
package com.czlis.interfaceCommon.mapper; package com.czlis.interfaceCommon.mapper;
import com.czlis.common.core.domain.Result;
import com.czlis.common.core.domain.entity.lis.LabCheckrules; import com.czlis.common.core.domain.entity.lis.LabCheckrules;
import java.util.List; import java.util.List;
@ -18,4 +19,12 @@ public interface LabCheckrulesMapper {
* @return * @return
*/ */
List<LabCheckrules> getLabCheckrulesAutocheck(String yq); List<LabCheckrules> getLabCheckrulesAutocheck(String yq);
void insert(LabCheckrules labCheckrules);
void update(LabCheckrules labCheckrules);
List<LabCheckrules> query(LabCheckrules labCheckrules);
void delete(int ruleid);
} }

View File

@ -9,7 +9,7 @@ import java.util.List;
public interface LabInputmdlMapper { public interface LabInputmdlMapper {
List<LabInputmdl> query(LabInputmdl labInputmdl); List<LabInputmdl> query(LabInputmdl labInputmdl);
List<LabInputmdlDetail> queryDetail(LabInputmdl labInputmdl); List<LabInputmdlDetail> queryDetail(LabInputmdlDetail labInputmdlDetail);
void add(LabInputmdl labInputmdl); void add(LabInputmdl labInputmdl);

View File

@ -0,0 +1,9 @@
package com.czlis.interfaceCommon.mapper;
import com.czlis.common.core.domain.entity.lis.LabPatInfo;
public interface LabPatInfoMapper {
LabPatInfo selectLabPatInfoOne(LabPatInfo labPatInfo);
void insert(LabPatInfo labPatInfo);
void update(LabPatInfo labPatInfo);
}

View File

@ -12,4 +12,44 @@
FROM lab_checkrules where (isnull(autocheck,'') = '1') and rptunitid = #{yq} FROM lab_checkrules where (isnull(autocheck,'') = '1') and rptunitid = #{yq}
</select> </select>
<select id="query" resultType="com.czlis.common.core.domain.entity.lis.LabCheckrules">
select * from lab_checkrules
<where>
<if test="ruleid != null">and ruleid = #{ruleid}</if>
<if test="rptunitid != null and rptunitid != ''">and rptunitid = #{rptunitid}</if>
<if test="checktype != null and checktype != ''">and checktype = #{checktype}</if>
<if test="logflag != null and logflag != ''">and logflag = #{logflag}</if>
<if test="autocheck != null and autocheck != ''">and autocheck = #{autocheck}</if>
<if test="actions != null and actions != ''">and actions = #{actions}</if>
</where>
</select>
<insert id="insert">
insert into lab_checkrules(
<if test="autocheck != null and autocheck != ''">autocheck,</if>
rptunitid, checkrules, checktype, logflag, logcontent, ruledisplay, actions)
values(
<if test="autocheck != null and autocheck != ''">#{autocheck},</if>
#{rptunitid}, #{checkrules},#{checktype},#{logflag},#{logcontent},#{ruledisplay},#{actions}
)
</insert>
<update id="update">
update lab_checkrules set
<if test="checkrules != null and checkrules != ''">checkrules = #{checkrules},</if>
<if test="checktype != null and checktype != ''">checktype = #{checktype},</if>
<if test="logflag != null and logflag != ''">logflag = #{logflag},</if>
<if test="logcontent != null and logcontent != ''">logcontent = #{logcontent},</if>
<if test="ruledisplay != null and ruledisplay != ''">ruledisplay = #{ruledisplay},</if>
<if test="actions != null and actions != ''">actions = #{actions},</if>
<if test="autocheck != null and autocheck != ''">autocheck = #{autocheck},</if>
rptunitid = #{rptunitid}
where ruleid = #{ruleid}
</update>
<delete id="delete">
delete from lab_checkrules where ruleid = #{ruleid}
</delete>
</mapper> </mapper>

View File

@ -7,16 +7,17 @@
select * from lab_inputmdl select * from lab_inputmdl
<where> <where>
<if test="yq != null and yq !=''"> and yq = #{yq}</if> <if test="yq != null and yq !=''"> and yq = #{yq}</if>
<if test="mbmc != null and mbmc !=''"> and mbmc = #{mbmc}</if> <if test="mbmc != null and mbmc !=''"> and mbmc like '%'+#{mbmc}+'%'</if>
</where> </where>
</select> </select>
<select id="queryDetail" resultType="com.czlis.common.core.domain.entity.lis.LabInputmdlDetail"> <select id="queryDetail" resultType="com.czlis.common.core.domain.entity.lis.LabInputmdlDetail">
select * from lab_inputmdldetail select a.*,b.xmmc from lab_inputmdldetail a,xm_info b
<where> <where>
<if test="yq != null and yq !=''"> and yq = #{yq}</if> a.yq = b.yq and a.xmdh = b.xmdh
<if test="mbmc != null and mbmc !=''"> and mbmc = #{mbmc}</if> <if test="yq != null and yq !=''"> and a.yq = #{yq}</if>
<if test="xh != null "> and xh = #{xh}</if> <if test="mbmc != null and mbmc !=''"> and a.mbmc = #{mbmc}</if>
<if test="xh != null "> and a.xh = #{xh}</if>
</where> </where>
</select> </select>
@ -39,7 +40,6 @@
<update id="update"> <update id="update">
update lab_inputmdl update lab_inputmdl
<set> <set>
<if test="mbmc != null and mbmc != ''"> mbmc = #{mbmc},</if>
<if test="srbh != null"> srbh = #{srbh},</if> <if test="srbh != null"> srbh = #{srbh},</if>
<if test="zdsr != null and zdsr != ''"> zdsr = #{zdsr},</if> <if test="zdsr != null and zdsr != ''"> zdsr = #{zdsr},</if>
<if test="qsybh != null "> qsybh = #{qsybh},</if> <if test="qsybh != null "> qsybh = #{qsybh},</if>
@ -47,7 +47,7 @@
<if test="yblx != null and yblx != ''"> yblx = #{yblx},</if> <if test="yblx != null and yblx != ''"> yblx = #{yblx},</if>
yq = #{yq},mbmc = #{mbmc} yq = #{yq},mbmc = #{mbmc}
</set> </set>
where yq = #{yq},mbmc = #{mbmc} where yq = #{yq} and mbmc = #{oldMbmc}
</update> </update>
<update id="updateDetail"> <update id="updateDetail">
@ -57,7 +57,7 @@
<if test="mrz != null and mrz != ''">mrz = #{mrz},</if> <if test="mrz != null and mrz != ''">mrz = #{mrz},</if>
yq = #{yq},mbmc = #{mbmc},xh=#{xh} yq = #{yq},mbmc = #{mbmc},xh=#{xh}
</set> </set>
where yq = #{yq},mbmc = #{mbmc},xh=#{xh} where yq = #{yq} and mbmc = #{oldMbmc} and xh=#{xh}
</update> </update>
<delete id="delete"> <delete id="delete">
@ -65,7 +65,8 @@
</delete> </delete>
<delete id="deleteDetail"> <delete id="deleteDetail">
delete from lab_inputmdldetail where yq = #{yq} and mbmc = #{mbmc} and xh = #{xh} delete from lab_inputmdldetail where yq = #{yq} and mbmc = #{mbmc}
<if test="xh != null"> and xh = #{xh}</if>
</delete> </delete>
<select id="getLabInputmdl" resultType="com.czlis.common.core.domain.entity.lis.LabInputmdl"> <select id="getLabInputmdl" resultType="com.czlis.common.core.domain.entity.lis.LabInputmdl">

View File

@ -0,0 +1,32 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="com.czlis.interfaceCommon.mapper.LabPatInfoMapper">
<select id="selectLabPatInfoOne" resultType="com.czlis.common.core.domain.entity.lis.LabPatInfo">
select * from lab_patinfo where jyrq = #{jyrq} and yq = #{yq} and ybh = #{ybh} and xxlb = #{xxlb}
</select>
<insert id="insert">
insert into lab_patinfo(
<if test="val1 != null and val1 != ''">val1,</if>
<if test="val2 != null and val2 != ''">val2,</if>
<if test="val3 != null and val3 != ''">val3,</if>
<if test="textinfo != null and textinfo != ''">textinfo,</if>
jyrq, yq, ybh, xxlb) values(
<if test="val1 != null and val1 != ''">#{val1},</if>
<if test="val2 != null and val2 != ''">#{val2},</if>
<if test="val3 != null and val3 != ''">#{val3},</if>
<if test="textinfo != null and textinfo != ''">#{textinfo},</if>
#{jyrq},#{yq},#{ybh},#{xxlb}
)
</insert>
<update id="update">
update lab_patinfo set
<if test="val1 != null and val1 != ''">val1 = #{val1},</if>
<if test="val2 != null and val2 != ''">val2 = #{val2},</if>
<if test="val3 != null and val3 != ''">val3 = #{val3},</if>
<if test="textinfo != null and textinfo != ''">textinfo = #{textinfo},</if>
jyrq = #{jyrq}, yq = #{yq} , ybh = #{ybh}
where jyrq = #{jyrq} and yq = #{yq} and ybh = #{ybh} and xxlb = #{xxlb}
</update>
</mapper>

View File

@ -0,0 +1,29 @@
package com.czlis.liswork.controller.dict;
import com.czlis.common.core.domain.Result;
import com.czlis.common.core.domain.entity.lis.XmInfo;
import com.czlis.liswork.service.XmInfoService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
/**
* 老的xm_info数据查询
*/
@Api(tags = "老的xm_info数据查询")
@RestController
@RequestMapping("/oldxminfo")
public class XmInfoController {
@Autowired
private XmInfoService xmInfoService;
@ApiOperation("查询数据")
@GetMapping("/query")
public Result query(XmInfo xmInfo) {
return xmInfoService.query(xmInfo);
}
}

View File

@ -10,11 +10,9 @@ import com.czlis.interfaceCommon.constants.SysLogConstants;
import com.czlis.liswork.service.XmReqitemVsReportitemService; import com.czlis.liswork.service.XmReqitemVsReportitemService;
import io.swagger.annotations.Api; import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation; import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.DeleteMapping; import org.springframework.web.bind.annotation.*;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import java.util.List; import java.util.List;
@ -24,13 +22,20 @@ import java.util.List;
@Api(tags = "收费项目报告项目对照") @Api(tags = "收费项目报告项目对照")
@RestController @RestController
@RequestMapping("/vsReportitem") @RequestMapping("/vsReportitem")
@Slf4j
public class XmReqitemVsReportitemController extends BaseController { public class XmReqitemVsReportitemController extends BaseController {
@Autowired @Autowired
private XmReqitemVsReportitemService xmReqitemVsReportitemService; private XmReqitemVsReportitemService xmReqitemVsReportitemService;
@ApiOperation("查询收费项目报告项目对照") @ApiOperation("查询收费项目报告项目对照")
@PostMapping("/query") @GetMapping("/queryList")
public Result queryList(XmReqitemVsReportitem xmReqitemVsReportitem){
return xmReqitemVsReportitemService.queryList(xmReqitemVsReportitem);
}
@ApiOperation("查询收费项目报告项目对照")
@GetMapping("/query")
public TableDataInfo query(XmReqitemVsReportitem xmReqitemVsReportitem){ public TableDataInfo query(XmReqitemVsReportitem xmReqitemVsReportitem){
startPage(); startPage();
List<XmReqitemVsReportitem> xmReqitemVsReportitemList = xmReqitemVsReportitemService.query(xmReqitemVsReportitem); List<XmReqitemVsReportitem> xmReqitemVsReportitemList = xmReqitemVsReportitemService.query(xmReqitemVsReportitem);
@ -40,21 +45,28 @@ public class XmReqitemVsReportitemController extends BaseController {
@ApiOperation("新增收费项目报告项目对照") @ApiOperation("新增收费项目报告项目对照")
@PostMapping("/add") @PostMapping("/add")
@Log(title = SysLogConstants.XMREQITEMVSREPORTITEM_LOG,businessType = BusinessType.INSERT) @Log(title = SysLogConstants.XMREQITEMVSREPORTITEM_LOG,businessType = BusinessType.INSERT)
public Result add(XmReqitemVsReportitem xmReqitemVsReportitem){ public Result add(@RequestBody List<XmReqitemVsReportitem> xmReqitemVsReportitemList){
return xmReqitemVsReportitemService.add(xmReqitemVsReportitem); return xmReqitemVsReportitemService.add(xmReqitemVsReportitemList);
} }
@ApiOperation("删除收费项目报告项目对照") @ApiOperation("删除收费项目报告项目对照")
@DeleteMapping("/del") @DeleteMapping("/del")
@Log(title = SysLogConstants.XMREQITEMVSREPORTITEM_LOG ,businessType = BusinessType.DELETE) @Log(title = SysLogConstants.XMREQITEMVSREPORTITEM_LOG ,businessType = BusinessType.DELETE)
public Result delete(String sqxmdh,String yq,String xmdh,String tdh){ public Result delete(@RequestParam String sqxmdh,@RequestParam String yq,@RequestParam String xmdh,@RequestParam String seq){
return xmReqitemVsReportitemService.delete(sqxmdh,yq,xmdh,tdh); return xmReqitemVsReportitemService.delete(sqxmdh,yq,xmdh,seq);
} }
@ApiOperation("修改收费项目报告项目对照") @ApiOperation("修改收费项目报告项目对照")
@PostMapping("/update") @PostMapping("/update")
@Log(title = SysLogConstants.XMREQITEMVSREPORTITEM_LOG ,businessType = BusinessType.UPDATE) @Log(title = SysLogConstants.XMREQITEMVSREPORTITEM_LOG ,businessType = BusinessType.UPDATE)
public Result update(XmReqitemVsReportitem xmReqitemVsReportitem){ public Result update(@RequestBody XmReqitemVsReportitem xmReqitemVsReportitem){
return xmReqitemVsReportitemService.update(xmReqitemVsReportitem); return xmReqitemVsReportitemService.update(xmReqitemVsReportitem);
} }
@Log(title = SysLogConstants.XMREQITEMVSREPORTITEM_LOG ,businessType = BusinessType.UPDATE)
@ApiOperation("搜索项目")
@GetMapping("/search")
public Result searchXmdh(String yq){
return xmReqitemVsReportitemService.searchXmdh(yq);
}
} }

View File

@ -0,0 +1,46 @@
package com.czlis.liswork.controller.xtwh;
import com.czlis.common.annotation.Log;
import com.czlis.common.core.domain.Result;
import com.czlis.common.core.domain.entity.lis.LabCheckrules;
import com.czlis.common.enums.BusinessType;
import com.czlis.interfaceCommon.constants.SysLogConstants;
import com.czlis.liswork.service.LabCheckrulesService;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import java.util.List;
@Api(tags = "高级审核条件")
@RestController
@RequestMapping("/labCheckrules")
@Slf4j
public class LabCheckrulesController {
@Autowired
private LabCheckrulesService labCheckrulesService;
@ApiOperation("获取审核条件列表")
@GetMapping("/queryList")
public Result queryList(LabCheckrules labCheckrules) {
return labCheckrulesService.queryList(labCheckrules);
}
@Log(title = SysLogConstants.LABCHECKRULES_LOG,businessType = BusinessType.UPDATE)
@ApiOperation("保存高级审核条件")
@PostMapping("/update")
public Result update(@RequestBody List<LabCheckrules> labCheckrulesList){
return labCheckrulesService.update(labCheckrulesList);
}
@Log(title = SysLogConstants.LABCHECKRULES_LOG,businessType = BusinessType.DELETE)
@GetMapping("/delete")
@ApiOperation("删除高级审核条件")
public Result delete(int id){
return labCheckrulesService.delete(id);
}
}

View File

@ -34,8 +34,8 @@ public class LabInputmdlController {
@ApiOperation("查询明细数据") @ApiOperation("查询明细数据")
@GetMapping("/queryDetail") @GetMapping("/queryDetail")
public Result queryDetail(LabInputmdl labInputmdl){ public Result queryDetail(LabInputmdlDetail labInputmdlDetail){
return labInputmdlService.queryDetail(labInputmdl); return labInputmdlService.queryDetail(labInputmdlDetail);
} }
@Log(title = SysLogConstants.LABINPUTMDL_LOG,businessType = BusinessType.INSERT) @Log(title = SysLogConstants.LABINPUTMDL_LOG,businessType = BusinessType.INSERT)
@ -61,8 +61,8 @@ public class LabInputmdlController {
@Log(title = SysLogConstants.LABINPUTMDL_LOG,businessType = BusinessType.DELETE_DETAIL) @Log(title = SysLogConstants.LABINPUTMDL_LOG,businessType = BusinessType.DELETE_DETAIL)
@ApiOperation("删除明细数据") @ApiOperation("删除明细数据")
@GetMapping("/deleteDetail") @PostMapping("/deleteDetail")
public Result deleteDetail(List<LabInputmdlDetail> labInputmdlDetailList){ public Result deleteDetail(@RequestBody List<LabInputmdlDetail> labInputmdlDetailList){
return labInputmdlService.deleteDetail(labInputmdlDetailList); return labInputmdlService.deleteDetail(labInputmdlDetailList);
} }

View File

@ -4,11 +4,17 @@ import com.czlis.common.core.domain.entity.lis.XmReqitemVsReportitem;
import org.apache.ibatis.annotations.Param; import org.apache.ibatis.annotations.Param;
import java.util.List; import java.util.List;
import java.util.Map;
import java.util.Objects;
public interface XmReqitemVsReportitemMapper { public interface XmReqitemVsReportitemMapper {
List<XmReqitemVsReportitem> query(XmReqitemVsReportitem xmReqitemVsReportitem); List<XmReqitemVsReportitem> query(XmReqitemVsReportitem xmReqitemVsReportitem);
void add(XmReqitemVsReportitem xmReqitemVsReportitem); void add(XmReqitemVsReportitem xmReqitemVsReportitem);
void delete(@Param("sqxmdh") String sqxmdh,@Param("yq") String yq,@Param("xmdh") String xmdh,@Param("tdh") String tdh); void delete(@Param("sqxmdh") String sqxmdh,@Param("yq") String yq,@Param("xmdh") String xmdh,@Param("seq") String seq);
void update(XmReqitemVsReportitem xmReqitemVsReportitem); void update(XmReqitemVsReportitem xmReqitemVsReportitem);
XmReqitemVsReportitem queryOne(XmReqitemVsReportitem xmReqitemVsReportitem);
List<Map<String, Object>> queryList(XmReqitemVsReportitem xmReqitemVsReportitem);
String getSqxmdhOne(String yq);
void searchXmdh(String yq);
} }

View File

@ -0,0 +1,14 @@
package com.czlis.liswork.service;
import com.czlis.common.core.domain.Result;
import com.czlis.common.core.domain.entity.lis.LabCheckrules;
import java.util.List;
public interface LabCheckrulesService {
Result queryList(LabCheckrules labCheckrules);
Result update(List<LabCheckrules> labCheckrulesList);
Result delete(int id);
}

View File

@ -10,7 +10,7 @@ import java.util.List;
public interface LabInputmdlService { public interface LabInputmdlService {
Result query(LabInputmdl labInputmdl); Result query(LabInputmdl labInputmdl);
Result queryDetail(LabInputmdl labInputmdl); Result queryDetail(LabInputmdlDetail labInputmdlDetail);
Result add(LabInputmdlDTO labInputmdlDTO); Result add(LabInputmdlDTO labInputmdlDTO);

View File

@ -0,0 +1,8 @@
package com.czlis.liswork.service;
import com.czlis.common.core.domain.Result;
import com.czlis.common.core.domain.entity.lis.XmInfo;
public interface XmInfoService {
Result query(XmInfo xmInfo);
}

View File

@ -7,7 +7,11 @@ import java.util.List;
public interface XmReqitemVsReportitemService { public interface XmReqitemVsReportitemService {
List<XmReqitemVsReportitem> query(XmReqitemVsReportitem xmReqitemVsReportitem); List<XmReqitemVsReportitem> query(XmReqitemVsReportitem xmReqitemVsReportitem);
Result add(XmReqitemVsReportitem xmReqitemVsReportitem); Result add(List<XmReqitemVsReportitem> xmReqitemVsReportitem);
Result delete(String sqxmdh, String yq, String xmdh, String tdh); Result delete(String sqxmdh, String yq, String xmdh, String seq);
Result update(XmReqitemVsReportitem xmReqitemVsReportitem); Result update(XmReqitemVsReportitem xmReqitemVsReportitem);
Result queryList(XmReqitemVsReportitem xmReqitemVsReportitem);
Result searchXmdh(String yq);
} }

View File

@ -0,0 +1,27 @@
package com.czlis.liswork.service.impl;
import com.czlis.common.core.domain.Result;
import com.czlis.common.core.domain.entity.lis.XmInfo;
import com.czlis.interfaceCommon.mapper.XmInfoMapper;
import com.czlis.liswork.service.XmInfoService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.List;
@Service
@Slf4j
public class XmInfoServiceImpl implements XmInfoService {
@Autowired
XmInfoMapper xmInfoMapper;
@Override
public Result query(XmInfo xmInfo) {
if(xmInfo == null) return new Result("-1","入参不能为空");
if(xmInfo.getYq() == null || xmInfo.getYq().equals("")) return new Result("-1","入参yq不能为空!");
List<XmInfo> xmInfoList = xmInfoMapper.getXmInfoList(xmInfo.getYq());
return new Result("0","获取数据成功!",xmInfoList);
}
}

View File

@ -10,6 +10,9 @@ import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional; import org.springframework.transaction.annotation.Transactional;
import java.util.List; import java.util.List;
import java.util.Map;
import java.util.Objects;
import java.util.stream.Collectors;
@Service @Service
@Slf4j @Slf4j
@ -25,15 +28,24 @@ public class XmReqitemVsReportitemImpl implements XmReqitemVsReportitemService {
@Transactional(rollbackFor = Exception.class) @Transactional(rollbackFor = Exception.class)
@Override @Override
public Result add(XmReqitemVsReportitem xmReqitemVsReportitem) { public Result add(List<XmReqitemVsReportitem> xmReqitemVsReportitemList) {
for (XmReqitemVsReportitem xmReqitemVsReportitem : xmReqitemVsReportitemList) {
if(xmReqitemVsReportitem.getSeq() == null || xmReqitemVsReportitem.getSeq().equals("")) return new Result("-1","序号不能为空!");
XmReqitemVsReportitem xmReqitemVsReportitem1 = xmReqitemVsReportitemMapper.queryOne(xmReqitemVsReportitem);
if(xmReqitemVsReportitem1 != null){
xmReqitemVsReportitemMapper.update(xmReqitemVsReportitem);
}else {
xmReqitemVsReportitemMapper.add(xmReqitemVsReportitem); xmReqitemVsReportitemMapper.add(xmReqitemVsReportitem);
}
}
return new Result("0","添加项目成功!"); return new Result("0","添加项目成功!");
} }
@Transactional(rollbackFor = Exception.class) @Transactional(rollbackFor = Exception.class)
@Override @Override
public Result delete(String sqxmdh, String yq, String xmdh, String tdh) { public Result delete(String sqxmdh, String yq, String xmdh, String seq) {
xmReqitemVsReportitemMapper.delete(sqxmdh,yq,xmdh,tdh); xmReqitemVsReportitemMapper.delete(sqxmdh,yq,xmdh,seq);
return new Result("0","删除项目成功!"); return new Result("0","删除项目成功!");
} }
@ -43,4 +55,26 @@ public class XmReqitemVsReportitemImpl implements XmReqitemVsReportitemService {
xmReqitemVsReportitemMapper.update(xmReqitemVsReportitem); xmReqitemVsReportitemMapper.update(xmReqitemVsReportitem);
return new Result("0","修改项目成功!"); return new Result("0","修改项目成功!");
} }
@Override
public Result queryList(XmReqitemVsReportitem xmReqitemVsReportitem) {
List<Map<String, Object>> xmReqitemVsReportitemList = xmReqitemVsReportitemMapper.queryList(xmReqitemVsReportitem);
if(xmReqitemVsReportitem.getSl() != null ){
//过滤数据,只看仪器对照收费项目
if(xmReqitemVsReportitem.getSl().equals("1")){
List<Map<String, Object>> collect = xmReqitemVsReportitemList.stream().filter(item -> item.get("sl").toString().equals("1")).collect(Collectors.toList());
return new Result("0","获取数据成功!",collect);
}
}
return new Result("0","获取数据成功!",xmReqitemVsReportitemList);
}
@Override
public Result searchXmdh(String yq) {
String sqxmdhOne = xmReqitemVsReportitemMapper.getSqxmdhOne(yq);
if(sqxmdhOne != null && !sqxmdhOne.equals("")) return new Result("-1","有重复对应收费"+sqxmdhOne);
xmReqitemVsReportitemMapper.searchXmdh(yq);
return new Result("0","搜索项目成功!");
}
} }

View File

@ -0,0 +1,47 @@
package com.czlis.liswork.service.impl.xtwh;
import com.czlis.common.core.domain.Result;
import com.czlis.common.core.domain.entity.lis.LabCheckrules;
import com.czlis.interfaceCommon.mapper.LabCheckrulesMapper;
import com.czlis.liswork.service.LabCheckrulesService;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.List;
/**
* 高级审核条件
*/
@Service
@Slf4j
public class LabCheckrulesServiceImpl implements LabCheckrulesService {
@Autowired
private LabCheckrulesMapper labCheckrulesMapper;
@Override
public Result queryList(LabCheckrules labCheckrules) {
List<LabCheckrules> labCheckrulesList = labCheckrulesMapper.query(labCheckrules);
return new Result("0","获取数据成功!",labCheckrulesList);
}
@Override
public Result update(List<LabCheckrules> labCheckrulesList) {
for (LabCheckrules labCheckrules : labCheckrulesList) {
LabCheckrules labCheckrules1 = new LabCheckrules();
if(labCheckrules.getRuleid() == null){
labCheckrulesMapper.insert(labCheckrules);
}else{
labCheckrulesMapper.update(labCheckrules);
}
}
return new Result("0","保存数据成功!");
}
@Override
public Result delete(int id) {
labCheckrulesMapper.delete(id);
return new Result("0","删除成功!");
}
}

View File

@ -26,8 +26,8 @@ public class LabInputmdlServiceImpl implements LabInputmdlService {
} }
@Override @Override
public Result queryDetail(LabInputmdl labInputmdl) { public Result queryDetail(LabInputmdlDetail labInputmdlDetail) {
List<LabInputmdlDetail> labInputmdlDetailList = labInputmdlMapper.queryDetail(labInputmdl); List<LabInputmdlDetail> labInputmdlDetailList = labInputmdlMapper.queryDetail(labInputmdlDetail);
return new Result("0","查询成功!",labInputmdlDetailList); return new Result("0","查询成功!",labInputmdlDetailList);
} }
@ -46,7 +46,13 @@ public class LabInputmdlServiceImpl implements LabInputmdlService {
labInputmdlMapper.update(labInputmdlDTO.getLabInputmdl()); labInputmdlMapper.update(labInputmdlDTO.getLabInputmdl());
List<LabInputmdlDetail> labInputmdlDetailList = labInputmdlDTO.getLabInputmdlDetailList(); List<LabInputmdlDetail> labInputmdlDetailList = labInputmdlDTO.getLabInputmdlDetailList();
for (LabInputmdlDetail labInputmdlDetail : labInputmdlDetailList) { for (LabInputmdlDetail labInputmdlDetail : labInputmdlDetailList) {
List<LabInputmdlDetail> labInputmdlDetailList1 = labInputmdlMapper.queryDetail(labInputmdlDetail);
if(labInputmdlDetailList1.size() > 0){
labInputmdlMapper.updateDetail(labInputmdlDetail); labInputmdlMapper.updateDetail(labInputmdlDetail);
}else{
labInputmdlMapper.addDetail(labInputmdlDetail);
}
} }
return new Result("0","修改数据成功!"); return new Result("0","修改数据成功!");
} }
@ -66,6 +72,7 @@ public class LabInputmdlServiceImpl implements LabInputmdlService {
@Override @Override
public Result deleteDetail(List<LabInputmdlDetail> labInputmdlDetailList) { public Result deleteDetail(List<LabInputmdlDetail> labInputmdlDetailList) {
for (LabInputmdlDetail labInputmdlDetail : labInputmdlDetailList) { for (LabInputmdlDetail labInputmdlDetail : labInputmdlDetailList) {
if(labInputmdlDetail.getXh() == null) return new Result("-1","序号不能为空!");
labInputmdlMapper.deleteDetail(labInputmdlDetail); labInputmdlMapper.deleteDetail(labInputmdlDetail);
} }
return new Result("0","删除明细成功!"); return new Result("0","删除明细成功!");

View File

@ -4,16 +4,17 @@
<mapper namespace="com.czlis.liswork.mapper.dict.XmReqitemVsReportitemMapper"> <mapper namespace="com.czlis.liswork.mapper.dict.XmReqitemVsReportitemMapper">
<select id="query" resultType="com.czlis.common.core.domain.entity.lis.XmReqitemVsReportitem"> <select id="query" resultType="com.czlis.common.core.domain.entity.lis.XmReqitemVsReportitem">
select * from xm_reqitem_vs_reportitem select a.*,b.xmmc from xm_reqitem_vs_reportitem a, xm_info b
<where> <where>
<if test="sqxmdh != null and sqxmdh != ''">and sqxmdh = #{sqxmdh}</if> a.yq = b.yq and a.xmdh = b.xmdh
<if test="sqxmmc != null and sqxmmc != ''"> and sqxmmc = #{sqxmmc}</if> <if test="sqxmdh != null and sqxmdh != ''">and a.sqxmdh = #{sqxmdh}</if>
<if test="yq != null and yq != ''">and yq = #{yq}</if> <if test="sqxmmc != null and sqxmmc != ''"> and a.sqxmmc like '%'+#{sqxmmc}+'%' </if>
<if test="xmdh != null and xmdh != ''"> and xmdh = #{xmdh}</if> <if test="yq != null and yq != ''">and a.yq = #{yq}</if>
<if test="seq != null"> and seq = #{seq}</if> <if test="xmdh != null and xmdh != ''"> and a.xmdh = #{xmdh}</if>
<if test="tdh != null and tdh != ''"> and tdh = #{tdh}</if> <if test="seq != null"> and a.seq = #{seq}</if>
<if test="mrz != null and mrz != ''"> and mrz = #{mrz}</if> <if test="tdh != null and tdh != ''"> and a.tdh = #{tdh}</if>
<if test="def != null and def != ''"> and def = #{def}</if> <if test="mrz != null and mrz != ''"> and a.mrz = #{mrz}</if>
<if test="def != null and def != ''"> and a.def = #{def}</if>
</where> </where>
</select> </select>
@ -54,8 +55,29 @@
<delete id="delete"> <delete id="delete">
delete from xm_reqitem_vs_reportitem where sqxmdh = #{sqxmdh} and yq = #{yq} and xmdh = #{xmdh} delete from xm_reqitem_vs_reportitem where sqxmdh = #{sqxmdh} and yq = #{yq} and xmdh = #{xmdh}
<if test="tdh != null and tdh != ''">and tdh = #{tdh}</if> <if test="seq != null and seq != ''">and seq = #{seq}</if>
</delete> </delete>
<select id="queryList">
SELECT DISTINCT xm_reqitem_vs_reportitem.sqxmdh , xm_reqitem_vs_reportitem.sqxmmc , '' as zjf, (SELECT count(*) FROM xm_feeinstr WHERE xm_feeinstr.yq = xm_reqitem_vs_reportitem.yq and xm_feeinstr.sfxmdh=xm_reqitem_vs_reportitem.sqxmdh) as sl
FROM xm_reqitem_vs_reportitem WHERE ( xm_reqitem_vs_reportitem.yq = #{yq} )
<if test="sqxmmc != null and sqxmmc != ''"> and sqxmmc like '%'+#{sqxmmc}+'%'</if>
</select>
<select id="queryOne" resultType="com.czlis.common.core.domain.entity.lis.XmReqitemVsReportitem">
select * from xm_reqitem_vs_reportitem where sqxmdh = #{sqxmdh} and sqxmmc = #{sqxmmc} and yq = #{yq} and xmdh = #{xmdh}
</select>
<select id="getSqxmdhOne" resultType="string">
select top 1 sqxmdh
from (select sqxmdh,xmdh,COUNT(1) sl from xm_reqitem_vs_reportitem where yq=#{yq} group by sqxmdh,xmdh) x where sl>1
</select>
<update id="searchXmdh">
<![CDATA[
update a set a.sqxmmc=b.sfxmmc
from xm_reqitem_vs_reportitem a,xm_fee b where a.sqxmdh=b.sfxmdh and a.yq=#{yq} and a.sqxmmc<>b.sfxmmc ]]>
</update>
</mapper> </mapper>

View File

@ -6,9 +6,11 @@ import cn.hutool.core.util.StrUtil;
import com.czlis.common.config.RuoYiConfig; import com.czlis.common.config.RuoYiConfig;
import com.czlis.common.core.domain.Result; import com.czlis.common.core.domain.Result;
import com.czlis.common.core.domain.entity.lis.LabPat; import com.czlis.common.core.domain.entity.lis.LabPat;
import com.czlis.common.core.domain.entity.lis.LabPatInfo;
import com.czlis.common.core.domain.entity.lis.LabReqreportPdffile; import com.czlis.common.core.domain.entity.lis.LabReqreportPdffile;
import com.czlis.common.utils.file.FileUtils; import com.czlis.common.utils.file.FileUtils;
import com.czlis.common.utils.uuid.UUID; import com.czlis.common.utils.uuid.UUID;
import com.czlis.interfaceCommon.mapper.LabPatInfoMapper;
import com.czlis.interfaceCommon.utils.CommonUtil; import com.czlis.interfaceCommon.utils.CommonUtil;
import com.czlis.interfaceCommon.utils.LisUtil; import com.czlis.interfaceCommon.utils.LisUtil;
import com.czlis.interfaceCommon.utils.PdfPaperConverter; import com.czlis.interfaceCommon.utils.PdfPaperConverter;
@ -39,6 +41,8 @@ public class ZybgcxServcieImpl implements ZybgcxService {
private CommonUtil commonUtil; private CommonUtil commonUtil;
@Autowired @Autowired
ReportUtil reportUtil; ReportUtil reportUtil;
@Autowired
private LabPatInfoMapper labPatInfoMapper;
/** /**
* 获取报告信息 * 获取报告信息
@ -200,6 +204,12 @@ public class ZybgcxServcieImpl implements ZybgcxService {
return new Result("-1",e.getMessage()); return new Result("-1",e.getMessage());
} }
//修改打印标志
for (String string : bgdh) {
updatePrintStatus(string);
}
return new Result("0","打印成功!",encode); return new Result("0","打印成功!",encode);
} }
@ -267,5 +277,60 @@ public class ZybgcxServcieImpl implements ZybgcxService {
} }
public Result updatePrintStatus(String printId){
log.info("打印状态修改入参:"+printId);
String[] strings = StrUtil.splitToArray(printId, "_");
Date jyrq = DateUtil.parse(strings[0],"yyyyMMdd");
String yq = strings[1];
String ybh = strings[2];
LabPat labPatOne = commonUtil.getLabPatOne(jyrq, yq, ybh);
String jgbz = labPatOne.getJgbz();
if(!jgbz.equals("2")) return new Result("-1","报告还没有审核,不允许打印!");
LabPat labPat = new LabPat();
labPat.setDybz("1");
labPat.setJyrq(jyrq);
labPat.setYq(yq);
labPat.setYbh(ybh);
//labPat.setDysj(commonUtil.currentDateTime());
try{
LabPatInfo lab_patinfoOne = getLab_patinfoOne(jyrq, yq, ybh);
if(lab_patinfoOne == null){
LabPatInfo lab_patinfo = new LabPatInfo();
lab_patinfo.setJyrq(jyrq);
lab_patinfo.setYq(yq);
lab_patinfo.setYbh(ybh);
lab_patinfo.setXxlb("AUTOP_NEW");
lab_patinfo.setVal1("最后一次的打印时间:"+DateUtil.format(commonUtil.getCurrentTime(),"yyyy-MM-dd HH:mm:ss"));
lab_patinfo.setVal2("1");
labPatInfoMapper.insert(lab_patinfo);
}else{
LabPatInfo labPatinfo = new LabPatInfo();
labPatinfo.setVal1("最后一次的打印时间:"+DateUtil.format(commonUtil.getCurrentTime(),"yyyy-MM-dd HH:mm:ss"));
labPatinfo.setVal2("1");
labPatinfo.setJyrq(jyrq);
labPatinfo.setYq(yq);
labPatinfo.setYbh(ybh);
labPatinfo.setXxlb("AUTOP_NEW");
labPatInfoMapper.update(labPatinfo);
}
commonUtil.updateLabPat(labPat);
}catch (Exception e){
log.info("id:"+printId+",修改打印状态失败:",e);
return new Result("-1","修改打印状态失败:"+e.getMessage());
}
log.info("printID:"+printId+"修改打印状态成功!");
return new Result("0","修改打印状态成功!");
}
public LabPatInfo getLab_patinfoOne(Date jyrq,String yq,String ybh){
LabPatInfo labPatInfo = new LabPatInfo();
labPatInfo.setJyrq(jyrq);
labPatInfo.setYq(yq);
labPatInfo.setYbh(ybh);
labPatInfo.setXxlb("AUTOP_NEW");
return labPatInfoMapper.selectLabPatInfoOne(labPatInfo);
}
} }