Browse Source

门诊住院优化显示和操作

WANGJIALIANG 3 years ago
parent
commit
9d8a97a59a

+ 3 - 0
src/main/java/cn/hnthyy/thmz/controller/mz/MzPharmacyController.java

@@ -86,6 +86,9 @@ public class MzPharmacyController {
                 mzChargeDetail.setPatientId(null);
             }
             List<MzChargeDetail> mzChargeDetails = mzPharmacyService.getMzChargeOrder(chargeDetailPharmacyVo);
+            mzChargeDetails.forEach(detail -> {
+                detail.setWarnDept(zdUnitCodeService.queryDeptNameByIdInCache(detail.getWarnDept()));
+            });
             resultMap.put("code", 0);
             resultMap.put("message", "查询收费处方列表信息成功");
             resultMap.put("data", mzChargeDetails);

+ 2 - 2
src/main/java/cn/hnthyy/thmz/controller/yf/YfWardPrescriptionController.java

@@ -307,8 +307,8 @@ public class YfWardPrescriptionController {
                     byjList.add(yfWardVo);
                 }
             }
-            results.put("byjList",byjList);
-            results.put("list",list);
+            results.put("byjList",byjList.stream().sorted(Comparator.comparing(YfWardVo::getInpatientNo)).collect(Collectors.toList()));
+            results.put("list",list.stream().sorted(Comparator.comparing(YfWardVo::getInpatientNo)).collect(Collectors.toList()));
             resultMap.put("code", 0);
             resultMap.put("message", "查询病房请领单药品明细信息成功");
             resultMap.put("data", results);

+ 5 - 0
src/main/resources/static/js/mz/west_pharmacy_dispensing.js

@@ -145,6 +145,11 @@ function initTable() {
                 title: '流水号',
                 align: "center",
                 valign: 'middle'
+            }, {
+                field: 'warnDept',
+                title: '科室',
+                align: "center",
+                valign: 'middle'
             }, {
                 field: 'orderNo',
                 title: '处方号',

+ 8 - 4
src/main/resources/static/js/yf/ward_prescription.js

@@ -38,6 +38,12 @@ $(function () {
     });
 
     $("#btn_query").click(function (t) {
+        $("#initButton").find("button").each(function (index, element) {
+            if ($(element).hasClass("btn-primary")) {
+                $(element).removeClass("btn-primary").addClass("btn-default");
+            }
+        });
+        $("#qld").removeClass("btn-default").addClass("btn-primary");
         initTbTable();
     });
 });
@@ -661,12 +667,12 @@ function printCount() {
     let totalMoney = 0;
     $(".title").text(pageClass=="T"?'病房退药单':'病房汇总领药单('+$("#pageClassSearch").find("option:selected").text()+')');
     $(".groupName").text(groupNo==71?'门诊西药房':'住院药房');
-    $(".wardName").text($("#wardCode").find("option:selected").text().split("(")[0]);
+    let w_code = $("#wardCode").find("option:selected").text();
+    $(".wardName").text(w_code.substring(0,w_code.lastIndexOf("(")));
     $(".pageNo").text($("#pageNoSearch").val()==''?pageNos:$("#pageNoSearch").val());
     $(".printDate").html(format(new Date(),"yyyy-MM-dd HH:mm"));
     $('.sjh').remove();
     let datas = getJQAllData("tb_summarizing_table");
-    console.log(datas);
     for (var i = 0; i < datas.length; i++) {
         let data = datas[i];
         let handle =data.fybz;
@@ -727,7 +733,6 @@ function getPrintDetail(flag) {
                     window.location.href = '/thmz/login/view';
                     return;
                 }
-                console.log(res.data);
                 if (res.code == 0) {
                     for (let i = 0; i < res.data.list.length; i++) {
                         let byjDate = res.data.list[i];
@@ -802,7 +807,6 @@ function printDetail(datas,kfFlag,flag) {
  *
  */
 function printDetailHtml(datas,flag) {
-    console.log(datas);
     let html = '';
     let totalMoney = 0;
     let oldInpatientNo = '';//记录上一个病人

+ 1 - 0
src/main/resources/templates/yf/ward_prescription.html

@@ -66,6 +66,7 @@
                                 <select class="form-control selectpicker show-tick" required="required" title="请选择"
                                         onchange="initTbTable()"
                                         id="pageClassSearch">
+                                    <option value="" selected>全部</option>
                                     <option value="1">出院带药</option>
                                     <option value="2">毒麻药</option>
                                     <option value="3">基数药</option>