报告模板菜单

This commit is contained in:
tangw 2025-12-30 15:42:35 +08:00
parent a605ec1f8e
commit b3229c0e7d
5 changed files with 26 additions and 24 deletions

View File

@ -16,9 +16,9 @@ public class ComReportInstr {
private Long reportBgdh; private Long reportBgdh;
private String reportSize; private String reportSize;
private String reportType; private String reportType;
private Long reportRows; private Integer reportRows;
private Long reportMinrows; private Integer reportMinrows;
private Long reportMaxrows; private Integer reportMaxrows;
private String reportItems; private String reportItems;
private Long reportSort; private Long reportSort;
private String status; private String status;

View File

@ -9,8 +9,8 @@ import java.util.List;
public interface LabReportvsitemMapper { public interface LabReportvsitemMapper {
int getLabReportvsitemCount(@Param("jyrq") Date jyrq, @Param("yq")String yq, @Param("ybh")String ybh); int getLabReportvsitemCount(@Param("jyrq") Date jyrq, @Param("yq")String yq, @Param("ybh")String ybh);
int getLabReport2(@Param("jyrq") Date jyrq, @Param("yq")String yq, @Param("ybh")String ybh); int getLabReport2(@Param("jyrq") Date jyrq, @Param("yq")String yq, @Param("ybh")String ybh);
int getLabReportCount(@Param("jyrq") Date jyrq, @Param("yq")String yq, @Param("ybh")String ybh); Integer getLabReportCount(@Param("jyrq") Date jyrq, @Param("yq")String yq, @Param("ybh")String ybh);
int getLabReportCountwithitem(@Param("jyrq") Date jyrq, @Param("yq")String yq, @Param("ybh")String ybh,@Param("items")List<String> items); Integer getLabReportCountwithitem(@Param("jyrq") Date jyrq, @Param("yq")String yq, @Param("ybh")String ybh,@Param("items")List<String> items);
List<ComReportInstr> getComReportInstrByInstr(String reportYq); List<ComReportInstr> getComReportInstrByInstr(String reportYq);
String getreportCode(Long reportBgdh); String getreportCode(Long reportBgdh);
} }

View File

@ -22,7 +22,8 @@ public class ReportParam {
private String yq; private String yq;
private String ybh; private String ybh;
private String hospitalName; private String hospitalName;
private Long ReportId; private Integer resultRows;
private Integer reportRows;
/**结果图片数组*/private String[] pic; /**结果图片数组*/private String[] pic;
/**检验医生签名*/private String usernopic; /**检验医生签名*/private String usernopic;
/**审核医生签名*/private String checkerpic; /**审核医生签名*/private String checkerpic;

View File

@ -364,7 +364,10 @@ public class ReportUtil {
if(comReportInstr.getReportId()==null) { if(comReportInstr.getReportId()==null) {
return new Result("-1","未找到打印模板,请检查报告单设置"); return new Result("-1","未找到打印模板,请检查报告单设置");
} }
reportParam.setReportId(comReportInstr.getReportId()); reportParam.setReportRows(comReportInstr.getReportRows());
Integer count=labReportvsitemMapper.getLabReportCount(jyrq,yq,ybh);
if(count==null) {count=0;}
reportParam.setResultRows(count);
String filename=labReportvsitemMapper.getreportCode(comReportInstr.getReportBgdh()); String filename=labReportvsitemMapper.getreportCode(comReportInstr.getReportBgdh());
return printToPdf(filename, reportParam, UUID.randomUUID().toString(), true); return printToPdf(filename, reportParam, UUID.randomUUID().toString(), true);
@ -394,8 +397,8 @@ public class ReportUtil {
} }
int rows=labReportvsitemMapper.getLabReportCount(jyrq,yq,ybh); int rows=labReportvsitemMapper.getLabReportCount(jyrq,yq,ybh);
for (ComReportInstr comReportInstr : info) { for (ComReportInstr comReportInstr : info) {
Long minrows=comReportInstr.getReportMinrows(); Integer minrows=comReportInstr.getReportMinrows();
Long maxrows=comReportInstr.getReportMaxrows(); Integer maxrows=comReportInstr.getReportMaxrows();
if(minrows!=null&&minrows>0){ if(minrows!=null&&minrows>0){
if(rows<minrows){continue;} if(rows<minrows){continue;}
} }

View File

@ -117,21 +117,19 @@
<update id="updateComReportInstr" parameterType="com.czlis.common.core.domain.entity.lis.ComReportInstr"> <update id="updateComReportInstr" parameterType="com.czlis.common.core.domain.entity.lis.ComReportInstr">
update com_report_instr update com_report_instr
<set> set report_type = #{reportType},
<if test="reportType != null and reportType != ''">report_type = #{reportType},</if> report_yq = #{reportYq},
<if test="reportYq != null and reportYq != ''">report_yq = #{reportYq},</if> report_bgdh = #{reportBgdh},
<if test="reportBgdh != null and reportBgdh != 0">report_bgdh = #{reportBgdh},</if> report_size = #{reportSize},
<if test="reportSize != null and reportSize != ''">report_size = #{reportSize},</if> report_rows = #{reportRows},
<if test="reportRows != null and reportRows != 0">report_rows = #{reportRows},</if> report_minrows = #{reportMinrows},
<if test="reportMinrows != null and reportMinrows != 0">report_minrows = #{reportMinrows},</if> report_maxrows = #{reportMaxrows},
<if test="reportMaxrows != null and reportMaxrows != 0">report_maxrows = #{reportMaxrows},</if> report_items = #{reportItems},
<if test="reportItems != null and reportItems != ''">report_items = #{reportItems},</if> report_sort = #{reportSort},
<if test="reportSort != null">report_sort = #{reportSort},</if> status = #{status},
<if test="status != null and status != ''">status = #{status},</if> remark = #{remark},
<if test="remark != null">remark = #{remark},</if> update_by = #{updateBy},
<if test="updateBy != null and updateBy != ''">update_by = #{updateBy},</if>
update_time = getdate() update_time = getdate()
</set>
where report_id = #{reportId} where report_id = #{reportId}
</update> </update>