From 66d39b597ca95b935a8dfcd3f4eabb8626e9d35c Mon Sep 17 00:00:00 2001 From: wangxh Date: Thu, 23 Apr 2020 16:08:13 +0800 Subject: [PATCH] =?UTF-8?q?1.=E7=95=8C=E9=9D=A2=E8=B0=83=E6=95=B4=202.?= =?UTF-8?q?=E6=96=B0=E5=A2=9E=E5=8F=82=E6=95=B0=E8=AE=BE=E7=BD=AE=E6=8E=A7?= =?UTF-8?q?=E5=88=B6=E7=94=B3=E8=AF=B7=E6=9C=80=E5=A4=A7=E6=97=B6=E9=97=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../otherManage/CommomSetController.java | 9 ++++- src/main/java/com/emr/entity/EmrComomSet.java | 22 ++++++++++++ .../resources/mapper/EmrComomSetMapper.xml | 28 ++++++++++++--- .../views/otherManage/commomSetList.jsp | 26 ++++++++++++-- .../views/otherManage/downloadInfoList174.jsp | 8 ++--- .../views/otherManage/printInfoList174.jsp | 8 ++--- .../commomSearch/commomListqf.jsp | 10 +++--- .../approveList/approveList174.js | 10 ++++++ .../approveSaveCommomMethodBlood.js | 1 - .../approveManageList/approveManageList174.js | 34 +++++++++---------- src/main/webapp/static/js/dateUtil.js | 31 ++++++++++++++++- .../static/js/font/showRecordIframeBlood.js | 1 - .../webapp/static/js/otherManage/commomSet.js | 16 +++++++++ .../js/otherManage/downloadInfoCommomJs174.js | 8 ++--- .../recordManage/commomSearch/commomListqf.js | 1 - .../templateSearch/customSearchIframeqf.js | 2 -- .../templateSearch/searchCommomMethod174.js | 2 -- .../templateSearch/searchCommomMethodqf.js | 1 + 18 files changed, 169 insertions(+), 49 deletions(-) diff --git a/src/main/java/com/emr/controller/otherManage/CommomSetController.java b/src/main/java/com/emr/controller/otherManage/CommomSetController.java index aad65e1..2aca400 100644 --- a/src/main/java/com/emr/controller/otherManage/CommomSetController.java +++ b/src/main/java/com/emr/controller/otherManage/CommomSetController.java @@ -1,6 +1,6 @@ package com.emr.controller.otherManage; -import com.emr.dao.EmrComomSetMapper; +import com.alibaba.fastjson.JSON; import com.emr.entity.EmrComomSet; import com.emr.entity.ResultUtil; import com.emr.service.CommomSetService; @@ -38,4 +38,11 @@ public class CommomSetController { return ResultUtil.error("保存出错了,请联系系统管理员"); } } + + @RequestMapping(value = "getCommomSetList") + @ResponseBody + public String getCommomSetList(){ + EmrComomSet comomSet = commomSetService.selectByPrimaryKey(1); + return JSON.toJSONString(comomSet); + } } diff --git a/src/main/java/com/emr/entity/EmrComomSet.java b/src/main/java/com/emr/entity/EmrComomSet.java index 75d7cc4..40365f2 100644 --- a/src/main/java/com/emr/entity/EmrComomSet.java +++ b/src/main/java/com/emr/entity/EmrComomSet.java @@ -7,6 +7,10 @@ public class EmrComomSet implements Serializable { private Short times; + private int defaultDay; + + private int maxDay; + private static final long serialVersionUID = 1L; public Integer getId() { @@ -25,6 +29,22 @@ public class EmrComomSet implements Serializable { this.times = times; } + public int getDefaultDay() { + return defaultDay; + } + + public void setDefaultDay(int defaultDay) { + this.defaultDay = defaultDay; + } + + public int getMaxDay() { + return maxDay; + } + + public void setMaxDay(int maxDay) { + this.maxDay = maxDay; + } + @Override public String toString() { StringBuilder sb = new StringBuilder(); @@ -33,6 +53,8 @@ public class EmrComomSet implements Serializable { sb.append("Hash = ").append(hashCode()); sb.append(", id=").append(id); sb.append(", times=").append(times); + sb.append(", defaultDay=").append(defaultDay); + sb.append(", maxDay=").append(maxDay); sb.append("]"); return sb.toString(); } diff --git a/src/main/resources/mapper/EmrComomSetMapper.xml b/src/main/resources/mapper/EmrComomSetMapper.xml index 94ae71f..28d7640 100644 --- a/src/main/resources/mapper/EmrComomSetMapper.xml +++ b/src/main/resources/mapper/EmrComomSetMapper.xml @@ -4,9 +4,11 @@ + + - id, times + id, times, defaultDay, maxDay + + +
+
+ +
+
+ +
+
- - - +
+ + + +
diff --git a/src/main/webapp/WEB-INF/views/otherManage/downloadInfoList174.jsp b/src/main/webapp/WEB-INF/views/otherManage/downloadInfoList174.jsp index be82fd8..9f45f01 100644 --- a/src/main/webapp/WEB-INF/views/otherManage/downloadInfoList174.jsp +++ b/src/main/webapp/WEB-INF/views/otherManage/downloadInfoList174.jsp @@ -100,18 +100,18 @@
- +
- +
- +
- +
diff --git a/src/main/webapp/WEB-INF/views/otherManage/printInfoList174.jsp b/src/main/webapp/WEB-INF/views/otherManage/printInfoList174.jsp index 49e0412..66f1455 100644 --- a/src/main/webapp/WEB-INF/views/otherManage/printInfoList174.jsp +++ b/src/main/webapp/WEB-INF/views/otherManage/printInfoList174.jsp @@ -100,18 +100,18 @@
- +
- +
- +
- +
diff --git a/src/main/webapp/WEB-INF/views/recordManage/commomSearch/commomListqf.jsp b/src/main/webapp/WEB-INF/views/recordManage/commomSearch/commomListqf.jsp index 2dd7e17..452bba4 100644 --- a/src/main/webapp/WEB-INF/views/recordManage/commomSearch/commomListqf.jsp +++ b/src/main/webapp/WEB-INF/views/recordManage/commomSearch/commomListqf.jsp @@ -12,7 +12,9 @@ - + @@ -220,13 +222,13 @@
+ value="病案号,ID号,住院次数,姓名,性别,年龄_岁,年龄_月,入院日期,出院日期,出院科室,联系地址,主诊ICD码,主诊名称,主诊转归,住院天数,主治医生,是否有手术"> + value="commomtable.inpatient_no,commomtable.admiss_id,commomtable.admiss_times,commomtable.name,commomtable.sex,commomtable.age,commomtable.age_month,commomtable.admiss_date,commomtable.dis_date,commomtable.dis_dept,commomtable.home_addr,commomtable.main_diag_code,commomtable.main_diag_name,commomtable.main_dis_thing,commomtable.admiss_days,commomtable.attending,commomtable.is_oper"> + value="inpatientNo,admissId,admissTimes,name,sex,age,ageMonth,admissDate,disDate,disDept,homeAddr,mainDiagCode,mainDiagName,mainDisThing,admissDays,attending,isOper"> diff --git a/src/main/webapp/static/js/approveManage/approveList/approveList174.js b/src/main/webapp/static/js/approveManage/approveList/approveList174.js index f5836c3..9eb6dfc 100644 --- a/src/main/webapp/static/js/approveManage/approveList/approveList174.js +++ b/src/main/webapp/static/js/approveManage/approveList/approveList174.js @@ -246,8 +246,17 @@ function refreshTable(){ }) } +//批量添加按钮 +function addApproves(){ + pickTime("effeTime5"); + form5.reset(); + //加载申请原因模板 + loadSelect(path+ '/approve/loadReasonModle','parentId5',''); +} + //添加按钮 function addApprove(){ + pickTime("effeTime"); setFormToken(); $("#inpatientNo").removeAttr("readonly"); $("#name").removeAttr("readonly"); @@ -326,6 +335,7 @@ function addSimple(){ } //编辑 function updateApprove(id){ + pickTime("effeTime") //加载申请原因模板 loadSelect(path+ '/approve/loadReasonModle','parentId',''); $("#inpatientNo").prop("readonly",true); diff --git a/src/main/webapp/static/js/approveManage/approveList/approveSaveCommomMethodBlood.js b/src/main/webapp/static/js/approveManage/approveList/approveSaveCommomMethodBlood.js index 0812dac..3bbc309 100644 --- a/src/main/webapp/static/js/approveManage/approveList/approveSaveCommomMethodBlood.js +++ b/src/main/webapp/static/js/approveManage/approveList/approveSaveCommomMethodBlood.js @@ -11,7 +11,6 @@ function add(){ //封装模态框保存公共方法,applyState:提交状态1保存未提交2已提交.msg:操作后提示信息 function saveMethod(applyState){ - debugger var inpatientNo = $("#inpatientNo").val(); var name = $("#name").val(); if($("#effeTime").val() != ''){ diff --git a/src/main/webapp/static/js/approveManage/approveManageList/approveManageList174.js b/src/main/webapp/static/js/approveManage/approveManageList/approveManageList174.js index ef6ec69..55c0b1c 100644 --- a/src/main/webapp/static/js/approveManage/approveManageList/approveManageList174.js +++ b/src/main/webapp/static/js/approveManage/approveManageList/approveManageList174.js @@ -88,6 +88,23 @@ $('#mytab').bootstrapTable({ title:'有效天数', field:'effeDays', }, + { + title:'审批状态', + field:'approveState', + formatter: function (value, row, index) { + var spanValue; + if(value == '已过期'){ + spanValue = '

已过期

'; + }else if(value == '待审批'){ + spanValue = '

待审批

'; + }else if(value == '审核通过'){ + spanValue = '

审核通过

'; + }else if(value == '审核不通过'){ + spanValue = '

审核不通过

'; + } + return spanValue; + } + }, { title:'姓名', field:'name', @@ -113,23 +130,6 @@ $('#mytab').bootstrapTable({ title:'申请类型', field:'applyType', }, - { - title:'审批状态', - field:'approveState', - formatter: function (value, row, index) { - var spanValue; - if(value == '已过期'){ - spanValue = '

已过期

'; - }else if(value == '待审批'){ - spanValue = '

待审批

'; - }else if(value == '审核通过'){ - spanValue = '

审核通过

'; - }else if(value == '审核不通过'){ - spanValue = '

审核不通过

'; - } - return spanValue; - } - }, { title:'审批时间', field:'approveTime', diff --git a/src/main/webapp/static/js/dateUtil.js b/src/main/webapp/static/js/dateUtil.js index 443e401..3e5e91f 100644 --- a/src/main/webapp/static/js/dateUtil.js +++ b/src/main/webapp/static/js/dateUtil.js @@ -54,4 +54,33 @@ function showTime(days){ } var eDate = year + "-" + month + "-" + strDate; return eDate; -} \ No newline at end of file +} + +function pickTime(info){ + var defaultDay = new Date(); + var maxDay = new Date(); + $.ajax({ + type:'get', + url:path+'/commomSet/getCommomSetList', + dataType:'json', + success:function(data){ + if(data != null || data != ''){ + defaultDay.setDate(defaultDay.getDate() + data.defaultDay); + maxDay.setDate(maxDay.getDate() + data.maxDay); + console.log("defaultDay = " + defaultDay); + console.log("maxDay =" + maxDay); + $('#'+info).datepicker({ + language: "zh-CN", + format: "yyyy-mm-dd", + autoclose: true,//选中之后自动隐藏日期选择框, + }) + $('#'+info).datepicker('setDate', defaultDay); + $('#'+info).datepicker('setEndDate', maxDay); + } + } + }) +} + +function getDefaultNumAndMaxNum() { + +} diff --git a/src/main/webapp/static/js/font/showRecordIframeBlood.js b/src/main/webapp/static/js/font/showRecordIframeBlood.js index b860035..97d5b32 100644 --- a/src/main/webapp/static/js/font/showRecordIframeBlood.js +++ b/src/main/webapp/static/js/font/showRecordIframeBlood.js @@ -132,7 +132,6 @@ function onloadJpgForPdf(){ } //记录打印记录 function printInfoBlood(){ - debugger alert(2) var patientId = "'"+$("#patientId").val()+"'"; var assortIds = $("#assortIds").val(); diff --git a/src/main/webapp/static/js/otherManage/commomSet.js b/src/main/webapp/static/js/otherManage/commomSet.js index f7a3732..9a01b05 100644 --- a/src/main/webapp/static/js/otherManage/commomSet.js +++ b/src/main/webapp/static/js/otherManage/commomSet.js @@ -23,3 +23,19 @@ function save(){ toastr.warning("保存失败,组数不能为空"); } } + +function checkNum(numName) { + var maxNum = Number($("#maxDay").val()); + var defaultNum = Number($("#defaultDay").val()); + if (numName == 'defaultDay') { + if (defaultNum > maxNum) { + $("#defaultDay").val(maxNum); + } + } + if (numName == 'maxDay') { + if (maxNum < defaultNum) { + $("#maxDay").val(defaultNum); + } + } + +} diff --git a/src/main/webapp/static/js/otherManage/downloadInfoCommomJs174.js b/src/main/webapp/static/js/otherManage/downloadInfoCommomJs174.js index afc8079..54dea03 100644 --- a/src/main/webapp/static/js/otherManage/downloadInfoCommomJs174.js +++ b/src/main/webapp/static/js/otherManage/downloadInfoCommomJs174.js @@ -64,14 +64,14 @@ $('#mytab').bootstrapTable({ title:'操作人', field:'creater', }, - { - title:'姓名', - field:'name', - }, { title:'病案号', field:'inpatientNo', }, + { + title:'姓名', + field:'name', + }, { title:'住院次数', field:'admissTimes', diff --git a/src/main/webapp/static/js/recordManage/commomSearch/commomListqf.js b/src/main/webapp/static/js/recordManage/commomSearch/commomListqf.js index 41fbe86..07ee28f 100644 --- a/src/main/webapp/static/js/recordManage/commomSearch/commomListqf.js +++ b/src/main/webapp/static/js/recordManage/commomSearch/commomListqf.js @@ -689,7 +689,6 @@ function insertContent(content, id) { clearContent(id); setLocation(id); var json = JSON.parse(content); - debugger for (key in json) { console.log(key) console.log(json[key]) diff --git a/src/main/webapp/static/js/recordManage/templateSearch/customSearchIframeqf.js b/src/main/webapp/static/js/recordManage/templateSearch/customSearchIframeqf.js index c3e0fd0..04372bf 100644 --- a/src/main/webapp/static/js/recordManage/templateSearch/customSearchIframeqf.js +++ b/src/main/webapp/static/js/recordManage/templateSearch/customSearchIframeqf.js @@ -142,7 +142,6 @@ function getSql() { var age_month = ''; var age_day = ''; $("#block").children().find('div').each(function () { - debugger var val = $(this).children().val(); var className = $(this).children().attr('class'); if (className == 'select2') { @@ -237,7 +236,6 @@ function getSql() { var orderBys = " order by " + commomtable + ".inpatient_no," + commomtable + ".admiss_times"; var sql = selectNames + fromTableNames + whereNames; $("#orderBys").val(orderBys); - debugger $("#sql").val(sql); console.log("sql = " + $("#sql").val()); //console.log(sql); diff --git a/src/main/webapp/static/js/recordManage/templateSearch/searchCommomMethod174.js b/src/main/webapp/static/js/recordManage/templateSearch/searchCommomMethod174.js index 353da47..594ceed 100644 --- a/src/main/webapp/static/js/recordManage/templateSearch/searchCommomMethod174.js +++ b/src/main/webapp/static/js/recordManage/templateSearch/searchCommomMethod174.js @@ -759,7 +759,6 @@ function add(){ //封装模态框保存公共方法,applyState:提交状态1保存未提交2已提交.msg:操作后提示信息 function saveMethod(applyState,msg,typeId){ - debugger if($("#effeTime").val() != ''){ var patientIds = $("#check").val(); if(patientIds == '') { @@ -1032,7 +1031,6 @@ function getLockPatientIds(){ } //过滤下载,导出pdf,查看详情的patientId集合:typeId:已借阅审批病案id集合或已下载审批病案id集合 function powerPotient(patientIds,flag,typeId){ - debugger //有权限的过滤 //通过且未过期的可查看的 var approves = $("#"+typeId).val(); diff --git a/src/main/webapp/static/js/recordManage/templateSearch/searchCommomMethodqf.js b/src/main/webapp/static/js/recordManage/templateSearch/searchCommomMethodqf.js index 9d4dc8c..9a9a4b0 100644 --- a/src/main/webapp/static/js/recordManage/templateSearch/searchCommomMethodqf.js +++ b/src/main/webapp/static/js/recordManage/templateSearch/searchCommomMethodqf.js @@ -622,6 +622,7 @@ function borrowing(patientId){ //批量申请借阅 function borrowings(){ + pickTime("effeTime"); $("#typeId").val('approves'); //加载申请借阅类型 loadApplyType(1);