This commit is contained in:
闫晓茹 2024-08-21 14:41:14 +08:00
parent a68be3e785
commit f87d5ed14e

View File

@ -77,11 +77,14 @@
<div class="appbottom">
<div class="appbottomone">
<div class="word">本月签约患者情况</div>
<div id="main1" style="height: 80%"></div>
<div id="main1" style="height: 80%" v-if="countydata"></div>
<el-empty description="暂无" style="width: 100%" v-else></el-empty>
</div>
<div class="appbottomtwo">
<div class="word">服务方式</div>
<div id="main" style="height: 80%"></div>
<div id="main" style="height: 80%" v-if="arrlist"></div>
<el-empty description="暂无" style="width: 100%" v-else></el-empty>
</div>
</div>
</div>
@ -105,6 +108,8 @@ export default {
list: {},
namelist: [],
taskSituationlist: [],
countydata:[],
arrlist:[],
};
},
mounted() {
@ -140,18 +145,20 @@ export default {
getlist() {
signPatientCount().then((res) => {
console.log(res, "res");
var countydata = [];
// x
// this. countydata = [];
res.data.forEach((e) => {
countydata.push(e.time);
this. countydata.push(e.time);
});
//
var countydatay = [];
res.data.forEach((e) => {
countydatay.push(e.patientCount);
});
//
var proportionlist = [];
res.data.forEach((e) => {
e.proportion = e.proportion*100;
e.proportion = e.proportion * 100;
proportionlist.push(e.proportion);
});
//
@ -189,7 +196,7 @@ export default {
},
},
type: "category",
data: countydata,
data: this.countydata,
axisPointer: {
type: "shadow",
},
@ -217,13 +224,12 @@ export default {
tooltip: {
trigger: "axis",
formatter: (params) => {
// console.log(params,'params')
let text = '';
let text = "";
params.map((item) => {
if(item.seriesName =='当月签约率'){
text += item.seriesName + " : " + item.value + "%"+'<br/>';
}else{
text += item.seriesName + " : " + item.value+'<br/>';
if (item.seriesName == "当月签约率") {
text += item.seriesName + " : " + item.value + "%" + "<br/>";
} else {
text += item.seriesName + " : " + item.value + "<br/>";
}
});
return text;
@ -255,9 +261,9 @@ export default {
},
info() {
serviceModeStatistics().then((res) => {
let arr = [];
this. arrlist = [];
res.data.forEach((element) => {
arr.push({
this.arrlist.push({
value: element.count, //conutvalue
name: element.name, //namename
});
@ -278,7 +284,7 @@ export default {
name: "",
type: "pie",
radius: ["40%", "70%"],
data: arr,
data: this.arrlist,
label: {
show: true,
formatter: "{b}:{c}", // " "
@ -294,7 +300,7 @@ export default {
{
type: "pie",
radius: ["40%", "70%"],
data: arr,
data: this.arrlist,
emphasis: {
itemStyle: {
shadowBlur: 10,