ソースを参照

各科室甲级,条目缺陷

luolei 5 年 前
コミット
96a3132de1
6 ファイル変更86 行追加13 行削除
  1. 6 0
      src/css/common.less
  2. 6 0
      src/html/jiaji.html
  3. 6 0
      src/html/singleVeto.html
  4. 1 1
      src/js/console.js
  5. 30 4
      src/js/jiaji.js
  6. 37 8
      src/js/singleVeto.js

+ 6 - 0
src/css/common.less

@@ -57,12 +57,18 @@ th[code]{
         line-height: 40px;
         position: relative;
     }
+    .datapickerBox input {
+        margin-right: 0px !important;
+    }
     .iconCalen{
         position: absolute;
         width: 15px;
         top: 10px !important;
         right: 20px;
     }
+    .divide {
+        margin: 0 10px;
+    }
 }
 .dataSelectDark {
     // position: relative;

+ 6 - 0
src/html/jiaji.html

@@ -27,6 +27,12 @@
                     <span>科室名称:</span>
                     <input class="patientNumInp" style="width: 148px;" type="text" placeholder="请输入科室名称">
                 </span>
+                <span class="filterItem typeFilter clearfix dataSelectLight">
+                    <span class="fl">出院日期:</span>
+                    <span class="datapickerBox fl"><input type="text" placeholder="请选择时间" id="datepicker" autocomplete="off" /></span>
+                    <span  class="divide fl">-</span>
+                    <span class="datapickerBox fl"><input type="text" placeholder="请选择时间" id="datepicker2"  autocomplete="off" /></span>
+                </span>
                 <span class="filter">查询</span>
                 <span class="filterclear abnormalClear">重置</span>
             </div>

+ 6 - 0
src/html/singleVeto.html

@@ -45,6 +45,12 @@
                         <li  class="rejectItem" data-name="否" data-id=0>否</li>
                     </ul>
                 </span>
+                <span class="filterItem typeFilter clearfix dataSelectLight">
+                    <span class="fl">出院日期:</span>
+                    <span class="datapickerBox fl"><input type="text" placeholder="请选择时间" id="datepicker" autocomplete="off" /></span>
+                    <span  class="divide fl">-</span>
+                    <span class="datapickerBox fl"><input type="text" placeholder="请选择时间" id="datepicker2"  autocomplete="off" /></span>
+                </span>
                 <span class="filter">查询</span>
                 <span class="filterclear abnormalClear">重置</span>
             </div>

+ 1 - 1
src/js/console.js

@@ -165,7 +165,7 @@ function getDetails(){
     })
     $(".circleB .title").click(function(){
         focusMenuItem("YH-ZKK-TMQXZB_XQ");
-        $(parent.document).find("#contentIframe").attr("src","./singleVeto.html?from=1&special=1&dateType="+dateType)
+        $(parent.document).find("#contentIframe").attr("src","./singleVeto.html?from=1&special=1&shijian="+dateType)
     })
 }
 

+ 30 - 4
src/js/jiaji.js

@@ -2,7 +2,7 @@ const $ = require('jquery');
 require("../css/jiaji.less");
 require('./modal.js');
 const {api} = require('./api.js')
-const {post,getCookie,getUrlArgObjectNew,emptyBox} = require('./utils.js')
+const {post,getCookie,getUrlArgObjectNew,emptyBox,setDatePicker,getPickerDate} = require('./utils.js')
 require('./../resource/jquery-ui/jquery-ui.min.js');
 require('./../resource/jquery-ui/jquery-ui.min.css');
 const iconCheck= require("./../images/icon_check.png")
@@ -31,6 +31,7 @@ if(statisticsType == 1){
         color:'#00A1FF',
         backgroundColor:'#fff'
     })
