فهرست منبع

药品购入情况分析开发完成

WANGJIALIANG 2 سال پیش
والد
کامیت
d7110ed7ee

+ 14 - 0
src/main/java/cn/hnthyy/thmz/controller/NavigationController.java

@@ -1299,4 +1299,18 @@ public class NavigationController {
         }
         return "yk/drug_purchase_situation";
     }
+
+    /**
+     * 药品购入情况分析
+     *
+     * @return
+     */
+    @RequestMapping("/drug-in-out-count")
+    public String drugInOutCount(HttpServletRequest httpServletRequest) throws Exception {
+        List<String> urls = getRoleUrls(httpServletRequest);
+        if (!urls.contains("/thmz/drug-in-out-count")) {
+            throw new Exception("您没有此模块的权限,请联系管理员开通!");
+        }
+        return "yk/drug_in_out_count";
+    }
 }

+ 28 - 0
src/main/java/cn/hnthyy/thmz/controller/yk/YpInDetlController.java

@@ -359,4 +359,32 @@ public class YpInDetlController {
             return resultMap;
         }
     }
+    /**
+     * 统计出入库金额
+     *
+     * @param map
+     * @return
+     */
+    @UserLoginToken
+    @RequestMapping(value = "/getDrugMoneyCount", method = {RequestMethod.POST})
+    public Map<String, Object> getDrugMoneyCount(@RequestBody Map<String,Object> map) {
+        Map<String, Object> resultMap = new HashMap<>();
+        try {
+            if (map == null) {
+                resultMap.put("code", -1);
+                resultMap.put("message", "查询记录信息失败,参数为空");
+                return resultMap;
+            }
+            List<Map<String, Object>> list = ypInDetlService.queryDrugMoneyCount(map);
+            resultMap.put("data", list);
+            resultMap.put("code", 0);
+            resultMap.put("message", "查询记录信息成功");
+            return resultMap;
+        } catch (Exception e) {
+            log.error("系统异常,错误信息{}", e);
+            resultMap.put("code", -1);
+            resultMap.put("message", "查询记录信息失败");
+            return resultMap;
+        }
+    }
 }

+ 37 - 8
src/main/java/cn/hnthyy/thmz/mapper/his/yp/YpInDetlMapper.java

