|
@ -6,6 +6,7 @@
|
|
|
Vue.component('high-incidence-disease', {
|
|
|
template: '<div style="height: 100%;">\
|
|
|
<h4 class="c-b5e1fc c-f16 c-t-center div-common-title">本月高发疾病排行</h4>\
|
|
|
<img src="../images/icon.png" class="icon-img" @click="detailClick">\
|
|
|
<div v-show="!hasData" class="no-result-panel">\
|
|
|
<div class="no-result-img" style="padding-top:1.09375rem;">\
|
|
|
<img src="../images/noData.png">\
|
|
@ -60,6 +61,18 @@
|
|
|
}
|
|
|
},
|
|
|
methods: {
|
|
|
detailClick:function(){
|
|
|
top.layer.open({
|
|
|
id: 'LAY_layuipro', //设定一个id,防止重复弹出
|
|
|
type: 2,
|
|
|
title: false,
|
|
|
closeBtn: 0,
|
|
|
shade: 0.5,
|
|
|
shadeClose: true,
|
|
|
area: ['7.604rem', '4.1875rem'],
|
|
|
content: '../../../page/bigData/html/alert6.html'
|
|
|
});
|
|
|
},
|
|
|
btnClick1:function(idx){
|
|
|
this.index1 = idx;
|
|
|
this.initData();
|
|
@ -80,18 +93,18 @@
|
|
|
this.hasData = false;
|
|
|
return false;
|
|
|
}
|
|
|
var zhuYuanData = [],zhuYuanTitle = "";
|
|
|
var menZhenData = [],menZhenTitle = "";
|
|
|
var xAxisData = (this.gaoBingFaData.xAxis[0].data).reverse()||[];
|
|
|
var menZhenData = (this.gaoBingFaData.series[0].data).reverse()||[];
|
|
|
var menZhenTitle = this.gaoBingFaData.series[0].name||"";
|
|
|
var zhuYuanData = (this.gaoBingFaData.series[1].data).reverse()||[];
|
|
|
var zhuYuanTitle = this.gaoBingFaData.series[1].name||"";
|
|
|
if(this.index1==0){//全部(显示门诊/住院数据叠加)
|
|
|
zhuYuanData = (this.gaoBingFaData.series[1].data).reverse();
|
|
|
zhuYuanTitle = this.gaoBingFaData.series[1].name;
|
|
|
}else if(this.index1==1){//住院(显示单个柱状图)
|
|
|
menZhenData = (this.gaoBingFaData.series[1].data).reverse();
|
|
|
menZhenTitle = this.gaoBingFaData.series[1].name;
|
|
|
zhuYuanData = [];
|
|
|
zhuYuanTitle = "";
|
|
|
menZhenData = (this.gaoBingFaData.series[0].data).reverse();
|
|
|
menZhenTitle = this.gaoBingFaData.series[0].name;
|
|
|
}else if(this.index1==2){//门诊(显示单个柱状图)
|
|
|
zhuYuanData = (this.gaoBingFaData.series[0].data).reverse();
|
|
|
zhuYuanTitle = this.gaoBingFaData.series[0].name;
|
|
|
menZhenData = [];
|
|
|
menZhenTitle = "";
|
|
|
}
|
|
|
this.geoFaMainFun(xAxisData,menZhenData,zhuYuanData,menZhenTitle,zhuYuanTitle)
|
|
|
},
|
|
@ -156,7 +169,7 @@
|
|
|
}],
|
|
|
"series": [{
|
|
|
"smooth": true,
|
|
|
"name": menZhenTitle,
|
|
|
"name": zhuYuanTitle,
|
|
|
"type": "bar",
|
|
|
stack: '高发疾病',
|
|
|
barWidth: 20,
|
|
@ -174,17 +187,17 @@
|
|
|
barBorderRadius: [0, 8, 8, 0],
|
|
|
}
|
|
|
},
|
|
|
"data": menZhenData
|
|
|
"data": zhuYuanData
|
|
|
},
|
|
|
]
|
|
|
}
|
|
|
if(zhuYuanData.length>0){
|
|
|
if(menZhenData.length>0){
|
|
|
gaofaOption.series[0].label.show = false;
|
|
|
gaofaOption.series[0].itemStyle.normal.color = "#6576e0";
|
|
|
delete gaofaOption.series[0].itemStyle.normal.barBorderRadius;
|
|
|
gaofaOption.series[1] = {
|
|
|
"smooth": true,
|
|
|
"name": zhuYuanTitle,
|
|
|
"name": menZhenTitle,
|
|
|
"type": "bar",
|
|
|
stack: '高发疾病',
|
|
|
"label": {
|
|
@ -192,13 +205,13 @@
|
|
|
position: "right",
|
|
|
color: '#b5e1fc',
|
|
|
formatter:function(param){
|
|
|
var dataIndex = param.dataIndex,menZhenVal;
|
|
|
_.map(menZhenData,function(item,idx){
|
|
|
var dataIndex = param.dataIndex,zhuYuanVal;
|
|
|
_.map(zhuYuanData,function(item,idx){
|
|
|
if(idx==dataIndex){
|
|
|
menZhenVal = item
|
|
|
zhuYuanVal = item
|
|
|
}
|
|
|
})
|
|
|
return menZhenVal+"+"+param.value;
|
|
|
return zhuYuanVal+"+"+param.value;
|
|
|
},
|
|
|
},
|
|
|
"itemStyle": {
|
|
@ -210,7 +223,7 @@
|
|
|
color: '#00e6f3'
|
|
|
},
|
|
|
},
|
|
|
"data": zhuYuanData
|
|
|
"data": menZhenData
|
|
|
}
|
|
|
}else{
|
|
|
gaofaOption.series = gaofaOption.series[0];
|