优化2.0标准版代码

master
Godblessyou 10 months ago
parent 0838f38c7e
commit e54b90a930

@ -24,7 +24,7 @@
<mybatis.spring.version>1.3.2</mybatis.spring.version>
<mybatis.version>3.5.7</mybatis.version>
<mssql.version>7.4.1.jre8</mssql.version>
<mysql.version>5.1.32</mysql.version>
<mysql.version>8.0.33</mysql.version>
<druid.version>1.1.22</druid.version>
<shiro.version>1.2.5</shiro.version>
<log4j2.version>2.15.0</log4j2.version>

@ -1,14 +1,12 @@
package com.emr.controller.bloodPurification;
import com.alibaba.fastjson.JSON;
import com.emr.annotation.DBSource;
import com.emr.annotation.OptionalLog;
import com.emr.dao.CommomMapper;
import com.emr.dao.bloodPurification.BloodPurificationMapper;
import com.emr.dao.emrLog.Emr_LogMapper;
import com.emr.entity.EmrBloodApplyInfo;
import com.emr.entity.EmrBloodDialysisDoc;
import com.emr.entity.Power_User;
import com.emr.entity.ResultUtil;
import com.emr.entity.*;
import com.emr.service.ImportExcel.ImportExcelEntity;
import com.emr.service.ImportExcel.ImportExcelUtil;
import com.emr.service.bloodPurification.BloodPurificationService;
@ -27,15 +25,23 @@ import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.util.CollectionUtils;
import org.springframework.util.ObjectUtils;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.ResponseBody;
import org.springframework.util.StreamUtils;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile;
import org.springframework.web.multipart.MultipartHttpServletRequest;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import javax.servlet.http.HttpSession;
import java.io.IOException;
import java.io.InputStream;
import java.io.OutputStream;
import java.net.*;
import java.nio.charset.Charset;
import java.nio.charset.StandardCharsets;
import java.nio.file.Files;
import java.nio.file.Path;
import java.nio.file.Paths;
import java.text.DecimalFormat;
import java.time.YearMonth;
import java.time.format.DateTimeFormatter;
@ -48,6 +54,10 @@ import java.util.stream.Collectors;
@Controller
@RequestMapping("bloodPurification/")
public class bloodPurificationController {
// 文件服务器地址
private static final String FILE_SERVER_URL = "http://192.168.2.22:9001";
@Autowired
private CommomMapper commomMapper;
@Autowired
@ -154,6 +164,21 @@ public class bloodPurificationController {
return "recordManage/bloodPurification/inspectionRecordsSum";
}
/**
*
*
* @param model
* @param request
* @return
*/
@RequiresPermissions("/bloodPurification/informedConsentForm")
@OptionalLog(module = "查看", methods = "知情同意书查询")
@RequestMapping("informedConsentForm")
public String informedConsentForm(Model model, HttpServletRequest request) {
return "recordManage/bloodPurification/informedConsentForm";
}
/**
*
* @return
@ -605,6 +630,32 @@ public class bloodPurificationController {
}
}
/**
*
* @param page
* @param limit
* @param vmPatFormedDoc
* @param request
* @return
*/
@DBSource("salve")
@RequestMapping("queryInformedConsentForm")
@ResponseBody
public String queryInformedConsentForm(Integer page, Integer limit, VmPatFormedDoc vmPatFormedDoc, HttpServletRequest request){
if(null != page && null != limit){
PageHelper.startPage(page, limit);
}
try{
List<VmPatFormedDoc> vmPatFormedDocList = bloodPurificationMapper.queryInformedConsentForm(vmPatFormedDoc);
PageInfo pageInfo = new PageInfo<>(vmPatFormedDocList);
return JSON.toJSONString(pageInfo);
}catch (Exception e){
ExceptionPrintUtil.printException(e);
e.printStackTrace();
return null;
}
}
/**
*
* @param page
@ -856,4 +907,89 @@ public class bloodPurificationController {
return ResultUtil.error("流程处理出错");
}
}
@GetMapping("/downloadSecureFile")
public void downloadSecureFile(@RequestParam String path, @RequestParam String filename, HttpServletResponse response) throws IOException {
// 处理路径编码问题
String baseUrl = FILE_SERVER_URL;
// 分割路径并逐个编码
String[] segments = path.split("/");
StringBuilder safePath = new StringBuilder();
for (String segment : segments) {
if (!segment.isEmpty()) {
safePath.append("/").append(URLEncoder.encode(segment, StandardCharsets.UTF_8.name()));
}
}
String fullPath = baseUrl + safePath;
// UNC 路径检查
if (path.startsWith("\\") || path.contains("\\")) {
response.sendError(HttpServletResponse.SC_BAD_REQUEST, "UNC 路径不支持,请使用 HTTP/SMB 访问远程文件");
return;
}
// 创建连接
URL url = new URL(fullPath);
URLConnection connection = url.openConnection();
connection.setConnectTimeout(10000);
connection.setReadTimeout(30000);
try (InputStream inputStream = connection.getInputStream()) {
response.setContentType("application/octet-stream");
// 提取文件名
String finalFilename = extractFileName(path);
if (!ObjectUtils.isEmpty(filename)) {
String fileExtension = "";
int dotIndex = finalFilename.lastIndexOf(".");
if (dotIndex > 0) {
fileExtension = finalFilename.substring(dotIndex);
}
if (filename.contains(".")) {
filename = filename.substring(0, filename.lastIndexOf("."));
}
finalFilename = filename + fileExtension;
}
String encodedFilename = URLEncoder.encode(finalFilename, "UTF-8");
response.setHeader(HttpHeaders.CONTENT_DISPOSITION,
"attachment; filename*=UTF-8''" + encodedFilename);
long contentLength = connection.getContentLengthLong();
if (contentLength > 0) {
response.setContentLengthLong(contentLength);
}
try (OutputStream out = response.getOutputStream()) {
byte[] buffer = new byte[10 * 1024];
int bytesRead;
while ((bytesRead = inputStream.read(buffer)) != -1) {
out.write(buffer, 0, bytesRead);
}
}
} catch (IOException e) {
e.printStackTrace();
response.sendError(HttpServletResponse.SC_NOT_FOUND, "File not found or access denied");
}
}
/**
*
* /upload/2024/05/12/report.pdf => report.pdf
*/
private String extractFileName(String path) {
// 兼容 / 和 \
int lastUnixSlash = path.lastIndexOf('/');
int lastWinSlash = path.lastIndexOf('\\');
int lastSlashIndex = Math.max(lastUnixSlash, lastWinSlash);
if (lastSlashIndex != -1 && lastSlashIndex < path.length() - 1) {
return path.substring(lastSlashIndex + 1);
}
return "file.dat";
}
}