@@ -168,7 +168,7 @@ public interface YpInDetlMapper {
             "       rept_date," +
             "       confirm_date," +
             "       producing_date" +
-            " FROM yp_in_detl" +
+            " FROM yp_in_detl WITH(NOLOCK)" +
             "<where>" +
             "   <if test=\"chargeCode != null and chargeCode != ''\">" +
             "        AND charge_code=#{chargeCode}" +
@@ -305,7 +305,7 @@ public interface YpInDetlMapper {
             "       c.yp_type as ypType," +
             "       buyMoney=sum(cast(a.buy_price* a.buy_amt as decimal(18,2)))," +
             "       packMoney=sum(cast(a.pack_retprice * a.buy_amt as decimal(18,2)))" +
-            "FROM yp_in_detl a,yp_zd_dict b,yp_zd_drug_kind c" +
+            "FROM yp_in_detl a WITH(NOLOCK),yp_zd_dict b WITH(NOLOCK),yp_zd_drug_kind c WITH(NOLOCK)" +
             "<where>" +
             "    AND a.charge_code=b.code" +
             "    AND a.serial=b.serial" +
@@ -342,7 +342,7 @@ public interface YpInDetlMapper {
             "       license_no,purchaser,checker,in_comment," +
             "       in_type,acct_type,stock_amount,fix_price,group_no,acct_date," +
             "       current_stock,kl,sys_date,fp_date,hg_flag" +
-            " FROM yp_in_detl" +
+            " FROM yp_in_detl WITH(NOLOCK)" +
             "<where>" +
             "    current_stock > 0" +
             "   <if test=\"chargeCode != null and chargeCode != ''\">" +
@@ -378,7 +378,7 @@ public interface YpInDetlMapper {
             "       manuCode=max(manu_code),\n" +
             "       supplyCode=max(supply_code),\n" +
             "       in_docu_no AS inDocuNo" +
-            " FROM yp_in_detl" +
+            " FROM yp_in_detl WITH(NOLOCK)" +
             "<where>" +
             "   <if test=\"beginDate != null and beginDate != ''\">" +
             "       and in_date <![CDATA[>=]]> #{beginDate}"+
@@ -409,7 +409,7 @@ public interface YpInDetlMapper {
             "       reptNoSum=count(distinct rept_no),\n" +
             "       manuCode=max(manu_code),\n" +
             "       supplyCode=max(supply_code)" +
-            " FROM yp_in_detl" +
+            " FROM yp_in_detl WITH(NOLOCK)" +
             "<where>" +
             "   <if test=\"beginDate != null and beginDate != ''\">" +
             "       and in_date <![CDATA[>=]]> #{beginDate}"+
@@ -441,7 +441,7 @@ public interface YpInDetlMapper {
             "       reptNoSum=count(distinct rept_no),\n" +
             "       manuCode=max(manu_code),\n" +
             "       supplyCode=max(supply_code)" +
-            " FROM yp_in_detl" +
+            " FROM yp_in_detl WITH(NOLOCK)" +
             "<where>" +
             "   <if test=\"beginDate != null and beginDate != ''\">" +
             "       and in_date <![CDATA[>=]]> #{beginDate}"+
@@ -472,7 +472,7 @@ public interface YpInDetlMapper {
             "       reptNoSum=count(distinct rept_no),\n" +
             "       manuCode=max(manu_code),\n" +
             "       supplyCode=max(supply_code)" +
-            " FROM yp_in_detl" +
+            " FROM yp_in_detl WITH(NOLOCK)" +
             "<where>" +
             "   <if test=\"beginDate != null and beginDate != ''\">" +
             "       and in_date <![CDATA[>=]]> #{beginDate}"+
@@ -491,7 +491,36 @@ public interface YpInDetlMapper {
             "</script>")
     List<Map<String,Object>> selectDrugManuDetailed(Map map);
 
+    /**
+     * 统计药库入库金额
+     * @param map
+     * @return
+     */
+    @Select("<script>"+
+            "select  a.group_no as groupNo,\n" +
+            "        left(convert(varchar(12),in_date,111),7) as countDate,\n" +
+            "        sum(round(convert(decimal(18,3),(convert(decimal(18,3),a.buy_price )* a.buy_amt)),2)) as inMoneyBuy,\n" +
+            "        sum(round(convert(decimal(18,3),(convert(decimal(18,3),a.pack_retprice )* a.buy_amt)),2)) as inMoneyRet\n" +
+            "   from yp_in_detl a WITH(NOLOCK)\n" +
+            "   where  datediff(day,in_date,#{beginDate}) <![CDATA[<=]]> 0 and\n" +
+            "   datediff(day,in_date,#{endDate}) <![CDATA[>]]> 0 and\n" +
+            "   a.group_no =#{groupNo}" +
+            "   group by a.group_no,\n" +
+            "         left(convert(varchar(12),in_date,111),7)" +
+            "</script>")
+    List<Map<String,Object>> selectDrugInMoneyCount(Map map);
 
 
-
+    /**
+     * 按药品分类统计入库金额
+     * @param map
+     * @return
+     */
+    @Select("<script>"+
+            "select c.name,sum(b.buy_amt*b.buy_price) inMoneyBuy,sum(b.buy_amt*b.pack_retprice) inMoneyRet from yp_zd_dict a WITH(NOLOCK),yp_in_detl b WITH(NOLOCK),yp_zd_drug_kind c WITH(NOLOCK)\n" +
+            " where a.code=b.charge_code and a.serial=b.serial and a.drug_kind=c.code\n" +
+            "  and b.in_date<![CDATA[>=]]>#{beginDate} and b.in_date<![CDATA[<=]]>#{endDate} and b.group_no=#{groupNo}\n" +
+            "  group by c.code,c.name" +
+            "</script>")
+    List<Map<String,Object>> selectDrugKindInMoneyCount(Map map);
 }

+ 18 - 0
src/main/java/cn/hnthyy/thmz/mapper/his/yp/YpOutDetlMapper.java

@@ -5,6 +5,7 @@ import cn.hnthyy.thmz.vo.YpOutDetlVo;
 import org.apache.ibatis.annotations.*;
 
 import java.util.List;
+import java.util.Map;
 
 /**
  * @description:药品出库
@@ -276,4 +277,21 @@ public interface YpOutDetlMapper {
             "</script>"})
     int selectYpOutDetlDrugReturnCount(YpOutDetl ypOutDetl);
 
+    /**
+     * 统计药库出库金额
+     * @param map
+     * @return
+     */
+    @Select("<script>"+
+            "select  a.group_no_out as group_no," +
+            "        left(convert(varchar(12),out_date,111),7)as countDate," +
+            "        sum(round(convert(decimal(18,3),(convert(decimal(18,3),a.pack_retprice )* out_amt)),2)) as outMoneyRet" +
+            "   from yp_out_detl a" +
+            "   where  datediff(day,in_date,#{beginDate}) <![CDATA[<=]]> 0 and" +
+            "   datediff(day,in_date,#{endDate}) <![CDATA[>]]> 0 and" +
+            "   a.group_no =#{groupNo}" +
+            "   group by a.group_no_out," +
+            "         left(convert(varchar(12),out_date,111),7)" +
+            "</script>")
+    List<Map<String,Object>> selectDrugOutMoneyCount(Map map);
 }

+ 8 - 0
src/main/java/cn/hnthyy/thmz/service/his/yp/YpInDetlService.java

@@ -102,4 +102,12 @@ public interface YpInDetlService {
      * @return
      */
     List<Map<String,Object>> queryDrugPurchaseSituation(Map map);
+
+    /**
+     * 统计药库出入库金额
+     * @param map
+     * @return
+     */
+    List<Map<String,Object>> queryDrugMoneyCount(Map map);
+
 }

+ 28 - 1
src/main/java/cn/hnthyy/thmz/service/impl/his/yp/YpInDetlServiceImpl.java

@@ -61,6 +61,9 @@ public class YpInDetlServiceImpl implements YpInDetlService {
     private YpZdDrugKindMapper ypZdDrugKindMapper;
     @SuppressWarnings("all")
     @Autowired
+    private YpOutDetlMapper ypOutDetlMapper;
+    @SuppressWarnings("all")
+    @Autowired
     private YpConfigService ypConfigService;
 
     @Override
@@ -312,7 +315,7 @@ public class YpInDetlServiceImpl implements YpInDetlService {
     @Override
     public List<Map<String, Object>> queryDrugPurchaseSituation(Map map) {
         String flag = map.get("flag").toString();
-        List<Map<String, Object>> list = new ArrayList<>();
+        List<Map<String, Object>> list;
         if(flag.equals("0")){
             list = ypInDetlMapper.selectDrugSupplySum(map);
         }else if(flag.equals("1")){
@@ -340,4 +343,28 @@ public class YpInDetlServiceImpl implements YpInDetlService {
         }
         return list;
     }
+
+    @Override
+    public List<Map<String, Object>> queryDrugMoneyCount(Map map) {
+        if(map.get("flag").equals("1")){
+            return ypInDetlMapper.selectDrugKindInMoneyCount(map);
+        }
+        List<Map<String, Object>> listIn = ypInDetlMapper.selectDrugInMoneyCount(map);
+        List<Map<String, Object>> listOut = new ArrayList<>();
+        for (int i = 0; i < listIn.size(); i++) {
+            Map<String, Object> stringObjectMap = listIn.get(i);
+            String countDate = stringObjectMap.get("countDate").toString();
+            for (int j = 0; j < listOut.size(); j++) {
+                Map<String, Object> stringObjectMapOut = listIn.get(i);
+                String countDateOut = stringObjectMapOut.get("countDate").toString();
+                if(countDate.equals(countDateOut)){
+                    stringObjectMap.put("outMoneyRet",stringObjectMapOut.get("outMoneyRet"));
+                }
+            }
+        }
+        if(listIn.size() == 0){
+            return listOut;
+        }
+        return listIn;
+    }
 }

+ 188 - 0
src/main/resources/static/js/yk/drug_in_out_count.js

@@ -0,0 +1,188 @@
+//@ sourceURL=drug_in_out_count.js
+var LODOP; //声明为全局变量
+var groupYk = window.localStorage["groupYk"];
+$(function () {
+    if (groupYk == null) {
+        return errorMesageSimaple('药库参数未设置,请在发药参数设置中设置');
+    }
+    init_daterangepicker();
+    setTimeout(function () {
+        getLodop();
+    }, 800);
+    $("#class_table").hide();
+    $(".selectpicker").selectpicker({
+        dropuAuto: false
+    });
+
+    //初始化页面上面的按钮事件
+    $("#btn_search").click(function (t) {
+        $('.sjh').remove();
+        getRecordData();
+    });
+    $('#btn_clean').click(function () {
+        cleanParams();
+    });
+    $("#btn_daily").click(function (t) {
+        print();
+    });
+    $("#btn_excel").click(function (t) {
+        let statisticalMethod = $("#statisticalMethod").val();
+        let id = "";
+        if (statisticalMethod === "0") {
+            id = 'sum_table';
+        } else {
+            id = 'class_table';
+        }
+        $("#" + id).table2excel({
+            exclude: ".exclHide",
+            filename: $("#" + id + " .title").html() + "(" + getRePortRangeArr()[0].substring(0, getRePortRangeArr()[0].indexOf(" ") + 1) + ").xls"
+        })
+    });
+    $("#statisticalMethod").change(function (t, d, e) {
+        let statisticalMethod = $("#statisticalMethod").val();
+        if (statisticalMethod === "0") {
+            $("#sum_table").show();
+            $("#class_table").hide();
+        } else {
+            $("#class_table").show();
+            $("#sum_table").hide();
+        }
+        $(".dateRange").html($('#reportrange span').html());
+        $(".printDate").html(format(new Date(), "yyyy-MM-dd HH:mm"));
+    });
+});
+
+
+/**
+ * 获取汇总药品统计报表
+ */
+function getRecordData() {
+    let statisticalMethod = $('#statisticalMethod').val();
+    let data = {
+        'beginDate': getRePortRangeArr()[0],
+        'endDate': getRePortRangeArr()[1],
+        'flag': statisticalMethod,
+        'groupNo': groupYk,
+    };
+    $('#YWaitDialog').css('top', $('.xtd').offset().top);
+    $('#YWaitDialog').show();
+    $(".dateRange").html($('#reportrange span').html());
+    $(".groupName").html(getGroupName(groupYk));
+    $(".printDate").html(format(new Date(), "yyyy-MM-dd HH:mm"));
+    $.ajax({
+        type: "POST",
+        url: '/thmz/getDrugMoneyCount',
+        contentType: "application/json;charset=UTF-8",
+        dataType: "json",
+        headers: {'Accept': 'application/json', 'Authorization': 'Bearer ' + localStorage.getItem("token")},
+        data: JSON.stringify(data),
+        success: function (res) {
+            $('#YWaitDialog').hide();
+            if (res == '401' || res == 401) {
+                window.location.href = '/thmz/login/view'
+                return;
+            }
+            if (res.code == 0) {
+                let html = '';
+                let totalInMoneyRet = 0;
+                let totalOutMoneyRet = 0;
+                for (var i = 0; i < res.data.length; i++) {
+                    let data = res.data[i];
+                    if (statisticalMethod == 0) {
+                        let inMoneyRet = isEmpty(data.inMoneyRet)?0:keepTwoDecimal(data.inMoneyRet);
+                        let outMoneyRet = isEmpty(data.outMoneyRet)?0:keepTwoDecimal(data.outMoneyRet);
+                        html += '<tr class="sjh">';
+                        html += '<td class="xtd" style="text-align: center;">' + (i + 1) + '</td>';
+                        html += '<td class="xtd" style="text-align: center;">' + data.countDate + '</td>';
+                        html += '<td class="xtd" style="text-align: center;">' + data.inMoneyBuy + '</td>';
+                        html += '<td class="xtd" style="text-align: center;">' + inMoneyRet + '</td>';
+                        html += '<td class="xtd" style="text-align: center;">' + outMoneyRet + '</td>';
+                        html += '</tr>';
+                        totalInMoneyRet += inMoneyRet;
+                        totalOutMoneyRet += outMoneyRet
+                    } else {
+                        let inMoneyBuy = isEmpty(data.inMoneyBuy)?0:keepTwoDecimal(data.inMoneyBuy);
+                        let inMoneyRet = isEmpty(data.inMoneyRet)?0:keepTwoDecimal(data.inMoneyRet);
+                        html += '<tr class="sjh">';
+                        html += '<td class="xtd" style="text-align: center;">' + data.name + '</td>';
+                        html += '<td class="xtd" style="text-align: center;">' + inMoneyBuy + '</td>';
+                        html += '<td class="xtd" style="text-align: center;">' + inMoneyRet + '</td>';
+                        totalInMoneyRet += inMoneyBuy;
+                        totalOutMoneyRet += inMoneyRet
+                    }
+                }
+                if (statisticalMethod == 0) {
+                    html += '<tr class="sjh">';
+                    html += '<td colspan="3" style="text-align: right;font-weight: 700;">总计:</td>';
+                    html += '<td style="text-align: center;">' + keepTwoDecimal(totalInMoneyRet) + '</td>';
+                    html += '<td style="text-align: center;">' + keepTwoDecimal(totalOutMoneyRet) + '</td>';
+                    html += '</tr>';
+                }else{
+                    html += '<tr class="sjh">';
+                    html += '<td style="text-align: right;font-weight: 700;">总计:</td>';
+                    html += '<td style="text-align: center;">' + keepTwoDecimal(totalInMoneyRet) + '</td>';
+                    html += '<td style="text-align: center;">' + keepTwoDecimal(totalOutMoneyRet) + '</td>';
+                    html += '</tr>';
+                }
+                if (statisticalMethod == 0) {
+                    $("#sum_table").append(html);
+                } else {
+                    $("#class_table").append(html);
+                }
+            } else if (res.code == -1) {
+                new PNotify({
+                    title: '错误提示',
+                    text: res.message,
+                    type: 'error',
+                    hide: true,
+                    styling: 'bootstrap3'
+                });
+            }
+        }
+    });
+}
+
+/**
+ * 获取时间选择器的时间数组
+ * @returns {string[]}
+ */
+function getRePortRangeArr() {
+    var rePortRange = $('#reportrange span').html();
+    var rePortRangeArr = rePortRange.split(" - ");
+    return rePortRangeArr;
+}
+
+/**
+ * 清空查询条件
+ */
+function cleanParams() {
+    $("#statisticalMethod").val(0);
+    $('#statisticalMethod').selectpicker('refresh');
+    $('#reportrange span').html(moment().subtract(1, 'days').format("YYYY-MM-DD") + ' - ' + moment().subtract(1, 'days').format("YYYY-MM-DD"));
+    $('#sum_table').show();
+    $('#class_table').hide();
+    $('.sjh').remove();
+}
+
+/**
+ * 打印报表
+ */
+function print() {
+    setDefaultPrint();
+    LODOP = getLodop();
+    LODOP.PRINT_INITA(6, 0, "210mm", "297mm", "药品出入库统计表");
+    LODOP.SET_PRINT_PAGESIZE(1, 0, 0, "A4");
+    //设置默认打印机
+    LODOP.SET_PRINTER_INDEX(defaultPrintIndex);
+    LODOP.SET_PRINT_STYLE("FontSize", 10); //字体大小
+    LODOP.SET_PRINT_STYLEA(0, "ItemType", 2);
+    //设置默认打印机
+    LODOP.SET_PRINTER_INDEX(defaultPrintIndex);
+    LODOP.ADD_PRINT_TEXT('280mm', '100mm', '40mm', '40mm', '第#页/共&页');
+    LODOP.SET_PRINT_STYLEA(0, "ItemType", 2);
+    var strStyle = "<style>table,td,th {border-width: 1px;" +
+        "border-style: solid;border-collapse: collapse;table-layout:fixed;word-wrap:break-word;font-size: 14px}</style>";
+    LODOP.ADD_PRINT_HTM("2mm", "4mm", "RightMargin:4mm", "BottomMargin:15mm", strStyle + document.getElementById("report_table_1").innerHTML);
+    LODOP.PRINT();
+    //LODOP.PREVIEW();
+}

+ 1 - 19
src/main/resources/static/js/yk/drug_purchase_situation.js

@@ -118,7 +118,6 @@ function getRecordData() {
                 return;
             }
             if (res.code == 0) {
-                console.log(res.data);
                 let html = '';
                 let packRetpriceSum = 0;
                 let buyPriceSum = 0;
@@ -191,23 +190,6 @@ function getRecordData() {
     });
 }
 
-/**
- * 获取按钮组选择的下标
- * @param id
- * @returns {number}
- */
-function getIndex(id) {
-    var index = 0;
-    var item = $("#" + id).find("button");
-    for (var i = 0; i <= item.length; i++) {
-        if ($(item[i]).hasClass("btn-primary")) {
-            index = i;
-            break;
-        }
-    }
-    return index;
-}
-
 /**
  * 获取时间选择器的时间数组
  * @returns {string[]}
@@ -239,7 +221,7 @@ function cleanParams() {
 function print() {
     setDefaultPrint();
     LODOP = getLodop();
-    LODOP.PRINT_INITA(6, 0, "210mm", "297mm", "药品发放统计表");
+    LODOP.PRINT_INITA(6, 0, "210mm", "297mm", "药品购入统计表");
     LODOP.SET_PRINT_PAGESIZE(1, 0, 0, "A4");
     //设置默认打印机
     LODOP.SET_PRINTER_INDEX(defaultPrintIndex);

+ 126 - 0
src/main/resources/templates/yk/drug_in_out_count.html

@@ -0,0 +1,126 @@
+<link rel="stylesheet" href="/thmz/css/bootstrap/css/bootstrap-select.css"/>
+<link rel="stylesheet" href="/thmz/css/bootstrap/css/daterangepicker.css"/>
+<link rel="stylesheet" href="/thmz/css/custom.min.css">
+<link rel="stylesheet" href="/thmz/css/toll_administration.css">
+<link rel="stylesheet" href="/thmz/css/jquery.webui-popover.min.css">
+<script src="/thmz/js/dependent/bootstrap-select.js"></script>
+<script src="/thmz/js/dependent/daterangepicker.js"></script>
+<script src="/thmz/js/common/date-util.js"></script>
+<script src="/thmz/js/dependent/jquery.webui-popover.min.js"></script>
+<script src="/thmz/js/common/pharmacy-com.js"></script>
+<script src="/thmz/js/yk/drug_in_out_count.js"></script>
+<script src="/thmz/js/dependent/jquery.table2excel.min.js"></script>
+<script src="/thmz/js/dependent/LodopFuncs.js"></script>
+<title>药品出入库汇总统计</title>
+<!-- 打印的样式-->
+<style media="print">
+    @page {
+        size: auto;
+        margin: 0mm;
+    }
+</style>
+<div class="row" style="height: calc(100% - 00px);">
+    <div class="col-md-12 col-sm-12 col-xs-12" style="height: 100%">
+        <div class="x_panel" style="height: 100%">
+            <div class="panel-body">
+                <form id="formSearch" class="form-horizontal" autocomplete="off">
+                    <div class="form-group col-md-12 col-sm-12 col-xs-12">
+                        <div class="col-md-3 col-sm-3 col-xs-12"></div>
+                        <div class="col-md-2 col-sm-2 col-xs-12">
+                            <label class="control-label col-md-5 col-sm-5 col-xs-12"
+                                   for="statisticalMethod">统计方式</label>
+                            <div class="col-md-7 col-sm-7 col-xs-12">
+                                <select class="form-control selectpicker show-tick" required="required" title="请选择"
+                                        id="statisticalMethod">
+                                    <option value="0" selected>按日期</option>
+                                    <option value="1">按分类</option>
+                                </select>
+                            </div>
+                        </div>
+                        <label class="control-label col-md-1 col-sm-1 col-xs-12" for="reportrange"
+                               style="width: 105px;">
+                            日期范围
+                        </label>
+                        <div class="col-md-3 col-sm-3 col-xs-12 " style="width: 325px;">
+                            <div id="reportrange" class="pull-left"
+                                 style="background: #fff; cursor: pointer; padding: 6.5px 10px; border: 1px solid #ccc">
+                                <i class="glyphicon glyphicon-calendar fa fa-calendar"></i>
+                                <span>December 30, 2014 - January 28, 2015</span> <b class="caret"></b>
+                            </div>
+                        </div>
+                        <button type="button" id="btn_search" class="btn btn-primary"
+                                title="查询"><i class="glyphicon glyphicon-search"></i>
+                        </button>
+                        <button type="button"  id="btn_clean" class="btn btn-primary"
+                                title="重置"><i class="fa fa-rotate-left"></i>
+                        </button>
+                        <button type="button" id="btn_daily" class="btn btn-primary"
+                                title="打印"><i class="fa fa-print"></i>
+                        </button>
+                        <a id="btn_excel" class="btn btn-primary"
+                           title="导出Excel"><i class="fa fa-file-excel-o"></i>
+                        </a>
+                    </div>
+                </form>
+            </div>
+            <div id="report_table"
+                 style="width:920px;height: calc(100% - 160px);margin:0 auto;border: 1px solid #337ab7;font-size: 14px;padding: 40px 10px 40px 10px;overflow: scroll">
+                <div id="report_table_1">
+                    <table id="sum_table" class="table table-striped table-bordered" style="margin-top: 0px;">
+                        <tr style="font-weight: 700;background-color: #EBEBE4">
+                            <td colspan="6" style="font-size: 21px;text-align: center;border: transparent !important;"><span class="title">药库药品入/出库数据分析</span></td>
+                        </tr>
+                        <tr style="font-weight: 700;background-color: #EBEBE4">
+                            <td colspan="2" style="text-align: left;border: transparent !important;">统计日期:<span class="dateRange"></span></td>
+                            <td colspan="1" style="text-align: right;border: transparent !important;">库房名称:<span class="groupName"></span></td>
+                            <td colspan="3" style="text-align: right;border: transparent !important;">打印日期:<span class="printDate"></span></td>
+                        </tr>
+                        <tr>
+                            <td class="xtd " style="text-align: center;width: 100px;">序号</td>
+                            <td class="xtd" style="text-align: center;width: 200px;">统计日期</td>
+                            <td class="xtd" style="text-align: center;width: 200px;">购入金额</td>
+                            <td class="xtd" style="text-align: center;width: 200px;">入库金额(零售价)</td>
+                            <td class="xtd" style="text-align: center;width: 200px;">出库金额(零售价)</td>
+                        </tr>
+                    </table>
+                    <table id="class_table" class="table table-striped table-bordered" style="margin-top: 0px;">
+                        <tr style="font-weight: 700;background-color: #EBEBE4">
+                            <td colspan="3" style="font-size: 21px;text-align: center;border: transparent !important;"><span class="title">药品类型入库统计表</span></td>
+                        </tr>
+                        <tr style="font-weight: 700;background-color: #EBEBE4">
+                            <td style="text-align: left;border: transparent !important;">统计日期:<span class="dateRange"></span></td>
+                            <td style="text-align: right;border: transparent !important;">库房名称:<span class="groupName"></span></td>
+                            <td style="text-align: right;border: transparent !important;">打印日期:<span class="printDate"></span></td>
+                        </tr>
+                        <tr>
+                            <td class="xtd" style="text-align: center;width: 200px;">药品类型</td>
+                            <td class="xtd" style="text-align: center;width: 200px;">入库金额(购入价)</td>
+                            <td class="xtd" style="text-align: center;width: 200px;">入库金额(零售价)</td>
+                        </tr>
+                    </table>
+                </div>
+            </div>
+        </div>
+    </div>
+</div>
+<!--加载中提示开始-->
+<div id="YWaitDialog"
+     style="
+    position: absolute;
+    margin: auto;
+    display: none;
+    top: 0px;
+    left: 0px;
+    right: 0px;
+    bottom: 0px;
+    height: 60px;
+    width: 300px;">
+    <p style="text-align: center; vertical-align: central;">
+        请等待,正在查询数据<i class="fa fa-spinner fa-spin fa-2x fa-fw"></i>
+    </p>
+</div>
+<!--加载中提示结尾-->
+<object id="LODOP_OB" classid="clsid:2105C259-1E0C-4534-8141-A753534CB4CA" width=0 height=0>
+    <embed id="LODOP_EM" type="application/x-print-lodop" width=0 height=0></embed>
+</object>
+

+ 0 - 2
src/main/resources/templates/yk/drug_purchase_situation.html

@@ -24,8 +24,6 @@
         <div class="x_panel" style="height: 100%">
             <div class="panel-body">
                 <form id="formSearch" class="form-horizontal" autocomplete="off">
-                    <input type="hidden" id="codeSearch">
-                    <input type="hidden" id="serialSearch">
                     <div class="form-group col-md-12 col-sm-12 col-xs-12">
                         <label class="control-label col-md-1 col-sm-1 col-xs-12" for="reportrange"
                                style="width: 105px;">