+    setDatePicker($("#datepicker"),$("#datepicker2"),1)
 }else{
     $(".monthYear .year").css({
         backgroundColor:'#00A1FF',
@@ -39,9 +40,11 @@ if(statisticsType == 1){
         color:'#00A1FF',
         backgroundColor:'#fff'
     })
+    setDatePicker($("#datepicker"),$("#datepicker2"),2)
 }
 $(".abnormalClear").click(function(){
     behospitalCode =behospitalCodeTemp= ""
+    setDatePicker($("#datepicker"),$("#datepicker2"),statisticsType||2)
     $(".patientNumInp").val("")
     getTabData(1)
 })
@@ -75,6 +78,7 @@ function dateChange(){
         $(".dayDetail .deptListWrap").css("display","block")
         $(".dayDetail .dayFilter").css("display","none")
         statisticsType = 1
+        setDatePicker($("#datepicker"),$("#datepicker2"),1)
         getTabData(1)
     })
     $(".monthYear .year").click(function(){
@@ -88,6 +92,7 @@ function dateChange(){
         $(".dayDetail .deptListWrap").css("display","none")
         $(".dayDetail .dayFilter").css("display","block")
         statisticsType = 2
+        setDatePicker($("#datepicker"),$("#datepicker2"),2)
         getTabData(1)
     })
 }
