Pārlūkot izejas kodu

病案首页完事

luolei 5 gadi atpakaļ
vecāks
revīzija
b3df3f9929

+ 21 - 0
src/css/common.less

@@ -36,6 +36,27 @@ input:disabled {
     border:10px @disColor solid;
 }
 
+th[code]{
+    cursor: pointer;
+    &:after{
+        content:"";
+        display:inline-block;
+        width: 11px;
+        height: 14px;
+        margin-left: 4px;
+        vertical-align: middle;
+        background-size: 100%;
+        background-image: url("../images/grey.png");
+    }
+    &.asc:after{
+        background: url("../images/up_blue.png");
+        background-size: 100%;
+    }
+    &.desc:after{
+        background: url("../images/down_blue.png");
+        background-size: 100%;
+    }
+}
 .selectDates {
 
 }

+ 0 - 18
src/css/partDetail.less

@@ -53,24 +53,6 @@
         th{
             white-space: nowrap;
         }
-        th[code]{
-            cursor: pointer;
-            &:after{
-                content:"";
-                display:inline-block;
-                width: 11px;
-                height: 14px;
-                margin-left: 4px;
-                vertical-align: middle;
-                background: url("../images/grey.png");
-            }
-            &.asc:after{
-                background: url("../images/up_blue.png");
-            }
-            &.desc:after{
-                background: url("../images/down_blue.png");
-            }
-        }
         td{
             white-space: nowrap;
         }

+ 0 - 18
src/css/partDetailControl.less

@@ -53,24 +53,6 @@
         th{
             white-space: nowrap;
         }
-        th[code]{
-            cursor: pointer;
-            &:after{
-                content:"";
-                display:inline-block;
-                width: 11px;
-                height: 14px;
-                margin-left: 4px;
-                vertical-align: middle;
-                background: url("../images/grey.png");
-            }
-            &.asc:after{
-                background: url("../images/up_blue.png");
-            }
-            &.desc:after{
-                background: url("../images/down_blue.png");
-            }
-        }
         td{
             white-space: nowrap;
         }

+ 9 - 9
src/html/partDetail.html

@@ -47,15 +47,15 @@
                 <table>
                     <thead>
                     <th class="moduleName" style="width: 65px;">序号</th>
-                    <th class="beHospitalId textCenter">主管医生</th>
-                    <th class="beHospitalId textCenter">缺陷总数</th>
-                    <th class="beHospitalId textCenter">合格率</th>
-                    <th class="beHospitalId textCenter">空项数</th>
-                    <th class="beHospitalId textCenter">完整率</th>
-                    <th class="beHospitalId textCenter">错误数</th>
-                    <th class="beHospitalId textCenter">完善率</th>
-                    <th class="beHospitalId textCenter">质控平均分</th>
-                    <th class="beHospitalId textCenter">质控病历数</th>
+                    <th class="beHospitalId textCenter" code="deptName">主管医生</th>
+                    <th class="beHospitalId textCenter" code="entryNum">缺陷总数</th>
+                    <th class="beHospitalId textCenter" code="firstLevelPercent">合格率</th>
+                    <th class="beHospitalId textCenter" code="emptyNum">空项数</th>
+                    <th class="beHospitalId textCenter" code="emptyPercent">完整率</th>
+                    <th class="beHospitalId textCenter" code="errorNum">错误数</th>
+                    <th class="beHospitalId textCenter" code="errorPercent">完善率</th>
+                    <th class="beHospitalId textCenter" code="averageValue">质控平均分</th>
+                    <th class="beHospitalId textCenter" code="mrNum">质控病历数</th>
                     </thead>
                     <tbody>
 

+ 9 - 9
src/html/partDetailControl.html

@@ -43,15 +43,15 @@
                 <table>
                     <thead>
                         <th class="moduleName" style="width: 65px;">序号</th>
-                        <th class="beHospitalId textCenter">科室名称</th>
-                        <th class="beHospitalId textCenter">缺陷总数</th>
-                        <th class="beHospitalId textCenter">合格率</th>
-                        <th class="beHospitalId textCenter">空项数</th>
-                        <th class="beHospitalId textCenter">完整率</th>
-                        <th class="beHospitalId textCenter">错误数</th>
-                        <th class="beHospitalId textCenter">完善率</th>
-                        <th class="beHospitalId textCenter">质控平均分</th>
-                        <th class="beHospitalId textCenter">质控病历数</th>
+                        <th class="beHospitalId textCenter" code="deptName">科室名称</th>
+                        <th class="beHospitalId textCenter" code="entryNum">缺陷总数</th>
+                        <th class="beHospitalId textCenter" code="firstLevelPercent">合格率</th>
+                        <th class="beHospitalId textCenter" code="emptyNum">空项数</th>
+                        <th class="beHospitalId textCenter" code="emptyPercent">完整率</th>
+                        <th class="beHospitalId textCenter" code="errorNum">错误数</th>
+                        <th class="beHospitalId textCenter" code="errorPercent">完善率</th>
+                        <th class="beHospitalId textCenter" code="averageValue">质控平均分</th>
+                        <th class="beHospitalId textCenter" code="mrNum">质控病历数</th>
                     </thead>
                     <tbody>
 

+ 6 - 5
src/js/console.js

@@ -92,7 +92,7 @@ $(function(){
             getAverageScoreLis()
             $(this).parent().slideToggle().prev().find("span").html(str+"系统")
         }else if(type == 7){//病案首页
-            deptType="合格率"
+            lineType="合格率"
             lineChartHome(lineType4,lineType1)
             $(this).parent().slideToggle().prev().find("span").html(str)
         }else if(type == 8){//病案首页
@@ -384,8 +384,8 @@ function getBarData(type){
                 lineType2 = dataY2.sort(function(a, b){return b - a})
                 lineType3 = dataY3.sort(function(a, b){return b - a})
                 lineType4 = dataX
-                
-                lineChartHome(dataX,lineType == "合格率"?lineType1:lineType=="完整率"?lineType2:lineType3)
+                let datay = (lineType == "合格率")?lineType1:(lineType=="完整率"?lineType2:lineType3)
+                lineChartHome(dataX,datay)
             }
         })
     }
