XMLWAN преди 4 години
родител
ревизия
cde91ad1e2

+ 5 - 3
src/api/common/common.js Целия файл

149
     startime: startime,
149
     startime: startime,
150
     endtime: endtime
150
     endtime: endtime
151
   }
151
   }
152
-
152
+  console.log('params', params)
153
   return request({
153
   return request({
154
     url: '/com/api/gettotallapsecount',
154
     url: '/com/api/gettotallapsecount',
155
     method: 'get',
155
     method: 'get',
174
     startime: startime,
174
     startime: startime,
175
     endtime: endtime
175
     endtime: endtime
176
   }
176
   }
177
+  console.log('传染病', params)
177
   return request({
178
   return request({
178
     url: '/com/api/gettoalinfectiouscount',
179
     url: '/com/api/gettoalinfectiouscount',
179
     method: 'get',
180
     method: 'get',
282
   })
283
   })
283
 }
284
 }
284
 
285
 
285
-export function getInspectionTotalCount(startime, endtime) {
286
+export function getInspectionTotalCount(startime, endtime, patientid) {
286
   const params = {
287
   const params = {
287
     startime: startime,
288
     startime: startime,
288
-    endtime: endtime
289
+    endtime: endtime,
290
+    patientid: patientid
289
   }
291
   }
290
   return request({
292
   return request({
291
     url: '/com/api/getinspectiontotalcount',
293
     url: '/com/api/getinspectiontotalcount',

+ 33 - 33
src/xt_pages/qcd/basicInformationAnalysis.vue Целия файл

380
       this.listQuery.state = state;
380
       this.listQuery.state = state;
381
       //获取本月当前机构的透析模式
381
       //获取本月当前机构的透析模式
382
       const startDate = moment().subtract('month', 0).format('YYYY-MM') + '-01'
382
       const startDate = moment().subtract('month', 0).format('YYYY-MM') + '-01'
383
-    //  console.log("开始时间",startDate)
383
+      console.log("开始时间",startDate)
384
       const endDate = moment(new Date()).format('YYYY-MM-DD')
384
       const endDate = moment(new Date()).format('YYYY-MM-DD')
385
-     // console.log("结束时间",endDate)
385
+      console.log("结束时间",endDate)
386
       var now = new Date()
386
       var now = new Date()
387
       var nowMonth = now.getMonth(); //当前月
387
       var nowMonth = now.getMonth(); //当前月
388
       var nowYear = now.getFullYear(); //当前年
388
       var nowYear = now.getFullYear(); //当前年
399
        //统计透析总量
399
        //统计透析总量
400
         this.getDialysisModeType(startDate,endDate)
400
         this.getDialysisModeType(startDate,endDate)
401
         //统计转归状态
401
         //统计转归状态
402
-        this.getTotalLapseCount(timeStar,timeEnd)
402
+        this.getTotalLapseCount(startDate,endDate)
403
         //统计男女比例
403
         //统计男女比例
404
         this.getTotalSexCount(timeStar,timeEnd)
404
         this.getTotalSexCount(timeStar,timeEnd)
405
         //统计传染病
405
         //统计传染病
406
-        this.getTotalInfectiousCount(timeStar,timeEnd)
406
+        this.getTotalInfectiousCount(startDate,endDate)
407
         //统计年龄
407
         //统计年龄
408
         this.getTotalAgeCount(timeStar,timeEnd)
408
         this.getTotalAgeCount(timeStar,timeEnd)
409
         //统计透析年龄
409
         //统计透析年龄
412
       //近三月
412
       //近三月
413
       if(state == 1){
413
       if(state == 1){
414
         const startDate = moment().subtract('month', 3).format('YYYY-MM-DD')
414
         const startDate = moment().subtract('month', 3).format('YYYY-MM-DD')
415
-        console.log("三月前",startDate)
415
+        // console.log("三月前",startDate)
416
         var startunitx = Date.parse(startDate)/1000
416
         var startunitx = Date.parse(startDate)/1000
417
-        console.log("开始时间搓",startunitx)
417
+        // console.log("开始时间搓",startunitx)
418
         const endDate = moment(new Date()).format('YYYY-MM-DD')
418
         const endDate = moment(new Date()).format('YYYY-MM-DD')
419
-        console.log("结束时间",endDate)
419
+        // console.log("结束时间",endDate)
420
          var endunitx = Date.parse(endDate)/1000
420
          var endunitx = Date.parse(endDate)/1000
421
-        console.log("日期时间搓",endunitx)
421
+        // console.log("日期时间搓",endunitx)
422
          //统计透析总量
422
          //统计透析总量
423
         this.getDialysisModeType(startDate,endDate)
423
         this.getDialysisModeType(startDate,endDate)
424
          //统计转归状态
424
          //统计转归状态
425
-        this.getTotalLapseCount(startunitx,endunitx)
425
+        this.getTotalLapseCount(startDate,endDate)
426
         //统计男女比例
426
         //统计男女比例
427
         this.getTotalSexCount(startunitx,endunitx)
427
         this.getTotalSexCount(startunitx,endunitx)
428
         //统计传染病
428
         //统计传染病
429
-        this.getTotalInfectiousCount(startunitx,endunitx)
429
+        this.getTotalInfectiousCount(startDate,endDate)
430
         //统计年龄
430
         //统计年龄
431
         this.getTotalAgeCount(startunitx,endunitx)
431
         this.getTotalAgeCount(startunitx,endunitx)
432
         //统计透析年龄
432
         //统计透析年龄
436
      //近半年
436
      //近半年
437
      if(state == 2){
437
      if(state == 2){
438
         const startDate = moment().subtract('month', 6).format('YYYY-MM-DD')
438
         const startDate = moment().subtract('month', 6).format('YYYY-MM-DD')
439
-        console.log("6月前",startDate)
439
+        // console.log("6月前",startDate)
440
         var startunitx = Date.parse(startDate)/1000
440
         var startunitx = Date.parse(startDate)/1000
441
-        console.log("开始时间搓",startunitx)
441
+        // console.log("开始时间搓",startunitx)
442
         const endDate = moment(new Date()).format('YYYY-MM-DD')
442
         const endDate = moment(new Date()).format('YYYY-MM-DD')
443
-        console.log("结束时间",endDate)
443
+        // console.log("结束时间",endDate)
444
          var endunitx = Date.parse(endDate)/1000
444
          var endunitx = Date.parse(endDate)/1000
445
-        console.log("日期时间搓",endunitx)
445
+        // console.log("日期时间搓",endunitx)
446
          //统计透析总量
446
          //统计透析总量
447
         this.getDialysisModeType(startDate,endDate)
447
         this.getDialysisModeType(startDate,endDate)
448
          //统计转归状态
448
          //统计转归状态
449
-        this.getTotalLapseCount(startunitx,endunitx)
449
+        this.getTotalLapseCount(startDate,endDate)
450
         //统计男女比例
450
         //统计男女比例
451
         this.getTotalSexCount(startunitx,endunitx)
451
         this.getTotalSexCount(startunitx,endunitx)
452
         //统计传染病
452
         //统计传染病
453
-        this.getTotalInfectiousCount(startunitx,endunitx)
453
+        this.getTotalInfectiousCount(startDate,endDate)
454
         //统计年龄
454
         //统计年龄
455
         this.getTotalAgeCount(startunitx,endunitx)
455
         this.getTotalAgeCount(startunitx,endunitx)
456
         //统计透析年龄
456
         //统计透析年龄
460
      //近一年
460
      //近一年
461
      if(state == 3){
461
      if(state == 3){
462
         const startDate = moment().subtract('month', 12).format('YYYY-MM-DD')
462
         const startDate = moment().subtract('month', 12).format('YYYY-MM-DD')
463
-        console.log("6月前",startDate)
463
+        // console.log("6月前",startDate)
464
         var startunitx = Date.parse(startDate)/1000
464
         var startunitx = Date.parse(startDate)/1000
465
-        console.log("开始时间搓",startunitx)
465
+        // console.log("开始时间搓",startunitx)
466
         const endDate = moment(new Date()).format('YYYY-MM-DD')
466
         const endDate = moment(new Date()).format('YYYY-MM-DD')
467
-        console.log("结束时间",endDate)
467
+        // console.log("结束时间",endDate)
468
          var endunitx = Date.parse(endDate)/1000
468
          var endunitx = Date.parse(endDate)/1000
469
-        console.log("日期时间搓",endunitx)
469
+        // console.log("日期时间搓",endunitx)
470
          //统计透析总量
470
          //统计透析总量
471
         this.getDialysisModeType(startDate,endDate)
471
         this.getDialysisModeType(startDate,endDate)
472
          //统计转归状态
472
          //统计转归状态
473
-        this.getTotalLapseCount(startunitx,endunitx)
473
+        this.getTotalLapseCount(startDate,endDate)
474
         //统计男女比例
474
         //统计男女比例
475
         this.getTotalSexCount(startunitx,endunitx)
475
         this.getTotalSexCount(startunitx,endunitx)
476
         //统计传染病
476
         //统计传染病
477
-        this.getTotalInfectiousCount(startunitx,endunitx)
477
+        this.getTotalInfectiousCount(startDate,endDate)
478
         //统计年龄
478
         //统计年龄
479
         this.getTotalAgeCount(startunitx,endunitx)
479
         this.getTotalAgeCount(startunitx,endunitx)
480
         //统计透析年龄
480
         //统计透析年龄
489
          if(response.data.state == 1){
489
          if(response.data.state == 1){
490
           var modetype =  response.data.data.modetype
490
           var modetype =  response.data.data.modetype
491
             var total =  response.data.data.total
491
             var total =  response.data.data.total
492
-            console.log("total",total)
492
+            // console.log("total",total)
493
             this.total = total
493
             this.total = total
494
            this.modetype = modetype
494
            this.modetype = modetype
495
-           console.log("modetype",modetype)
495
+          //  console.log("modetype",modetype)
496
 
496
 
497
          }
497
          }
498
       })
498
       })
503
          if(response.data.state == 1){
503
          if(response.data.state == 1){
504
           var patients =  response.data.data.patients
504
           var patients =  response.data.data.patients
505
           this.rollOutTotal = patients.length
505
           this.rollOutTotal = patients.length
506
-          console.log("留治病人长度",patients.length)
506
+          // console.log("留治病人长度",patients.length)
507
           var patienttwo = response.data.data.patienttwo
507
           var patienttwo = response.data.data.patienttwo
508
           this.outTotal = patienttwo.length
508
           this.outTotal = patienttwo.length
509
-            console.log("转出长度", this.outTotal)
509
+            // console.log("转出长度", this.outTotal)
510
           var count = response.data.data.count
510
           var count = response.data.data.count
511
           this.patientCount = count
511
           this.patientCount = count
512
          }
512
          }
532
        getTotalInfectiousCount(timeStar,timeEnd).then(response=>{
532
        getTotalInfectiousCount(timeStar,timeEnd).then(response=>{
533
            if(response.data.state === 1){
533
            if(response.data.state === 1){
534
              this.InfectiousTotal = response.data.data.total
534
              this.InfectiousTotal = response.data.data.total
535
-             console.log("===",this.InfectiousTotal)
535
+            //  console.log("===",this.InfectiousTotal)
536
              var infectious = response.data.data.count
536
              var infectious = response.data.data.count
537
-             console.log("infectious",infectious)
537
+            //  console.log("infectious",infectious)
538
              var otherTotal = response.data.data.otherTotal
538
              var otherTotal = response.data.data.otherTotal
539
-             console.log("otherTotal",otherTotal)
539
+            //  console.log("otherTotal",otherTotal)
540
              this.otherTotal = otherTotal
540
              this.otherTotal = otherTotal
541
               var arr = [
541
               var arr = [
542
                 {count:0,disease_id:2},
542
                 {count:0,disease_id:2},
559
       getTotalAgeCount(timeStar,timeEnd).then(response=>{
559
       getTotalAgeCount(timeStar,timeEnd).then(response=>{
560
          if(response.data.state == 1){
560
          if(response.data.state == 1){
561
           var ageCount =  response.data.data.ageCount
561
           var ageCount =  response.data.data.ageCount
562
-          console.log("ageCount",ageCount)
562
+          // console.log("ageCount",ageCount)
563
           var arr = []
563
           var arr = []
564
           arr =  ageCount.sort(this.compare('age'))
564
           arr =  ageCount.sort(this.compare('age'))
565
           this.ageCount = arr
565
           this.ageCount = arr
595
       getTotalDialysisCount(timeStar,timeEnd).then(response=>{
595
       getTotalDialysisCount(timeStar,timeEnd).then(response=>{
596
          if(response.data.state == 1){
596
          if(response.data.state == 1){
597
            var dataage =  response.data.data.dataage
597
            var dataage =  response.data.data.dataage
598
-           console.log("dataage",dataage)
598
+          //  console.log("dataage",dataage)
599
            this.dialysisAge = dataage
599
            this.dialysisAge = dataage
600
 
600
 
601
          }
601
          }
605
   created() {
605
   created() {
606
         //获取本月当前机构的透析模式
606
         //获取本月当前机构的透析模式
607
       const startDate = moment().subtract('month', 0).format('YYYY-MM') + '-01'
607
       const startDate = moment().subtract('month', 0).format('YYYY-MM') + '-01'
608
-      console.log("开始时间",startDate)
608
+      // console.log("开始时间",startDate)
609
       const endDate = moment(new Date()).format('YYYY-MM-DD')
609
       const endDate = moment(new Date()).format('YYYY-MM-DD')
610
      // console.log("结束时间",endDate)
610
      // console.log("结束时间",endDate)
611
       var now = new Date()
611
       var now = new Date()
626
       //统计男女比例
626
       //统计男女比例
627
       this.getTotalSexCount(timeStar,timeEnd)
627
       this.getTotalSexCount(timeStar,timeEnd)
628
       //统计传染病
628
       //统计传染病
629
-      this.getTotalInfectiousCount(timeStar,timeEnd)
629
+      this.getTotalInfectiousCount(startDate,endDate)
630
       //统计年龄
630
       //统计年龄
631
       this.getTotalAgeCount(timeStar,timeEnd)
631
       this.getTotalAgeCount(timeStar,timeEnd)
632
       //统计透析年龄
632
       //统计透析年龄

+ 4 - 1
src/xt_pages/qcd/indicatorControlAnalysis/process.vue Целия файл

586
       },
586
       },
587
       getModeName(mode_id) {
587
       getModeName(mode_id) {
588
         return this.$store.getters.treatment_mode[mode_id] != undefined ? this.$store.getters.treatment_mode[mode_id].name : ''
588
         return this.$store.getters.treatment_mode[mode_id] != undefined ? this.$store.getters.treatment_mode[mode_id].name : ''
589
-      }, GetDialysisProcessIndexTableData(params) {
589
+      }, 
590
+      GetDialysisProcessIndexTableData(params) {
590
         this.loading = true
591
         this.loading = true
591
         GetDialysisProcessIndexTableData(params)
592
         GetDialysisProcessIndexTableData(params)
592
           .then(rs => {
593
           .then(rs => {
593
             var resp = rs.data
594
             var resp = rs.data
595
+            console.log("resp=====",resp)
594
             if (resp.state == 1) {
596
             if (resp.state == 1) {
595
               this.loading = false
597
               this.loading = false
596
               this.tableData = []
598
               this.tableData = []
617
           GetDialysisProcessIndexChartData(params)
619
           GetDialysisProcessIndexChartData(params)
618
           .then(rs => {
620
           .then(rs => {
619
             var resp = rs.data
621
             var resp = rs.data
622
+            console.log("resp",resp)
620
             if (resp.state == 1) {
623
             if (resp.state == 1) {
621
               if (this.query.statistics_type != 9 && this.query.statistics_type != 10) {
624
               if (this.query.statistics_type != 9 && this.query.statistics_type != 10) {
622
                 for (let i = 0; i < resp.data.data.length; i++) {
625
                 for (let i = 0; i < resp.data.data.length; i++) {

+ 14 - 5
src/xt_pages/qcd/officesControlAnalysis/project.vue Целия файл

46
         <p class="pointTitle">指标正常范围值</p>
46
         <p class="pointTitle">指标正常范围值</p>
47
       </div>
47
       </div>
48
       <div class="cell clearfix newDisplay">
48
       <div class="cell clearfix newDisplay">
49
-        <span class="index" v-for="(item,index) in normdata" :key="index ">{{item.item_name}}({{item.min_range}}-{{item.large_range}})</span>
49
+        <span class="index" v-for="(item,index) in normdata" :key="index ">
50
+          <span v-if="item.range_type == 1">{{item.item_name}}({{item.min_range}}-{{item.large_range}})</span> 
51
+          <span v-if="item.range_type == 2">{{item.item_name}}({{item.range_value}})</span> 
52
+        </span>
50
       </div>
53
       </div>
51
     </div>
54
     </div>
52
   </div>
55
   </div>
106
       lapseto:0,
109
       lapseto:0,
107
       type:1,
110
       type:1,
108
       mode_type:"",
111
       mode_type:"",
112
+      range_type:"",
109
       chart: {
113
       chart: {
110
         title: {
114
         title: {
111
           text: "ECharts 入门示例"
115
           text: "ECharts 入门示例"
273
         //第四季度
277
         //第四季度
274
          const four_qurter_start = moment().month(9).startOf('month').format("YYYY-MM-DD")
278
          const four_qurter_start = moment().month(9).startOf('month').format("YYYY-MM-DD")
275
          const four_qurter_end = moment().month(11).endOf('month').format("YYYY-MM-DD")
279
          const four_qurter_end = moment().month(11).endOf('month').format("YYYY-MM-DD")
276
- 
277
-     
280
+         console.log("this.modetype",this.mode_type)
281
+         for(let i=0;i<this.normdata.length;i++){
282
+            if(this.normdata[i].inspection_minor == this.mode_type){
283
+               this.range_type = this.normdata[i].range_type
284
+            }
285
+         }
278
          const params = {
286
          const params = {
279
            lapseto:this.lapseto,
287
            lapseto:this.lapseto,
280
            itemtype:this.type,
288
            itemtype:this.type,
289
            three_qurter_end:three_qurter_end,
297
            three_qurter_end:three_qurter_end,
290
            four_qurter_start:four_qurter_start,
298
            four_qurter_start:four_qurter_start,
291
            four_qurter_end:four_qurter_end,
299
            four_qurter_end:four_qurter_end,
300
+           range_type:this.range_type
292
          }
301
          }
293
       getProjectList(params).then(response=>{
302
       getProjectList(params).then(response=>{
294
         if(response.data.state === 1){
303
         if(response.data.state === 1){
295
           var list = response.data.data.list
304
           var list = response.data.data.list
296
-      
305
+          console.log("list",list)
297
           var standList =  response.data.data.standList
306
           var standList =  response.data.data.standList
298
-         
307
+          console.log("standlist",standList)
299
           var newArr = [
308
           var newArr = [
300
             {Total:"第一季度",Count:1,NoCount: 0},
309
             {Total:"第一季度",Count:1,NoCount: 0},
301
             {Total:"第二季度",Count:1,NoCount: 0},
310
             {Total:"第二季度",Count:1,NoCount: 0},

+ 15 - 4
src/xt_pages/qcd/officesControlAnalysis/time.vue Целия файл

91
         <p class="pointTitle">指标正常范围值</p>
91
         <p class="pointTitle">指标正常范围值</p>
92
       </div>
92
       </div>
93
       <div class="cell clearfix newDisplay">
93
       <div class="cell clearfix newDisplay">
94
-         <span v-for="(item,index) in normData" :key="index" class="index">{{item.item_name}}({{item.min_range}}-{{item.large_range}})</span> 
94
+         <span v-for="(item,index) in normData" :key="index" class="index">
95
+           {{item.item_name}}
96
+           <span v-if="item.range_type == 1">({{item.min_range}}-{{item.large_range}})</span>
97
+           <span v-if="item.range_type == 2">({{item.range_value}})</span>
98
+        </span> 
95
       </div>
99
       </div>
96
     </div>
100
     </div>
97
   </div>
101
   </div>
456
       getNormData().then(response=>{
460
       getNormData().then(response=>{
457
          if(response.data.state === 1){
461
          if(response.data.state === 1){
458
            var normdata = response.data.data.normdata
462
            var normdata = response.data.data.normdata
463
+          //  console.log("指标正常范围",normdata)
459
            this.normData = normdata
464
            this.normData = normdata
460
            this.getlist()
465
            this.getlist()
461
          }
466
          }
568
       getFirstQuarter(params).then(response=>{
573
       getFirstQuarter(params).then(response=>{
569
          if(response.data.state === 1){
574
          if(response.data.state === 1){
570
             var count =  response.data.data.count
575
             var count =  response.data.data.count
571
-            console.log("count",count)  
576
+            // console.log("count",count) 
577
+            var countwo = response.data.data.countwo 
578
+            // console.log("countwo",countwo)
579
+            countwo.map(item=>{
580
+              count.push(item)
581
+            })
582
+          //  console.log("count",count)
572
             //获取已经配置的数据 
583
             //获取已经配置的数据 
573
             var arr=[]
584
             var arr=[]
574
             for(let i=0;i<count.length;i++){  
585
             for(let i=0;i<count.length;i++){  
578
                 }
589
                 }
579
               }
590
               }
580
             }
591
             }
581
-           console.log("arr",arr )
592
+          //  console.log("arr",arr )
582
            
593
            
583
             var arrtwo =  this.arrayDate(count,this.normData)
594
             var arrtwo =  this.arrayDate(count,this.normData)
584
             for(let i=0;i<arrtwo.length;i++){
595
             for(let i=0;i<arrtwo.length;i++){
590
             arrtwo.map(item => {
601
             arrtwo.map(item => {
591
               arr.push(item)
602
               arr.push(item)
592
             })
603
             })
593
-            // arr.sort(this.compare('sort'))    
604
+            arr.sort(this.compare('sort'))    
594
             for(const key in this.normData ){
605
             for(const key in this.normData ){
595
                this.modesData.xAxis.push(this.normData[key].item_name);
606
                this.modesData.xAxis.push(this.normData[key].item_name);
596
                 if(key in arr){
607
                 if(key in arr){

+ 2 - 1
src/xt_pages/qcd/patientControlAnalysis.vue Целия файл

78
             <el-table-column fixed prop="name" label="姓名" width="120"></el-table-column>
78
             <el-table-column fixed prop="name" label="姓名" width="120"></el-table-column>
79
             <el-table-column   label="透析号" width="150">
79
             <el-table-column   label="透析号" width="150">
80
               <template slot-scope="scope">
80
               <template slot-scope="scope">
81
-                  {{getDialysisNo(scope.row.name)}}
81
+                  <!-- {{getDialysisNo(scope.row.name)}} -->
82
+                  {{scope.row.dialysis_no}}
82
               </template>
83
               </template>
83
             </el-table-column>
84
             </el-table-column>
84
             <el-table-column
85
             <el-table-column

+ 84 - 20
src/xt_pages/qcd/statisticalConfiguration.vue Целия файл

74
                 </el-option>
74
                 </el-option>
75
             </el-select>
75
             </el-select>
76
           </el-form-item>
76
           </el-form-item>
77
-
78
-          <!-- <el-form-item label="质控范围" :label-width="formLabelWidth" required prop="large_range">
79
-            <el-input style="width:200px" v-model="form.min_range"></el-input>&nbsp;
80
-            -
81
-            <el-input style="width:200px" v-model="form.large_range"></el-input>
82
-          </el-form-item> -->
83
-          <div style="display:flex;">
77
+       
78
+            <el-form-item label="检验类型" :label-width="formLabelWidth" required prop="check_type">
79
+                    <el-radio
80
+                      :disabled = "true"
81
+                      v-model="form.check_type"
82
+                      v-for="item in radioType"
83
+                      :key="item.label"
84
+                      :label="item.value"
85
+                      :value="item.label"
86
+                      >{{ item.label }}</el-radio>
87
+            </el-form-item>  
88
+          <div style="display:flex;" v-show="showOne">
84
             <el-form-item label="质控范围" :label-width="formLabelWidth" required prop="min_range">
89
             <el-form-item label="质控范围" :label-width="formLabelWidth" required prop="min_range">
85
                 <el-input style="width:200px" v-model="form.min_range"></el-input>
90
                 <el-input style="width:200px" v-model="form.min_range"></el-input>
86
             </el-form-item>
91
             </el-form-item>
89
                 <el-input style="width:200px" v-model="form.large_range"></el-input>
94
                 <el-input style="width:200px" v-model="form.large_range"></el-input>
90
             </el-form-item>
95
             </el-form-item>
91
           </div>
96
           </div>
97
+          <div v-show="showTwo">
98
+            <el-form-item label="质控范围" :label-width="formLabelWidth" required prop="range_value">
99
+                <el-input style="width:200px" v-model="form.range_value"></el-input>
100
+            </el-form-item>
101
+          </div>
92
           <el-form-item label="排序" :label-width="formLabelWidth">
102
           <el-form-item label="排序" :label-width="formLabelWidth">
93
             <el-input style="width:200px" v-model="form.sort"></el-input>
103
             <el-input style="width:200px" v-model="form.sort"></el-input>
94
           </el-form-item>
104
           </el-form-item>
125
                 </el-option>
135
                 </el-option>
126
             </el-select>
136
             </el-select>
127
           </el-form-item>
137
           </el-form-item>
128
-          <!-- <el-form-item label="质控范围" :label-width="formLabelWidth" required prop="large_range">
129
-            <el-input style="width:200px" v-model="editform.min_range"></el-input>&nbsp;
130
-            -
131
-            <el-input style="width:200px" v-model="editform.large_range"></el-input>
132
-          </el-form-item> -->
133
-           <div style="display:flex;">
138
+          <el-form-item label="检验类型" :label-width="formLabelWidth" required prop="check_type">
139
+                <el-radio
140
+                  :disabled = "true"
141
+                   v-model="editform.check_type"
142
+                   v-for="item in radioType"
143
+                   :key="item.label"
144
+                   :label="item.value"
145
+                   :value="item.label"
146
+                  >{{ item.label }}
147
+                </el-radio>
148
+            </el-form-item> 
149
+           <div style="display:flex;" v-show="showOne">
134
             <el-form-item label="质控范围" :label-width="formLabelWidth" required prop="min_range">
150
             <el-form-item label="质控范围" :label-width="formLabelWidth" required prop="min_range">
135
                 <el-input style="width:200px" v-model="editform.min_range"></el-input>
151
                 <el-input style="width:200px" v-model="editform.min_range"></el-input>
136
             </el-form-item>
152
             </el-form-item>
138
             <el-form-item class='newFormItem' :label-width="formLabelWidth" required prop="large_range">
154
             <el-form-item class='newFormItem' :label-width="formLabelWidth" required prop="large_range">
139
                 <el-input style="width:200px" v-model="editform.large_range"></el-input>
155
                 <el-input style="width:200px" v-model="editform.large_range"></el-input>
140
             </el-form-item>
156
             </el-form-item>
157
+          </div>
158
+            <div v-show="showTwo">
159
+            <el-form-item label="质控范围" :label-width="formLabelWidth" required prop="range_value">
160
+                <el-input style="width:200px" v-model="editform.range_value"></el-input>
161
+            </el-form-item>
141
           </div>
162
           </div>
142
           <el-form-item label="排序" :label-width="formLabelWidth">
163
           <el-form-item label="排序" :label-width="formLabelWidth">
143
             <el-input style="width:200px" v-model="editform.sort"></el-input>
164
             <el-input style="width:200px" v-model="editform.sort"></el-input>
169
         { path: false, name: "统计配置" },
190
         { path: false, name: "统计配置" },
170
         { path: false, name: "质控达标统计配置" }
191
         { path: false, name: "质控达标统计配置" }
171
       ],
192
       ],
193
+     radioType: [
194
+        { value: 1, label: "数值范围" },
195
+        { value: 2, label: "选项" }
196
+      ],
172
       tabActiveName: "control",
197
       tabActiveName: "control",
173
       InspectionMajor:[],
198
       InspectionMajor:[],
174
       InspectionMinor:[],
199
       InspectionMinor:[],
183
         min_range: "",
208
         min_range: "",
184
         large_range: "",
209
         large_range: "",
185
         sort:"",
210
         sort:"",
211
+        check_type:"",
212
+        range_value:"",
186
       },
213
       },
187
       editform:{
214
       editform:{
188
          id:0,
215
          id:0,
191
          min_range: "",
218
          min_range: "",
192
          large_range: "",
219
          large_range: "",
193
          sort:"",
220
          sort:"",
221
+         check_type:"",
222
+         range_value:"",
194
       },
223
       },
195
       rules: {
224
       rules: {
196
         inspectionMajor: [{ required: true, message: "检查大项不能为空" }],
225
         inspectionMajor: [{ required: true, message: "检查大项不能为空" }],
197
         inspectionMinor: [{ required: true, message: "检查小项不能为空" }],
226
         inspectionMinor: [{ required: true, message: "检查小项不能为空" }],
198
         large_range:[{required:true,message:"质控范围不能为空"}],
227
         large_range:[{required:true,message:"质控范围不能为空"}],
199
-        min_range:[{required:true,message:"质控范围不能为空"}]
228
+        min_range:[{required:true,message:"质控范围不能为空"}],
229
+        check_type:[{required:true,message:"检验类型不能为空"}]
200
       },
230
       },
201
       page:1,
231
       page:1,
202
       limit:10,
232
       limit:10,
203
       total:0,
233
       total:0,
234
+      showOne:true,
235
+      showTwo:false,
204
     };
236
     };
205
   },
237
   },
206
   methods: {
238
   methods: {
216
       getConfigurationDetail(id).then(response=>{
248
       getConfigurationDetail(id).then(response=>{
217
          if(response.data.state == 1){
249
          if(response.data.state == 1){
218
            var configurationdetail = response.data.data.configurationdetail
250
            var configurationdetail = response.data.data.configurationdetail
219
-          console.log("详情",configurationdetail)
251
+           console.log("详情",configurationdetail)
220
            this.editform.id = configurationdetail.id
252
            this.editform.id = configurationdetail.id
221
            this.editform.inspectionMajor = configurationdetail.inspection_major
253
            this.editform.inspectionMajor = configurationdetail.inspection_major
222
            this.editform.inspectionMinor = configurationdetail.inspection_minor
254
            this.editform.inspectionMinor = configurationdetail.inspection_minor
255
+           this.editform.check_type = configurationdetail.range_type
256
+           this.editform.range_value = configurationdetail.range_value
257
+         if(configurationdetail.range_type == 1){
258
+              this.showOne = true
259
+              this.showTwo = false
260
+           }
261
+         if(configurationdetail.range_type == 2){
262
+             this.showOne = false
263
+             this.showTwo = true
264
+           }
265
+         if (configurationdetail.range_value == ""){
266
+             this.editform.range_value = "0"
267
+           }
223
            this.editform.large_range = configurationdetail.large_range
268
            this.editform.large_range = configurationdetail.large_range
224
            this.editform.min_range = configurationdetail.min_range
269
            this.editform.min_range = configurationdetail.min_range
225
-           if(configurationdetail.sort == 0){
270
+           
271
+         if(configurationdetail.sort == 0){
226
             this.editform.sort = ""
272
             this.editform.sort = ""
227
             return
273
             return
228
            }
274
            }
236
       getInspectionMajor().then(response=>{
282
       getInspectionMajor().then(response=>{
237
         if(response.data.state == 1){
283
         if(response.data.state == 1){
238
           var inspection =  response.data.data.inspection
284
           var inspection =  response.data.data.inspection
239
-          console.log("大项",inspection)
285
+          console.log("大项是什么",inspection)
240
           this.InspectionMajor = inspection
286
           this.InspectionMajor = inspection
241
          
287
          
242
         }
288
         }
268
        getInspectionRange(id).then(response=>{
314
        getInspectionRange(id).then(response=>{
269
          if(response.data.state == 1){
315
          if(response.data.state == 1){
270
            var inspectionRange =  response.data.data.inspectionRange
316
            var inspectionRange =  response.data.data.inspectionRange
271
-          console.log("inspectionRange",inspectionRange)
272
-           this.form.min_range = inspectionRange.range_min
273
-           this.form.large_range = inspectionRange.range_max
317
+           console.log("inspectionRange",inspectionRange)
318
+           if(inspectionRange.range_type == 1){
319
+             this.showOne = true
320
+             this.showTwo = false
321
+             this.form.check_type =  1
322
+             this.editform.check_type = 1
323
+             this.form.min_range = inspectionRange.range_min
324
+             this.form.large_range = inspectionRange.range_max
325
+             this.form.range_value  = "0"
326
+           }
327
+           if(inspectionRange.range_type == 2){
328
+             this.showOne = false
329
+             this.showTwo = true
330
+             this.form.check_type = 2
331
+             this.editform.check_type = 2
332
+             this.form.min_range = inspectionRange.range_min
333
+             this.form.large_range = inspectionRange.range_max
334
+             this.form.range_value = inspectionRange.range_value
335
+             this.editform.range_value = inspectionRange.range_value
336
+           }
337
+          
274
          }
338
          }
275
       })
339
       })
276
     },
340
     },

+ 10 - 8
src/xt_pages/qcd/treatmentControlAnalysis/components/CheckAll.vue Целия файл

72
             <template slot-scope="scope">{{ scope.row.name}}</template>
72
             <template slot-scope="scope">{{ scope.row.name}}</template>
73
          </el-table-column>
73
          </el-table-column>
74
          <el-table-column
74
          <el-table-column
75
-          :label="modeItem.project_name"
75
+          :label="modeItem.project_name+'('+modeItem.inspection_frequency+'天)'"
76
           property="number"
76
           property="number"
77
           align="center"
77
           align="center"
78
           min-width="100"
78
           min-width="100"
80
           :key="index"
80
           :key="index"
81
         >
81
         >
82
           <template slot-scope="scope">
82
           <template slot-scope="scope">
83
-              {{ scope.row.data[index].Count}}
83
+             <span v-if="Math.floor(90/modeItem.inspection_frequency) <= scope.row.data[index].Count" style="color:black">{{ scope.row.data[index].Count}}</span>
84
+              <span v-if="Math.floor(90/modeItem.inspection_frequency) > scope.row.data[index].Count" style="color:red">{{ scope.row.data[index].Count}}</span>
84
           </template>
85
           </template>
85
         </el-table-column>
86
         </el-table-column>
86
         </el-table>
87
         </el-table>
90
           @size-change="handleSizeChange"
91
           @size-change="handleSizeChange"
91
           @current-change="handleCurrentChange"
92
           @current-change="handleCurrentChange"
92
           :current-page="listQuery.page"
93
           :current-page="listQuery.page"
93
-          :page-sizes="[20, 40, 60, 80,100]"
94
+          :page-sizes="[10, 20, 30, 40,50]"
94
           :page-size="10"
95
           :page-size="10"
95
           background
96
           background
96
           style="margin-top:20px;"
97
           style="margin-top:20px;"
113
         start_time: "",
114
         start_time: "",
114
         end_time: "",
115
         end_time: "",
115
         page: 1,
116
         page: 1,
116
-        limit: 20
117
+        limit: 10
117
       },
118
       },
118
       value: "请选项",
119
       value: "请选项",
119
       tableData: [],
120
       tableData: [],
203
       getAllMajorInspection().then(response=>{
204
       getAllMajorInspection().then(response=>{
204
         if(response.data.state === 1){
205
         if(response.data.state === 1){
205
            var inspection = response.data.data.inspection
206
            var inspection = response.data.data.inspection
206
-        
207
+           console.log("inspection",inspection)
207
            var a=[];
208
            var a=[];
208
            for(let i=0;i<inspection.length;i++){
209
            for(let i=0;i<inspection.length;i++){
209
              a.push(inspection[i])
210
              a.push(inspection[i])
219
       })
220
       })
220
     },
221
     },
221
     getPatientList(){
222
     getPatientList(){
223
+        this.tableData = []
222
       getPatientList(this.listQuery.start_time,this.listQuery.end_time,this.listQuery.limit,this.listQuery.page).then(response=>{
224
       getPatientList(this.listQuery.start_time,this.listQuery.end_time,this.listQuery.limit,this.listQuery.page).then(response=>{
223
          if(response.data.state === 1){
225
          if(response.data.state === 1){
224
            var patientInfo = response.data.data.patientInfo
226
            var patientInfo = response.data.data.patientInfo
225
-          
227
+           console.log("patientInfo",patientInfo)
226
 
228
 
227
            var total = response.data.data.total
229
            var total = response.data.data.total
228
         
230
         
229
            this.total = total
231
            this.total = total
230
           var list = response.data.data.list
232
           var list = response.data.data.list
231
-       
233
+          console.log("counts",list)
232
           var dtd = []
234
           var dtd = []
233
           for(let i=0;i<list.length;i++){
235
           for(let i=0;i<list.length;i++){
234
               for(let j=0;j<this.tableName.length;j++){
236
               for(let j=0;j<this.tableName.length;j++){
261
               }
263
               }
262
               this.tableData.push({ name: key, data: dd[key]});
264
               this.tableData.push({ name: key, data: dd[key]});
263
             }
265
             }
264
-       
266
+            console.log("表哥",this.tableData)
265
             let projectArr = []
267
             let projectArr = []
266
           
268
           
267
             this.newArr.map(item => {
269
             this.newArr.map(item => {

+ 18 - 14
src/xt_pages/qcd/treatmentControlAnalysis/components/CheckPersonal.vue Целия файл

60
           :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}"
60
           :header-cell-style="{backgroundColor: 'rgb(245, 247, 250)',color: '#606266'}"
61
           highlight-current-row
61
           highlight-current-row
62
           @current-change="handleChange"
62
           @current-change="handleChange"
63
+          ref="tableinfo"
63
           >
64
           >
64
            <el-table-column prop="dialysis_no" label="透析号" width="80">
65
            <el-table-column prop="dialysis_no" label="透析号" width="80">
65
             <template slot-scope="scope">{{scope.row.dialysis_no}}</template>
66
             <template slot-scope="scope">{{scope.row.dialysis_no}}</template>
195
       },
196
       },
196
       obj:[],
197
       obj:[],
197
       patient_id:0,
198
       patient_id:0,
199
+      patientid:0,
198
     };
200
     };
199
   },
201
   },
200
   methods: {
202
   methods: {
222
     },
224
     },
223
     getCurrentOrgPatients(){
225
     getCurrentOrgPatients(){
224
       getCurrentOrgPatients().then(response=>{
226
       getCurrentOrgPatients().then(response=>{
225
-         var patients = response.data.data.patients
226
-         this.patientsData = patients
227
+        var patients = response.data.data.patients
228
+        this.patientsData = patients
229
+        this.$refs.tableinfo.setCurrentRow(this.patientsData[0])
230
+        this.getInspectionTotalCount(this.patientsData[0].id)
227
       })
231
       })
228
     },
232
     },
229
-    getInspectionTotalCount(){
233
+    getInspectionTotalCount(id){
230
           this.modesData.series = []
234
           this.modesData.series = []
231
           this.modesData.xAxis = []
235
           this.modesData.xAxis = []
232
-      getInspectionTotalCount(this.listQuery.start_time,this.listQuery.end_time).then(response=>{
236
+      getInspectionTotalCount(this.listQuery.start_time,this.listQuery.end_time,id).then(response=>{
233
           if(response.data.state === 1){
237
           if(response.data.state === 1){
234
             var Inspection = response.data.data.Inspection
238
             var Inspection = response.data.data.Inspection
235
      
239
      
236
             this.tableData = Inspection
240
             this.tableData = Inspection
237
           
241
           
238
             var counts = response.data.data.counts
242
             var counts = response.data.data.counts
239
-         
243
+           
240
             var arr = []
244
             var arr = []
241
             for(let i=0;i<Inspection.length;i++){
245
             for(let i=0;i<Inspection.length;i++){
242
                for(let j=0;j<counts.length;j++){
246
                for(let j=0;j<counts.length;j++){
278
             res.map(item => {
282
             res.map(item => {
279
               this.modesData.series.push(parseInt(item.Count));
283
               this.modesData.series.push(parseInt(item.Count));
280
             })
284
             })
281
-             console.log("this=====",this.tableData)
282
             for (const key in this.tableData) {
285
             for (const key in this.tableData) {
283
               this.modesData.xAxis.push(this.tableData[key].project_name);
286
               this.modesData.xAxis.push(this.tableData[key].project_name);
284
                let time = new Date(this.listQuery.end_time) - new Date(this.listQuery.start_time)
287
                let time = new Date(this.listQuery.end_time) - new Date(this.listQuery.start_time)
294
 
297
 
295
     //获取单个病人数据
298
     //获取单个病人数据
296
     handleChange(val){
299
     handleChange(val){
300
+      this.patientid = val.id
297
       this.modesData.series = []
301
       this.modesData.series = []
298
       this.modesData.xAxis = []
302
       this.modesData.xAxis = []
299
-       getInspectionDetailById(val.id,this.listQuery.start_time,this.listQuery.end_time).then(response=>{
303
+     getInspectionDetailById(val.id,this.listQuery.start_time,this.listQuery.end_time).then(response=>{
300
           if(response.data.state === 1){
304
           if(response.data.state === 1){
301
             var patientdetail = response.data.data.patientdetail
305
             var patientdetail = response.data.data.patientdetail
302
-            console.log("patientdetail",patientdetail)
306
+            // console.log("patientdetail",patientdetail)
303
             var arr=[]
307
             var arr=[]
304
             for(let i=0;i<this.tableData.length;i++){
308
             for(let i=0;i<this.tableData.length;i++){
305
               for(let j=0;j<patientdetail.length;j++){
309
               for(let j=0;j<patientdetail.length;j++){
311
             
315
             
312
            let time = new Date(this.listQuery.end_time) - new Date(this.listQuery.start_time)
316
            let time = new Date(this.listQuery.end_time) - new Date(this.listQuery.start_time)
313
            let day = parseInt(time / (1000 * 60 * 60 * 24))
317
            let day = parseInt(time / (1000 * 60 * 60 * 24))
314
-           console.log("arr",arr)
315
-           console.log("tabledata",this.tableData)
318
+          //  console.log("arr",arr)
319
+          //  console.log("tabledata",this.tableData)
316
             for (const key in this.tableData) {
320
             for (const key in this.tableData) {
317
               this.modesData.xAxis.push(this.tableData[key].project_name);
321
               this.modesData.xAxis.push(this.tableData[key].project_name);
318
               if (key in arr) {
322
               if (key in arr) {
337
       getSearchPatientInfo(this.patient_id,this.listQuery.start_time,this.listQuery.end_time).then(response=>{
341
       getSearchPatientInfo(this.patient_id,this.listQuery.start_time,this.listQuery.end_time).then(response=>{
338
          if(response.data.state  === 1){
342
          if(response.data.state  === 1){
339
            var PatientsInfo = response.data.data.PatientsInfo
343
            var PatientsInfo = response.data.data.PatientsInfo
340
-           console.log("patientsInfo",PatientsInfo)
344
+          //  console.log("patientsInfo",PatientsInfo)
341
            var arr = []
345
            var arr = []
342
            for(let i=0;i<this.tableData.length;i++){
346
            for(let i=0;i<this.tableData.length;i++){
343
              for(let j=0;j<PatientsInfo.length;j++){
347
              for(let j=0;j<PatientsInfo.length;j++){
396
         PostSearch(key).then(response => {
400
         PostSearch(key).then(response => {
397
           if (response.data.state == 1) {
401
           if (response.data.state == 1) {
398
              searchArray = response.data.data.patient
402
              searchArray = response.data.data.patient
399
-             console.log("searchArray",searchArray)
403
+            //  console.log("searchArray",searchArray)
400
             cb(searchArray)
404
             cb(searchArray)
401
           } else {
405
           } else {
402
             cb([])
406
             cb([])
434
 
438
 
435
    //获取该机构下的所有患者
439
    //获取该机构下的所有患者
436
      this.getCurrentOrgPatients()
440
      this.getCurrentOrgPatients()
437
-   //获取检验检查项目
438
-    this.getInspectionTotalCount()
441
+  //  //获取检验检查项目
442
+  //   this.getInspectionTotalCount()
439
   }
443
   }
440
 };
444
 };
441
 </script>
445
 </script>

+ 24 - 3
src/xt_pages/qcd/treatmentControlAnalysis/components/TimePersonal.vue Целия файл

88
            </el-table-column>
88
            </el-table-column>
89
           <el-table-column prop="address" label="透析总次数" width="140">
89
           <el-table-column prop="address" label="透析总次数" width="140">
90
             <template slot-scope="scope">
90
             <template slot-scope="scope">
91
-                <span>{{ scope.row.total_dialysis + scope.row.user_sys_before_count }}</span>
91
+                <span>{{ getDialysisCount(scope.row.patient_id)}}</span>
92
               </template>
92
               </template>
93
           </el-table-column>
93
           </el-table-column>
94
         </el-table>
94
         </el-table>
124
         page: 1,
124
         page: 1,
125
         limit: 20
125
         limit: 20
126
       },
126
       },
127
+      DialysisCount:[],
127
       total:0,
128
       total:0,
128
       options: [],
129
       options: [],
129
       value: "请选项",
130
       value: "请选项",
195
            console.log("totallist",totallist)
196
            console.log("totallist",totallist)
196
           this.total = totallist  
197
           this.total = totallist  
197
           var prescriptionList = response.data.data.prescriptionList
198
           var prescriptionList = response.data.data.prescriptionList
199
+          console.log("prescriptionList",prescriptionList)
198
           this.getModeId(prescriptionList)
200
           this.getModeId(prescriptionList)
199
-          
201
+          var count = response.data.data.count
202
+          console.log("count",count)
203
+          this.DialysisCount = count
204
+          // for(let i=0;i<count.length;i++){
205
+          //  for(let j=0;j<prescriptionList.length;j++){
206
+          //    if(count[i].patient_id == prescriptionList[j].patient_id){
207
+          //         prescriptionList[j].count = count[i].Count
208
+          //    }
209
+          //  }
210
+          // }
211
+          // console.log("prescriptionList",prescriptionList)
200
           let dataInfo = {}
212
           let dataInfo = {}
201
           list.forEach((item, index) => {
213
           list.forEach((item, index) => {
202
             let { patient_id } = item
214
             let { patient_id } = item
213
             }
225
             }
214
           })
226
           })
215
           let list = Object.values(dataInfo)
227
           let list = Object.values(dataInfo)
216
-          //console.log("arr",list)    
228
+          console.log("arr",list)    
217
           list.map(item => {
229
           list.map(item => {
218
             for (let i = 0; i < prescriptionList.length; i++) {
230
             for (let i = 0; i < prescriptionList.length; i++) {
219
               if (item.patient_id === prescriptionList[i].patient_id) {
231
               if (item.patient_id === prescriptionList[i].patient_id) {
239
 				return age;
251
 				return age;
240
 			}
252
 			}
241
     },
253
     },
254
+    getDialysisCount(id){
255
+       var count = 0
256
+       for(let i=0;i<this.DialysisCount.length;i++){
257
+           if(id == this.DialysisCount[i].patient_id){
258
+              count = this.DialysisCount[i].Count
259
+           }
260
+       }
261
+       return count
262
+    },
242
     onSearch(){
263
     onSearch(){
243
       if(this.listQuery.search == "" || this.listQuery.search == null){
264
       if(this.listQuery.search == "" || this.listQuery.search == null){
244
          this.getDialysisList()
265
          this.getDialysisList()