@@ -104,12 +109,22 @@ function dateChange(){
     return false;
 }
 function getTabData(activePage){
+    const dateStatrt = getPickerDate($("#datepicker"),1)
+    const dateEnd = getPickerDate($("#datepicker2"),2)
+    const start = new Date(dateStatrt).getTime()
+    const end = new Date(dateEnd).getTime()
+    if(start > end){
+        $.alerModal({"message":'开始时间不能大于结束时间~',type:"tip",time:'1000',isFather: true, fatherWrapper: $("#mainBox", parent.document)});
+        return
+    }
     const param = {
         current:activePage,
         size: 15,
         name: behospitalCode||"",
         type: statisticsType||2, //1-本月,2-本年
         dateType: level||"",//(3-上月,4-去年本月,5-去年(必填))
+        "startDate":dateStatrt,
+        "endDate":dateEnd
     }
     post(api.levelPercentGroupByDeptPage,param).then(res =>{
         if(res.data.code == '0'){
@@ -547,6 +562,17 @@ $(document).on("click", function(){
     $(".selectLevel .arrow").attr("src",iconDown)
     
 })
-
-$((function($){
-})($));
+$(function() {
+    const  iconCalenBlue= require("./../images/darkDate.png")
+    const  iconCalenGrey= require("./../images/icon_calen_grey.png")
+    $('.datapickerBox').append(`<img class="iconCalen" src=${iconCalenGrey} />`)
+    $('.iconCalen').on("mouseenter", function(e){
+        $(this).attr("src", iconCalenBlue)
+    })
+    $('.iconCalen').on("mouseleave", function(e){
+        $(this).attr("src", iconCalenGrey)
+    })
+    $('.iconCalen').on("click", function(e){
+        $(this).parent().find("input").focus()
+    })
+});

+ 37 - 8
src/js/singleVeto.js

@@ -3,7 +3,7 @@ require("../css/tiaomu.less");
 require('./../resource/jquery-ui/jquery-ui.min.js');
 require('./modal.js');
 const {api} = require('./api.js')
-const {post,getCookie,getUrlArgObjectNew,emptyBox,focusMenuItem} = require('./utils.js')
+const {post,getCookie,getUrlArgObjectNew,emptyBox,focusMenuItem,setDatePicker,getPickerDate} = require('./utils.js')
 const switchIconOpen = require("./../images/btn_open.png")
 const switchIconClose = require("./../images/btn_close.png")
 const iconDown= require("./../images/arrow_down.png")
@@ -45,7 +45,6 @@ $(function(){
     if(from == 2){
         $(".partTitle a").attr("href","deptConsole.html").html("控制台(科室) / ")
     }
-    getTabData(1)//条目缺陷
     $(".partTitle a").click(function(){
         //初始菜单选中
         $(".managerContainer").remove()
@@ -58,6 +57,7 @@ $(function(){
     })
     $(".abnormalClear").click(function(){
         // window.location.reload()
+        setDatePicker($("#datepicker"),$("#datepicker2"),isReject||2)
         $(".selectModuleType").html("全部")
         $(".selectReject").html("全部")
         $(".selectModuleType").append(`<img class="arrow" src=${iconDown} alt="下拉">`)
@@ -78,6 +78,7 @@ $(function(){
             color:'#00A1FF',
             backgroundColor:'#fff'
         })
+        setDatePicker($("#datepicker"),$("#datepicker2"),1)
     }else{
         $(".monthYear .year").css({
             backgroundColor:'#00A1FF',
@@ -86,7 +87,9 @@ $(function(){
             color:'#00A1FF',
             backgroundColor:'#fff'
         })
+        setDatePicker($("#datepicker"),$("#datepicker2"),2)
     }
+    getTabData(1)//条目缺陷
 })
 bindDeptSelect()
 //科室选择
@@ -135,6 +138,14 @@ function getDeptList(){
     $(".tiaomu .filterDropList").html(str)
 }
 function getTabData(activePage){
+    const dateStatrt = getPickerDate($("#datepicker"),1)
+    const dateEnd = getPickerDate($("#datepicker2"),2)
+    const start = new Date(dateStatrt).getTime()
+    const end = new Date(dateEnd).getTime()
+    if(start > end){
+        $.alerModal({"message":'开始时间不能大于结束时间~',type:"tip",time:'1000',isFather: true, fatherWrapper: $("#mainBox", parent.document)});
+        return
+    }
     const param = {
         current:activePage,
         type: isReject,
@@ -143,7 +154,9 @@ function getTabData(activePage){
         isReject:isSingleReject, //是否单项否决
         name: name, //条目名
         deptName: deptId, //科室名
-        size: 15
+        size: 15,
+        "startDate":dateStatrt,
+        "endDate":dateEnd
     }
     post(from == 1?api.entryGroupByEntryInnerPage:api.entryGroupByEntryAndDeptInnerPage,param).then(res =>{
         if(res.data.code == '0'){
@@ -171,8 +184,8 @@ function dateChange(){
             color:'#00A1FF',
             backgroundColor:'#fff'
         })
-        isRejectTemp = 1
-        isReject = 1
+        isRejectTemp = isReject = 1
+        setDatePicker($("#datepicker"),$("#datepicker2"),1)
         getTabData(1)
     })
     $(".monthYear .year").click(function(){
@@ -183,8 +196,8 @@ function dateChange(){
             color:'#00A1FF',
             backgroundColor:'#fff'
         })
-        isRejectTemp = 2
-        isReject = 2
+        isRejectTemp =  isReject = 2
+        setDatePicker($("#datepicker"),$("#datepicker2"),2)
         getTabData(1)
     })
 }
@@ -526,4 +539,20 @@ $(document).on("click", function(){
     $(".selectModuleType .arrow").attr("src",iconDown)
     $(".selectReject .arrow").attr("src",iconDown)
     $(".selectUsed .arrow").attr("src",iconDown)
-})
+})
+
+
+$(function() {
+    const  iconCalenBlue= require("./../images/darkDate.png")
+    const  iconCalenGrey= require("./../images/icon_calen_grey.png")
+    $('.datapickerBox').append(`<img class="iconCalen" src=${iconCalenGrey} />`)
+    $('.iconCalen').on("mouseenter", function(e){
+        $(this).attr("src", iconCalenBlue)
+    })
+    $('.iconCalen').on("mouseleave", function(e){
+        $(this).attr("src", iconCalenGrey)
+    })
+    $('.iconCalen').on("click", function(e){
+        $(this).parent().find("input").focus()
+    })
+});