Forráskód Böngészése

Merge branch 'dev-1.0.9' into dev-1.1.0

hurugang 4 éve
szülő
commit
2441cd15c1
1 módosított fájl, 42 hozzáadás és 30 törlés
  1. 42 30
      src/main/resources/static/js/registration_list.js

+ 42 - 30
src/main/resources/static/js/registration_list.js

@@ -728,8 +728,8 @@ function formatCheck() {
  */
 function queryUserInfoByCardNo() {
     var cardNo = $("#cardNo").val();
-    var index =cardNo.indexOf("-");
-    if ((index > 0 && index==cardNo.length-2) || cardNo.length == 8) {
+    var index = cardNo.indexOf("-");
+    if ((index > 0 && index == cardNo.length - 2) || cardNo.length == 8) {
         $("#cardNo").attr("title", cardNo);
         $.ajax({
             type: "GET",
@@ -1352,7 +1352,7 @@ function initListDeptSelect() {
             }
             var html = '';
             $.each(data.data, function (commentIndex, comment) {
-                html += '<option value="' + comment.code + '">' + comment.name + '('+comment.pyCode+')</option>';
+                html += '<option value="' + comment.code + '">' + comment.name + '(' + comment.pyCode + ')</option>';
             });
             $('#deptNoParam').empty();
             $('#deptNoParam').html(html);
@@ -1568,7 +1568,7 @@ function loadCardList() {
                     html += mzyReqrecVo.mzPatientMi.responseType + '</div></div><div class="patient-card-main-right"><div></div> <div class="el-row"><label>';
                     html += text;
                     html += '</div><div class="el-row" title="' + mzyReqrecVo.mzPatientMi.phoneNo + '">' + sex + ' / ' + mzyReqrecVo.mzPatientMi.age + '岁 / ' + mzyReqrecVo.mzPatientMi.phoneNo + '</div><div class="el-row" title="' + mzyReqrecVo.mzyReqrec.ampm + '">' + mzyReqrecVo.mzyReqrec.ampm + ' / ' + mzyReqrecVo.mzyReqrec.chargeType + '</div><div class="el-row" title="' + mzyReqrecVo.mzyReqrec.chargeType + '">' + mzyReqrecVo.mzyReqrec.unitCode + ' / ' + mzyReqrecVo.mzyReqrec.doctorCode + '</div><div class="el-row">' + format(mzyReqrecVo.mzyReqrec.requestDay, "yyyy-MM-dd HH:mm:ss") + '</div></div></div>';
-                    if (mzyReqrecVo.mzyReqrec.cancelMark == 1 ) {
+                    if (mzyReqrecVo.mzyReqrec.cancelMark == 1) {
                         html += '<div class="patient-card-foot">' +
                             '                        <div class="col-md-3 col-sm-3 col-xs-12">' +
                             '                            <button type="button" class="can-not-used"' +
@@ -1595,7 +1595,8 @@ function loadCardList() {
                             '                            </button>' +
                             '                        </div>' +
                             '                    </div>';
-                    } if (mzyReqrecVo.mzyReqrec.visitedMark == 1) {
+                    }
+                    if (mzyReqrecVo.mzyReqrec.visitedMark == 1) {
                         html += '<div class="patient-card-foot">' +
                             '                        <div class="col-md-3 col-sm-3 col-xs-12">' +
                             '                            <button type="button" class="can-not-used"' +
@@ -1615,10 +1616,14 @@ function loadCardList() {
                             '                                <i class="fa fa-minus-square-o"></i>' +
                             '                            </button>' +
                             '                        </div>' +
-                            '                        <div class="col-md-3 col-sm-3 col-xs-12">' +
-                            '                            <button type="button" class="registration-no-color-foot-button"' +
-                            '                                    title="打印">' +
-                            '                                <i class="fa fa-print"></i>' +
+                            '                        <div class="col-md-3 col-sm-3 col-xs-12">';
+                        var printFlag = isEmpty(mzyReqrecVo.mzyReqrec.printerId);
+                        if (printFlag) {
+                            html += '                            <button type="button" class="registration-no-color-foot-button"  title="打印" onclick="prn1Print(\'' + mzyReqrecVo.mzyReqrec.patientId + '\',' + mzyReqrecVo.mzyReqrec.times + ')">';
+                        } else {
+                            html += '                            <button type="button" class="can-not-used" title="打印">';
+                        }
+                        html += '                                <i class="fa fa-print"></i>' +
                             '                            </button>' +
                             '                        </div>' +
                             '                    </div>';
@@ -1800,10 +1805,9 @@ function loadTableList() {
                     formatter: function (value, row, index) {
                         if (row.mzyReqrec.cancelMark == 1) {
                             return '<button type="button" class="can-not-used" title="修改挂号"><i class="fa fa-edit"></i></button><button type="button" class="registration-no-color-foot-button"title="修改患者" onclick="editUserModal(\'' + row.mzyReqrec.patientId + '\')"><i class="fa fa-user"></i></button><button type="button" class="can-not-used" title="退号"><i class="fa fa-minus-square-o"></i></button><button type="button" class="can-not-used" title="打印" ><i class="fa fa-print"></i></button>';
-                        } if (row.mzyReqrec.visitedMark == 1) {
-                            return '<button type="button" class="can-not-used" title="修改挂号"><i class="fa fa-edit"></i></button><button type="button" class="registration-no-color-foot-button"title="修改患者" onclick="editUserModal(\'' + row.mzyReqrec.patientId + '\')"><i class="fa fa-user"></i></button><button type="button" class="can-not-used" title="退号"><i class="fa fa-minus-square-o"></i></button><button type="button" class="registration-no-color-foot-button" title="打印" ><i class="fa fa-print"></i></button>';
-                        } else {
-                            var html = '<button type="button" class="can-not-used" title="修改挂号"><i class="fa fa-edit"></i></button><button type="button" class="registration-no-color-foot-button"title="修改患者" onclick="editUserModal(\'' + row.mzyReqrec.patientId + '\')"><i class="fa fa-user"></i></button><button type="button" class="registration-no-color-foot-button" title="退号" onclick="backNoModal(\'' + row.mzyReqrec.patientId + '\',' + row.mzyReqrec.times + ')"><i class="fa fa-minus-square-o"></i></button>';
+                        }
+                        if (row.mzyReqrec.visitedMark == 1) {
+                            var html = '<button type="button" class="can-not-used" title="修改挂号"><i class="fa fa-edit"></i></button><button type="button" class="registration-no-color-foot-button"title="修改患者" onclick="editUserModal(\'' + row.mzyReqrec.patientId + '\')"><i class="fa fa-user"></i></button><button type="button" class="can-not-used" title="退号"><i class="fa fa-minus-square-o"></i></button>';
                             var printFlag = isEmpty(row.mzyReqrec.printerId);
                             if (printFlag) {
                                 html += '                            <button type="button" class="registration-no-color-foot-button"  title="打印" onclick="prn1Print(\'' + row.mzyReqrec.patientId + '\',' + row.mzyReqrec.times + ')">';
@@ -1812,7 +1816,17 @@ function loadTableList() {
                             }
                             html += '<i class="fa fa-print"></i></button>';
                             return html;
+
                         }
+                        var html = '<button type="button" class="can-not-used" title="修改挂号"><i class="fa fa-edit"></i></button><button type="button" class="registration-no-color-foot-button"title="修改患者" onclick="editUserModal(\'' + row.mzyReqrec.patientId + '\')"><i class="fa fa-user"></i></button><button type="button" class="registration-no-color-foot-button" title="退号" onclick="backNoModal(\'' + row.mzyReqrec.patientId + '\',' + row.mzyReqrec.times + ')"><i class="fa fa-minus-square-o"></i></button>';
+                        var printFlag = isEmpty(row.mzyReqrec.printerId);
+                        if (printFlag) {
+                            html += '                            <button type="button" class="registration-no-color-foot-button"  title="打印" onclick="prn1Print(\'' + row.mzyReqrec.patientId + '\',' + row.mzyReqrec.times + ')">';
+                        } else {
+                            html += '                            <button type="button" class="can-not-used" title="打印">';
+                        }
+                        html += '<i class="fa fa-print"></i></button>';
+                        return html;
                     }
                 }],
             responseHandler: function (res) {
@@ -2053,7 +2067,7 @@ function clearRegistration() {
  */
 function prn1Print(patientId, times) {
     setPrint();
-    var height ="93.15mm";
+    var height = "93.15mm";
     // if(countReceiot%2==0){
     //     height ="93.2mm";
     // }
@@ -2072,7 +2086,7 @@ function prn1Print(patientId, times) {
                 if (res.data == null || res.data.length == 0) {
                     return;
                 }
-            //    countReceiot++;
+                //    countReceiot++;
                 LODOP = getLodop();
                 var temp = res.data;
                 LODOP.PRINT_INITA(6, 0, "120mm", height, "泰和门诊发票打印");
@@ -2134,27 +2148,25 @@ function isEmpty(obj) {
 }
 
 
-
-
 /**
  * 导出excel
  */
 function exportExcel() {
     var rePortRangeArr = getRePortRangeArr();
     var regiListBtnGroup = getIndex("regi_List_btn_group");
-    var visitedMark="";
-    var cancelMark="";
+    var visitedMark = "";
+    var cancelMark = "";
     if (regiListBtnGroup == 1) {
-        visitedMark=0;
-        cancelMark=0;
-    }else if (regiListBtnGroup == 2) {
-        visitedMark=1;
-        cancelMark=0;
-    }else if (regiListBtnGroup == 3) {
-
-        cancelMark=1;
+        visitedMark = 0;
+        cancelMark = 0;
+    } else if (regiListBtnGroup == 2) {
+        visitedMark = 1;
+        cancelMark = 0;
+    } else if (regiListBtnGroup == 3) {
+
+        cancelMark = 1;
     }
-    window.location.href = "/thmz/exportListMzyReqrec?beginTime=" + rePortRangeArr[0] + "&endTime=" + rePortRangeArr[1]+"&name="+$("#userNameParam").val()
-        +"&unitCode="+$("#deptNoParam").val()+"&doctorCode="+$("#doctorParam").val()+"&phoneNo="+$("#phoneParam").val()+"&serialNo="+$("#serialNoParams").val()+"&visitedMark="
-        +visitedMark+"&cancelMark="+cancelMark;
+    window.location.href = "/thmz/exportListMzyReqrec?beginTime=" + rePortRangeArr[0] + "&endTime=" + rePortRangeArr[1] + "&name=" + $("#userNameParam").val()
+        + "&unitCode=" + $("#deptNoParam").val() + "&doctorCode=" + $("#doctorParam").val() + "&phoneNo=" + $("#phoneParam").val() + "&serialNo=" + $("#serialNoParams").val() + "&visitedMark="
+        + visitedMark + "&cancelMark=" + cancelMark;
 }