|
@@ -164,8 +164,8 @@
|
164
|
164
|
<el-progress :percentage="(item.count/InfectiousTotal*100).toFixed(1)"></el-progress>
|
165
|
165
|
</span>
|
166
|
166
|
<span v-if="item.disease_id == 1">
|
167
|
|
- <p>其他:{{item.count + otherTotal}}人({{((item.count+otherTotal)/InfectiousTotal*100).toFixed(1)}}%)</p>
|
168
|
|
- <el-progress :percentage="((item.count+otherTotal)/InfectiousTotal*100).toFixed(1)"></el-progress>
|
|
167
|
+ <p>其他:{{item.count}}人({{((item.count)/InfectiousTotal*100).toFixed(1)}}%)</p>
|
|
168
|
+ <el-progress :percentage="((item.count)/InfectiousTotal*100).toFixed(1)"></el-progress>
|
169
|
169
|
</span>
|
170
|
170
|
</div>
|
171
|
171
|
</div>
|
|
@@ -477,7 +477,6 @@ export default {
|
477
|
477
|
getDialysisModeType(startDate,endDate).then(response=>{
|
478
|
478
|
if(response.data.state == 1){
|
479
|
479
|
var modetype = response.data.data.modetype
|
480
|
|
- console.log("mode---",modetype)
|
481
|
480
|
var total = response.data.data.total
|
482
|
481
|
console.log("total",total)
|
483
|
482
|
this.total = total
|
|
@@ -522,32 +521,26 @@ export default {
|
522
|
521
|
getTotalInfectiousCount(timeStar,timeEnd).then(response=>{
|
523
|
522
|
if(response.data.state === 1){
|
524
|
523
|
this.InfectiousTotal = response.data.data.total
|
|
524
|
+ console.log("===",this.InfectiousTotal)
|
525
|
525
|
var infectious = response.data.data.count
|
526
|
|
- this.InfectiousList = infectious
|
527
|
|
- // for(let i=0;i<infectious.length;i++){
|
528
|
|
- // if(infectious[i].disease_id == 1){
|
529
|
|
- // infectious[i].disease_id = "其他"
|
530
|
|
- // }
|
531
|
|
- // if(infectious[i].disease_id == 2){
|
532
|
|
- // infectious[i].disease_id = "乙肝"
|
533
|
|
- // }
|
534
|
|
- // if(infectious[i].disease_id == 3){
|
535
|
|
- // infectious[i].disease_id = "丙肝"
|
536
|
|
- // }
|
537
|
|
- // if(infectious[i].disease_id == 4){
|
538
|
|
- // infectious[i].disease_id = "艾滋病"
|
539
|
|
- // }
|
540
|
|
- // if(infectious[i].disease_id == 5){
|
541
|
|
- // infectious[i].disease_id = "肺结核"
|
542
|
|
- // }
|
543
|
|
- // if(infectious[i].disease_id == 6){
|
544
|
|
- // infectious[i].disease_id = "梅毒"
|
545
|
|
- // }
|
546
|
|
-
|
547
|
|
- // }
|
|
526
|
+ console.log("infectious",infectious)
|
548
|
527
|
var otherTotal = response.data.data.otherTotal
|
|
528
|
+ console.log("otherTotal",otherTotal)
|
549
|
529
|
this.otherTotal = otherTotal
|
550
|
|
- // console.log("infectious-----------",otherTotal)
|
|
530
|
+ var arr = [
|
|
531
|
+ {count:0,disease_id:2},
|
|
532
|
+ {count:0,disease_id:3},
|
|
533
|
+ {count:0,disease_id:4},
|
|
534
|
+ {count:0,disease_id:5},
|
|
535
|
+ {count:0,disease_id:6},
|
|
536
|
+ ]
|
|
537
|
+ if(infectious.length == 0){
|
|
538
|
+ this.InfectiousList = arr
|
|
539
|
+ return false
|
|
540
|
+
|
|
541
|
+ }
|
|
542
|
+ this.InfectiousList = infectious
|
|
543
|
+
|
551
|
544
|
}
|
552
|
545
|
})
|
553
|
546
|
},
|
|
@@ -555,15 +548,22 @@ export default {
|
555
|
548
|
getTotalAgeCount(timeStar,timeEnd).then(response=>{
|
556
|
549
|
if(response.data.state == 1){
|
557
|
550
|
var ageCount = response.data.data.ageCount
|
558
|
|
- this.ageCount = ageCount
|
559
|
|
- // console.log("ageCount",ageCount)
|
|
551
|
+ var arr = []
|
|
552
|
+ arr = ageCount.sort(this.compare('age'))
|
|
553
|
+ this.ageCount = arr
|
560
|
554
|
this.ageTotal = response.data.data.total
|
561
|
|
- // var two = response.data.data.two
|
562
|
|
- // console.log("two",two)
|
563
|
555
|
|
564
|
556
|
}
|
565
|
557
|
})
|
566
|
558
|
},
|
|
559
|
+ compare:function (k) {
|
|
560
|
+ return function (a, b) {
|
|
561
|
+ var M = a[k];
|
|
562
|
+ var N = b[k];
|
|
563
|
+ return M - N; // 从低向高排
|
|
564
|
+ // return N - M; // 从高向低排
|
|
565
|
+ }
|
|
566
|
+ },
|
567
|
567
|
//统计透析年龄
|
568
|
568
|
getTotalDialysisCount(timeStar,timeEnd){
|
569
|
569
|
getTotalDialysisCount(timeStar,timeEnd).then(response=>{
|