@@ -820,8 +820,9 @@ function lineChartHome(dataX,dataY){
     $(window).resize(function(){
         myCharts.resize()
     });
+    console.log(lineType)
     option = {
-        color:['#00A1FF','#FF2B92','#3EFFD1'],   
+        color:(lineType == "合格率")?'#00A1FF':(lineType=="完整率"?'#FF2B92':'#3EFFD1'),   
         title: {
             text: '百分比',
             top: 15,
@@ -840,7 +841,7 @@ function lineChartHome(dataX,dataY){
             },
             formatter: function(param) {           
                 return `<div style="color:#fff;">${param[0].name}<br>
-                    <i style="background:#00A1FF;margin-right:5px;display:inline-block;width:8px;height:8px;border-radius:50%"></i>病案首页${lineType}:${param[0]&&param[0].value}%<br>
+                    <i style="background:${(lineType == "合格率")?'#00A1FF':(lineType=="完整率"?'#FF2B92':'#3EFFD1')};margin-right:5px;display:inline-block;width:8px;height:8px;border-radius:50%"></i>病案首页${lineType}:${param[0]&&param[0].value}%<br>
                 </div>`
             }
         },

+ 8 - 8
src/js/partDetail.js

@@ -19,7 +19,7 @@ $(".selectLevel").append(`<img class="arrow" src=${iconDown} alt="下拉">`)
 $(".selectDept").append(`<img class="arrow" src=${iconDown} alt="下拉">`)
 let tabList = [], name = "", behospitalCode="", behosDateStart="", level="",behosDateEnd="", scoreSum = 0,statisticsType=2,
   nameTemp = "", behospitalCodeTemp="",levelTemp="", deptId="",deptIdTemp="", doctorName="", doctorNum="",doctorNameTemp="",doctorNumTemp="",
-  data_desc=[],data_asc=[];
+  data_desc='',data_asc='';
 let deptList = JSON.parse(getCookie("deptList"))||[]
 $(function(){
     let srcUrl = $("#contentIframe",parent.document).attr("src")
@@ -150,8 +150,8 @@ function dateChange(){
 }
 function getTabData(activePage){
     const param = {
-        "asc": "",
-        "desc": "",
+        "asc": data_asc,
+        "desc": data_desc,
         "deptName": deptId||"",
         "name": behospitalCode||"",
         "type": statisticsType||2, //1-本月,2-本年
@@ -431,14 +431,14 @@ $('.recordScoreBtn').on("click",function(e){
 })
 $("th[code]").on("click",function(e){
     const code=$(this).attr("code");
-    if(data_asc[0]===code){
-      data_desc=[code];
-      data_asc=[];
+    if(data_asc===code){
+      data_desc=code;
+      data_asc='';
       $("th[code]").removeClass("asc desc");
       $(this).addClass("desc");
     }else{
-      data_desc=[];
-      data_asc=[code];
+      data_desc='';
+      data_asc=code;
       $("th[code]").removeClass("asc desc");
       $(this).addClass("asc");
     }

+ 10 - 9
src/js/partDetailControl.js

@@ -19,7 +19,7 @@ $(".selectLevel").append(`<img class="arrow" src=${iconDown} alt="下拉">`)
 $(".selectDept").append(`<img class="arrow" src=${iconDown} alt="下拉">`)
 let tabList = [], name = "", behospitalCode="", behosDateStart="", level="",behosDateEnd="", scoreSum = 0,statisticsType=2,
   nameTemp = "", behospitalCodeTemp="",levelTemp="", deptId="",deptIdTemp="", doctorName="", doctorNum="",doctorNameTemp="",doctorNumTemp="",
-  data_desc=[],data_asc=[];
+  data_desc="",data_asc="";
   let srcUrl = $("#contentIframe",parent.document).attr("src")
   statisticsType = getUrlArgObjectNew("dateType",srcUrl)||""
   from = getUrlArgObjectNew("from",srcUrl)||""
@@ -42,7 +42,8 @@ let tabList = [], name = "", behospitalCode="", behosDateStart="", level="",beho
       })
   }
 $(".abnormalClear").click(function(){
-    // window.location.reload()
+    data_desc=""
+    data_asc=""
     $(".patientNumInp").val("")
     behospitalCode =behospitalCodeTemp= ""
     getTabData(1)
@@ -107,10 +108,10 @@ function dateChange(){
 }
 function getTabData(activePage){
     const param = {
-        "asc": "",
-        "desc": "",
         "level": deptId||"",
         "name": behospitalCode||"",
+        "asc":data_asc,     //升序
+        "desc":data_desc,       //降序
         "type": statisticsType||2, //1-本月,2-本年
     }
     post(api.homePageLevelStatistics,param).then(res =>{
@@ -397,14 +398,14 @@ $('.recordScoreBtn').on("click",function(e){
 })
 $("th[code]").on("click",function(e){
     const code=$(this).attr("code");
-    if(data_asc[0]===code){
-      data_desc=[code];
-      data_asc=[];
+    if(data_asc==code){
+      data_desc=code;
+      data_asc="";
       $("th[code]").removeClass("asc desc");
       $(this).addClass("desc");
     }else{
-      data_desc=[];
-      data_asc=[code];
+      data_desc="";
+      data_asc=code;
       $("th[code]").removeClass("asc desc");
       $(this).addClass("asc");
     }