@ -327,10 +327,6 @@ public class CommomSearchController {
}
/***
*
* @param request
@ -1166,6 +1162,7 @@ public class CommomSearchController {
@RequestMapping(value = "getRecordContentBlood")
@ResponseBody
public void getRecordContentBlood(String patientId, HttpServletRequest request, HttpServletResponse response) {
Map<String, Object> cacheMap = commomService.CACHE_MAP;
List<CommomTree> commomTrees = archiveDetailMapper.selectPdfPathByPatient2(patientId);
Power_User user;
Object currentUser = request.getSession().getAttribute("CURRENT_USER");
@ -1179,7 +1176,7 @@ public class CommomSearchController {
if (commomTrees.size() == 0) {
try {
String mapKey = user.getUserName() + "_" + patientId;
List<String> scanPages = (List<String>) request.getSession().getAttribute(mapKey);
List<String> scanPages = (List<String>) cacheMap.get(mapKey);
if (!CollectionUtils.isEmpty(scanPages)) {
String pdfName = "档案管理PDF";
//根据图片路径转换pdf
@ -1195,7 +1192,7 @@ public class CommomSearchController {
img2PdfUtil.imageToPdfUserEffective(response, scanPages, pdfName, emrPdfWaterSet);
}
//移除缓存
request.removeAttribute(mapKey);
commomService.CACHE_MAP.clear();
}
} catch (Exception e) {
ExceptionPrintUtil.printException(e);
@ -1204,14 +1201,14 @@ public class CommomSearchController {
} else {
String pdfWater = "";
String mapKey = user.getUserName() + "_" + patientId;
List<String> filePaths = (List<String>) request.getSession().getAttribute(mapKey);
List<String> filePaths = (List<String>) cacheMap.get(mapKey);
if (!CollectionUtils.isEmpty(filePaths)) {
//根据图片路径转换pdf
EmrPdfWaterSet emrPdfWaterSet = pdfWaterSetMapper.selectByPrimaryKey(1);
//定义第二文本水印 姓名 + 科室 + ip
Jpg2PdfUtil.mulFile2One2(response, filePaths, pdfWater,emrPdfWaterSet);
//移除缓存
request.removeAttribute(mapKey);
commomService.CACHE_MAP.clear();
}
}
}

@ -1702,7 +1702,7 @@ public class TemplateSearchController {
//批量添加打印记录
printOrDownLoadInfoService.SimpleInsert(scanPathVos, typeId, Short.valueOf("1"));
//调用湘雅附二病历复印打印状态同步接口
//this.MedicalPrintSyncPrintStatusAction(patientIds , printDate);
this.MedicalPrintSyncPrintStatusAction(patientIds , printDate);
}
} catch (Exception e) {
ExceptionPrintUtil.printException(e);
@ -1719,7 +1719,7 @@ public class TemplateSearchController {
JAXDynamicClientFactory dcf = JAXDynamicClientFactory.newInstance();
//创建客户端
Object[] objects;
Client client = dcf.createClient("http://172.16.198.250:13023/dev/openapi/health");
Client client = dcf.createClient("http://172.16.198.250:13023/openapi/health");
//合作方密钥
String partnerKey = "53fd4f5ff132528e2e071baeeb3f99a2";

@ -2,6 +2,7 @@ package com.emr.dao.bloodPurification;
import com.emr.entity.EmrBloodApplyInfo;
import com.emr.entity.EmrBloodDialysisDoc;
import com.emr.entity.VmPatFormedDoc;
import com.emr.entity.emrLog.Emr_Log;
import java.util.List;
@ -36,4 +37,6 @@ public interface BloodPurificationMapper{
List<Map<String, Object>> queryDocumentSum(Map<String,Object> params);
List<Emr_Log> selectAll(Emr_Log log, String startTime, String endTime);
List<VmPatFormedDoc> queryInformedConsentForm(VmPatFormedDoc vmPatFormedDoc);
}

@ -15,6 +15,7 @@ import com.emr.service.ImportExcel.ImportExcelEntity;
import com.emr.service.ImportExcel.ImportExcelUtil;
import com.emr.service.tScanAssort.T_Scan_AssortService;
import com.emr.util.Pdf2ImgUtil;
import com.emr.util.ThreadPoolUtil;
import com.emr.util.UploadUtil;
import com.emr.util.img2PdfUtil;
import com.emr.vo.ExportInpVo;
@ -80,6 +81,9 @@ public class CommomService {
@Value("${linuxPath}")
private String linuxPath;
@Value("${httpMapPort}")
private String httpMapPort;
@Autowired
private CommomMapper commomMapper;
@Autowired
@ -94,6 +98,9 @@ public class CommomService {
@Autowired
private Zd_AssortMapper zd_assortMapper;
@Autowired
private ThreadPoolUtil threadPoolUtil; // 注入统一的线程池
public static final Map<String, Object> CACHE_MAP = new ConcurrentHashMap<>();
//获取所属医院用户名集合
@ -320,80 +327,80 @@ public class CommomService {
}
}
}*/
if (StringUtils.isBlank(patientId)) {
return;
}
patientId = patientId.replace("'", "");
if (StringUtils.isBlank(flag)) {
return;
}
// 复制 request 中的关键信息避免线程安全问题request 不能直接跨线程使用)
Power_User user = getCurrentUser(request);
if (user == null) {
return;
}
String finalPatientId = patientId;
String finalFlag = flag;
String finalScanPages = scanPages;
String username = user.getUserName();
CompletableFuture.runAsync(() -> {
try {
CommomVo commomVo = commomMapper.selectByPrimaryKey(finalPatientId);
if (StringUtils.isNotBlank(patientId)) {
patientId = patientId.replace("'", "");
// 查询
if (StringUtils.isNotBlank(flag)) {
CommomVo commomVo = commomMapper.selectByPrimaryKey(patientId);
if (commomVo != null && StringUtils.isNotBlank(commomVo.getFilePath())) {
// flag = home_addr取home_addr字段path_file取home_addr字段
String root1;
if ("home_addr".equals(flag)) {
if ("home_addr".equals(finalFlag)) {
root1 = commomVo.getHomeAddr();
} else if ("file_path".equals(flag)) {
} else if ("file_path".equals(finalFlag)) {
root1 = commomVo.getFilePath();
} else {
root1 = "";
}
// 组织src
ExecutorService executor = Executors.newFixedThreadPool(6); // 创建线程池
String finalPatientId = patientId;
List<String> filePaths = CompletableFuture.supplyAsync(() -> {
List<String> pdfPaths = new LinkedList<>();
String[] scanPageArr = (scanPages != null) ? scanPages.split(",") : new String[0];
for (String scanPage : scanPageArr) {
if (StringUtils.isNotBlank(scanPage)) {
String srcStr = root1 + File.separator + scanPage;
if (StringUtils.isNotBlank(srcStr)) {
File file = new File(srcStr);
if (file.isFile()) {
pdfPaths.add(srcStr);
}
}
List<String> pdfPaths = new LinkedList<>();
String[] scanPageArr = (finalScanPages != null) ? finalScanPages.split(",") : new String[0];
for (String scanPage : scanPageArr) {
if (StringUtils.isNotBlank(scanPage)) {
String srcStr = root1 + File.separator + scanPage;
File file = new File(srcStr);
if (file.isFile()) {
pdfPaths.add(srcStr);
}
}
return pdfPaths;
}, executor).exceptionally(ex -> {
ex.printStackTrace();
return Collections.emptyList(); // 返回空列表
}).join(); // 阻塞等待结果
executor.shutdown(); // 关闭线程池
Power_User user;
Object currentUser = request.getSession().getAttribute("CURRENT_USER");
if(ObjectUtils.isEmpty(currentUser)){
ServletContext context = request.getServletContext();
user = (Power_User)context.getAttribute("CURRENT_USER");
}else{
//查询通过审批且未过期的patientId集合
user = (Power_User) currentUser;
}
if (user != null) {
String mapKey = user.getUserName() + "_" + finalPatientId;
request.getSession().setAttribute(mapKey, filePaths);
if (!pdfPaths.isEmpty()) {
String mapKey = username + "_" + finalPatientId;
CACHE_MAP.put(mapKey, pdfPaths);
}
} else {
List<String> commomTrees = archiveDetailMapper.getPDFRATH(patientId, scanPages);
if (!CollectionUtils.isEmpty(commomTrees) && request != null) {
Power_User user;
Object currentUser = request.getSession().getAttribute("CURRENT_USER");
if(ObjectUtils.isEmpty(currentUser)){
ServletContext context = request.getServletContext();
user = (Power_User)context.getAttribute("CURRENT_USER");
}else{
//查询通过审批且未过期的patientId集合
user = (Power_User) currentUser;
}
if (user != null) {
String mapKey = user.getUserName() + "_" + patientId;
request.getSession().setAttribute(mapKey, commomTrees);
}
List<String> commomTrees = archiveDetailMapper.getPDFRATH(finalPatientId, finalScanPages);
if (!CollectionUtils.isEmpty(commomTrees)) {
String mapKey = username + "_" + finalPatientId;
CACHE_MAP.put(mapKey, commomTrees);
}
}
} catch (Exception e) {
e.printStackTrace();
}
}, threadPoolUtil.getExecutor());
}
private Power_User getCurrentUser(HttpServletRequest request) {
Object currentUser = request.getSession().getAttribute("CURRENT_USER");
if (ObjectUtils.isEmpty(currentUser)) {
ServletContext context = request.getServletContext();
return (Power_User) context.getAttribute("CURRENT_USER");
} else {
return (Power_User) currentUser;
}
}
@ -803,6 +810,55 @@ public class CommomService {
root = selectRootByNotWater(WATERTIFTOJPGPATH);
outSrc = EMRRECORDJSP + File.separator + root + "/jiashi/tifToJpgLoad/" + format1 + ".jpg";
} else {
/*String driveLetterPath = srcPath.replaceAll("\\\\", "/");
if (driveLetterPath.startsWith("/")) {
String imageIpPath = "";//获取srcPath图像路径的ip
String localIP = getLocalIPAddress();//获取本机ip
//截取字符串为磁盘路径
int thirdBackslashIndex = driveLetterPath.indexOf('/', driveLetterPath.indexOf('/', driveLetterPath.indexOf('/') + 1) + 1);
if (thirdBackslashIndex != -1) {
imageIpPath = driveLetterPath.substring(2, thirdBackslashIndex);
driveLetterPath = driveLetterPath.substring(thirdBackslashIndex + 1);
}
//将原图片地址转换成映射地址
//获取盘符并转换映射地址的头部地址
root = selectRootByNotWater(driveLetterPath);
// 判断IP是否一致
if (imageIpPath.equals(localIP)) {
if (root == null) {
if(srcPath.contains(linuxPath)){
srcPath = srcPath.replace(linuxPath, "picShare");
outSrc = EMRRECORDJSP + File.separator + srcPath;
}else{
outSrc = srcPath;
}
} else {
//获取盘符后面的地址
picPath = driveLetterPath.substring(driveLetterPath.indexOf('/'));
outSrc = EMRRECORDJSP + File.separator + root + picPath;
}
} else {
if (root == null) {
if(srcPath.contains(linuxPath)){
srcPath = srcPath.replace(linuxPath, "picShare");
outSrc = EMRRECORDJSP + File.separator + srcPath;
}else{
outSrc = "http://" + imageIpPath + ":" + httpMapPort + File.separator + driveLetterPath;
}
} else {
//获取盘符后面的地址
picPath = driveLetterPath.substring(driveLetterPath.indexOf('/'));
outSrc = "http://" + imageIpPath + ":" + httpMapPort + File.separator + root + picPath;
}
}
} else {
root = selectRootByNotWater(driveLetterPath);
//获取盘符后面的地址
String str1 = driveLetterPath.substring(0, driveLetterPath.indexOf("/"));
picPath = driveLetterPath.substring(str1.length() + 1, driveLetterPath.length());
outSrc = EMRRECORDJSP + File.separator + root + picPath;
}*/
String driveLetterPath = srcPath.replaceAll("\\\\", "/");
if (driveLetterPath.startsWith("/")) {
//截取字符串为磁盘路径
@ -877,6 +933,19 @@ public class CommomService {
return outs;*/
}
/**
* IP
*/
private static String getLocalIPAddress() {
try {
InetAddress inetAddress = InetAddress.getLocalHost();
return inetAddress.getHostAddress();
} catch (UnknownHostException e) {
System.err.println("无法获取本机IP地址: " + e.getMessage());
return null;
}
}
public String processImagePath(String rootPath, String name, String source, Power_User user, EmrPdfWaterSet emrPdfWaterSet, String patientId, String mapKey) throws IOException {
return "processed_" + name; // 示例返回值

@ -53,6 +53,31 @@
<property name="connectionProperties" value="druid.stat.mergeSql=true;druid.stat.slowSqlMillis=5000"/>
</bean>
<!--<bean id="salve" class="com.alibaba.druid.pool.DruidDataSource" destroy-method="close">
<property name="driverClassName" value="${jdbc.driver}"/> &lt;!&ndash;数据库连接驱动&ndash;&gt;
<property name="url" value="${jdbc.url2}"/> &lt;!&ndash;数据库地址&ndash;&gt;
<property name="username" value="${jdbc.username2}"/> &lt;!&ndash;用户名&ndash;&gt;
<property name="password" value="${jdbc.password2}"/> &lt;!&ndash;密码&ndash;&gt;
<property name="initialSize" value="100"/> &lt;!&ndash; 初始化连接池内的数据库连接&ndash;&gt;
<property name="maxActive" value="1000"/>
<property name="maxWait" value="60000"/>
<property name="minEvictableIdleTimeMillis" value="300000"/>
<property name="keepAlive" value="true"/>
<property name="timeBetweenEvictionRunsMillis" value="-1"/>
<property name="minIdle" value="20"/>
<property name="removeAbandoned" value="false"/>
<property name="removeAbandonedTimeout" value="180"/>
<property name="logAbandoned" value="true"/>
<property name="testWhileIdle" value="true"/>
<property name="validationQuery" value="SELECT 'x'"/>
<property name="testOnBorrow" value="false"/>
<property name="testOnReturn" value="false"/>
<property name="poolPreparedStatements" value="true"/>
<property name="maxPoolPreparedStatementPerConnectionSize" value="20"/>
<property name="filters" value="stat,wall,slf4j"/>
<property name="connectionProperties" value="druid.stat.mergeSql=true;druid.stat.slowSqlMillis=5000"/>
</bean>-->
<bean id="salve" class="com.alibaba.druid.pool.DruidDataSource" destroy-method="close">
<property name="driverClassName" value="${jdbc.driver2}"/> <!--数据库连接驱动-->
<property name="url" value="${jdbc.url2}"/> <!--数据库地址-->

@ -34,6 +34,8 @@ waterPicPath = D:/jiashi/reload/
waterTifToJpgPath = D:/jiashi/tifToJpgLoad/
linuxPath = /data
#//????
printPrice = 0.3
@ -44,8 +46,8 @@ applyApproveFlag =0
initialization =0
export_pdf_hospital_info = \u5e7f\u4e1c\u7701\u005f\u6e5b\u6c5f\u5e02\u005f\u9042\u6eaa\u53bf\u4eba\u6c11\u533b\u9662
#\u5e7f\u4e1c\u7701\u005f\u6e5b\u6c5f\u5e02\u005f\u9042\u6eaa\u53bf\u4eba\u6c11\u533b\u9662
#\u5e7f\u4e1c\u7701\u005f\u5e7f\u5dde\u5e02\u5929\u6cb3\u533a\u4eba\u6c11\u533b\u9662
#\u5e7f\u4e1c\u7701\u005f\u6e5b\u6c5f\u5e02\u005f\u9042\u6eaa\u53bf\u4eba\u6c11\u533b\u9662 ??
#\u5e7f\u4e1c\u7701\u005f\u5e7f\u5dde\u5e02\u5929\u6cb3\u533a\u4eba\u6c11\u533b\u9662 ??
export_pdf_patient_info = inpatientNo,disDate
@ -67,5 +69,7 @@ NEW_EMR_RECORD_JSP : http://localhost:8081/emr_record
#\u8D39\u7528\u6E05\u5355\u751F\u6210\u7684\u76EE\u5F55
cost_pdf_path=D://cost//
httpMapPort = 9001

@ -8,9 +8,9 @@ jdbc.username=sa
jdbc.password=123456
#dataSource2
jdbc.driver2=com.mysql.jdbc.Driver
jdbc.url2=jdbc\:mysql\://192.168.2.22\:3306/gyw?useUnicode\=true&characterEncoding\=utf-8
jdbc.url2=jdbc\:mysql\://localhost\:3306/test?useUnicode\=true&characterEncoding\=utf-8
jdbc.username2=root
jdbc.password2=root
#jdbc.url2=jdbc\:sqlserver\://localhost:1433;databaseName=blgd_java
jdbc.password2=123456
#jdbc.url2=jdbc\:sqlserver\://132.147.165.227:1433;databaseName=sws_center_gz
#jdbc.username2=jsuser
#jdbc.password2=123456
#jdbc.password2=Sws@js2025!

@ -563,4 +563,42 @@
</where>
ORDER BY create_date DESC,log_id DESC
</select>
<select id="queryInformedConsentForm" parameterType="com.emr.entity.VmPatFormedDoc" resultType="com.emr.entity.VmPatFormedDoc">
select
Id id,
PatientId patientId,
Name name,
CardNum cardNum,
PatientNo patientNo,
PatientMZNo patientMZNo,
PatientTXNo patientTXNo,
PatientZYNo patientZYNo,
DocumentsName documentsName,
FileName fileName,
FileURL fileURL,
DataState dataState
from
vm_PatFormedDoc
<where>
<if test="name != '' and name != null">
Name LIKE '%${name}%'
</if>
<if test="cardNum != '' and cardNum != null">
AND CardNum LIKE '%${cardNum}%'
</if>
<if test="patientNo != '' and patientNo != null">
AND PatientNo LIKE '%${patientNo}%'
</if>
<if test="patientMZNo != '' and patientMZNo != null">
AND PatientMZNo LIKE '%${patientMZNo}%'
</if>
<if test="patientTXNo != '' and patientTXNo != null">
AND PatientTXNo LIKE '%${patientTXNo}%'
</if>
<if test="patientZYNo != '' and patientZYNo != null">
AND PatientZYNo LIKE '%${patientZYNo}%'
</if>
</where>
</select>
</mapper>

@ -276,7 +276,7 @@
CONVERT(varchar, c.dis_date, 127)+'.000+0000' as outDate,
c.dis_dept disDept,
c.file_path+'\'+t.scan_page as scanFile,
t.assort_id as fdCode,+++ +
t.assort_id as fdCode,
c.patient_id as indexId
FROM
commomtable c

@ -60,7 +60,6 @@
<mvc:resources mapping="/reloadW/**" location="file:W:/" />
<mvc:resources mapping="/picShare/**" location="file:/data/" />
<!-- 当上面要访问的静态资源不包括在上面的配置中时,则根据此配置来访问 -->
<!--配置视图解析器,方便页面返回 -->
<bean id="jspViewResolver"

@ -570,7 +570,7 @@
</div>
<div class="col-sm-9 inputDiv">
<input type="text" class="form-control input-sm diagTable inputValue"
id="attending" maxlength="6">
id="attending" >
</div>
</div>
</div>
@ -581,7 +581,7 @@
</div>
<div class="col-sm-8 inputDiv">
<input type="text" class="form-control input-sm diagTable inputValue"
id="dept_director" maxlength="6">
id="dept_director" >
</div>
</div>
</div>
@ -592,7 +592,7 @@
</div>
<div class="col-sm-9 inputDiv">
<input type="text" class="form-control input-sm diagTable inputValue"
id="director" maxlength="6">
id="director" >
</div>
</div>
</div>
@ -669,7 +669,7 @@
</div>
<div class="col-sm-9 inputDiv">
<input type="text" class="form-control input-sm diagTable inputValue"
id="female_name" maxlength="6">
id="female_name" >
</div>
</div>
</div>
@ -711,7 +711,7 @@
</div>
<div class="col-sm-9 inputDiv">
<input type="text" class="form-control input-sm diagTable inputValue"
id="cycle_type" maxlength="6">
id="cycle_type" >
</div>
</div>
</div>
@ -744,7 +744,7 @@
</div>
<div class="col-sm-9 inputDiv">
<input type="text" class="form-control input-sm diagTable inputValue"
id="pro_no" maxlength="6">
id="pro_no" >
</div>
</div>
</div>
@ -755,7 +755,7 @@
</div>
<div class="col-sm-9 inputDiv">
<input type="text" class="form-control input-sm diagTable inputValue"
id="pro_name" maxlength="6">
id="pro_name">
</div>
</div>
</div>
@ -766,7 +766,7 @@
</div>
<div class="col-sm-9 inputDiv">
<input type="text" class="form-control input-sm diagTable inputValue"
id="applicant" maxlength="6">
id="applicant">
</div>
</div>
</div>
@ -777,7 +777,7 @@
</div>
<div class="col-sm-9 inputDiv">
<input type="text" class="form-control input-sm diagTable inputValue"
id="file_type" maxlength="6">
id="file_type">
</div>
</div>
</div>
@ -788,7 +788,7 @@
</div>
<div class="col-sm-8 inputDiv">
<input type="text" class="form-control input-sm diagTable inputValue"
id="subject_no" maxlength="6">
id="subject_no">
</div>
</div>
</div>
@ -799,7 +799,7 @@
</div>
<div class="col-sm-8 inputDiv">
<input type="text" class="form-control input-sm diagTable inputValue"
id="pro_content" maxlength="6">
id="pro_content">
</div>
</div>
</div>
@ -810,7 +810,7 @@
</div>
<div class="col-sm-8 inputDiv">
<input type="text" class="form-control input-sm diagTable inputValue"
id="application_no" maxlength="6">
id="application_no" >
</div>
</div>
</div>
@ -821,7 +821,7 @@
</div>
<div class="col-sm-8 inputDiv">
<input type="text" class="form-control input-sm diagTable inputValue"
id="acceptance_no" maxlength="6">
id="acceptance_no" >
</div>
</div>
</div>
@ -833,7 +833,7 @@
</div>
<div class="col-sm-9 inputDiv">
<input type="text" class="form-control input-sm diagTable inputValue"
id="hemodialysis_id" maxlength="6">
id="hemodialysis_id" >
</div>
</div>
</div>
@ -844,7 +844,7 @@
</div>
<div class="col-sm-9 inputDiv">
<input type="text" class="form-control input-sm diagTable inputValue"
id="outpatient_no" maxlength="6">
id="outpatient_no" >
</div>
</div>
</div>
@ -855,7 +855,7 @@
</div>
<div class="col-sm-9 inputDiv">
<input type="text" class="form-control input-sm diagTable inputValue"
id="id_card" maxlength="6">
id="id_card" >
</div>
</div>
</div>
@ -887,7 +887,7 @@
</div>
<div class="col-sm-9 inputDiv">
<input type="text" class="form-control input-sm diagTable inputValue"
id="radiotherapy_no" maxlength="6">
id="radiotherapy_no" >
</div>
</div>
</div>

@ -359,8 +359,43 @@ function getSql() {
//拼接where语句
var name = '';
if(!isEmpty(dataSource)){
name = 'data_source';
whereNames += commomtable + "." + name + " = '" + dataSource + "' AND ";
if(dataSource == 6){
name = 'data_source';
whereNames += "len(commomtable.inpatient_no) > 10 AND ";
}else{
name = 'data_source';
whereNames += commomtable + "." + name + " = '" + dataSource + "' AND ";
}
}
if (inputValue != '') {
//判断是否多表

Loading…
Cancel
Save