5 changed files with 599 additions and 299 deletions
@ -1,296 +1,362 @@ |
|||||
<template> |
<template> |
||||
<div class="app-container"> |
<div> |
||||
<!-- 静脉溶栓 数据对比 --> |
<div class="app-container"> |
||||
<div class="dis" style="width: 100%"> |
<div class="dis" style="width: 100%"> |
||||
<div style="flex: 1"> |
<div style="flex: 1; margin-right: 20px"> |
||||
<el-card shadow="always"> |
<el-card shadow="always"> |
||||
<div class="dis title-box"> |
<div class="dis title-box"> |
||||
<span class="header-title">静脉溶栓率 </span> |
<span class="header-title">病种排名</span> |
||||
</div> |
<div class="dis"></div> |
||||
<!-- 统计图 --> |
</div> |
||||
<div style="height: 300px" v-loading="loading"> |
<div style="height: 300px" v-loading="loading"> |
||||
<div id="JMz" style="width: 100%"></div> |
<div id="diagnose" style="width: 100%"></div> |
||||
</div> |
</div> |
||||
</el-card> |
</el-card> |
||||
</div> |
</div> |
||||
<div style="flex: 1; margin-left: 20px"> |
<div style="flex: 1"> |
||||
<el-card shadow="always"> |
<el-card shadow="always"> |
||||
<div class="dis title-box"> |
<div class="dis title-box"> |
||||
<span class="header-title">数据对比</span> |
<span class="header-title">体系分布</span> |
||||
<div class="dis"> |
<div class="dis"> |
||||
<div class="dian-box dis"> |
</div> |
||||
<span class="dian" style="background: #00d1a1"></span> |
</div> |
||||
静脉溶栓人数 |
<div style="height: 300px" v-loading="loading"> |
||||
</div> |
<div id="system" style="width: 100%"></div> |
||||
<div class="dian-box dis"> |
</div> |
||||
<span class="dian" style="background: #4f8bff"></span> |
</el-card> |
||||
急救特征人数 |
</div> |
||||
</div> |
</div> |
||||
</div> |
</div> |
||||
</div> |
<div class="app-container"> |
||||
<!-- 统计图 --> |
<div class="dis" style="width: 100%"> |
||||
<div style="height: 300px" v-loading="loading"> |
<div style="flex: 1; margin-right: 20px"> |
||||
<div id="JMy" style="width: 100%"></div> |
<el-card shadow="always"> |
||||
</div> |
<div class="dis title-box"> |
||||
</el-card> |
<span class="header-title">体质分布</span> |
||||
</div> |
<div class="dis"></div> |
||||
</div> |
</div> |
||||
<!-- DNT分布 sICH发生率 --> |
<div style="height: 300px" v-loading="loading"> |
||||
<div class="dis" style="width: 100%"> |
<div id="physique" style="width: 100%"></div> |
||||
<div style="flex: 1"> |
</div> |
||||
<el-card shadow="always"> |
</el-card> |
||||
<div class="dis title-box"> |
</div> |
||||
<span class="header-title">DNT分布 </span> |
<div style="flex: 1"> |
||||
<div class="dis"> |
<el-card shadow="always"> |
||||
<div class="dian-box dis"> |
<div class="dis title-box"> |
||||
<span class="dian" style="background: #ffcd6c"></span> ≤45 min |
<span class="header-title">体态评估(TAPS)</span> |
||||
</div> |
<div class="dis"> |
||||
<div class="dian-box dis"> |
</div> |
||||
<span class="dian" style="background: #f97186"></span> ≤60 min |
</div> |
||||
</div> |
<div style="height: 300px" v-loading="loading"> |
||||
<div class="dian-box dis"> |
<div id="posture" style="width: 100%"></div> |
||||
<span class="dian" style="background: #4f8bff"></span> >60 min |
</div> |
||||
</div> |
</el-card> |
||||
</div> |
</div> |
||||
</div> |
</div> |
||||
<!-- 统计图 --> |
</div> |
||||
<div style="height: 300px" v-loading="loading"> |
<div class="app-container"> |
||||
<div id="DNT" style="width: 100%"></div> |
<div class="dis" style="width: 100%"> |
||||
</div> |
<div style="flex: 1; margin-right: 20px"> |
||||
</el-card> |
<el-card shadow="always"> |
||||
</div> |
<div class="dis title-box"> |
||||
<div style="flex: 1; margin-left: 20px"> |
<span class="header-title">失眠评估(PHQ-9)</span> |
||||
<el-card shadow="always"> |
<div class="dis"></div> |
||||
<div class="dis title-box"> |
</div> |
||||
<span class="header-title">sICH发生率</span> |
<div style="height: 300px" v-loading="loading"> |
||||
</div> |
<div id="agrypnia" style="width: 100%"></div> |
||||
<!-- 统计图 --> |
</div> |
||||
<div style="height: 300px" v-loading="loading"> |
</el-card> |
||||
<div id="sICH" style="width: 100%"></div> |
</div> |
||||
</div> |
<div style="flex: 1"> |
||||
</el-card> |
<el-card shadow="always"> |
||||
</div> |
<div class="dis title-box"> |
||||
</div> |
<span class="header-title">焦虑(HAMD-24)</span> |
||||
</div> |
<div class="dis"> |
||||
|
</div> |
||||
|
</div> |
||||
|
<div style="height: 300px" v-loading="loading"> |
||||
|
<div id="anxiety" style="width: 100%"></div> |
||||
|
</div> |
||||
|
</el-card> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
|
</div> |
||||
</template> |
</template> |
||||
|
|
||||
<script> |
<script> |
||||
import * as echarts from "echarts"; |
import * as echarts from "echarts"; |
||||
require("echarts/theme/macarons"); // echarts theme |
require("echarts/theme/macarons"); // echarts theme |
||||
import resize from "@/views/dashboard/mixins/resize"; |
import resize from "@/views/dashboard/mixins/resize"; |
||||
import { queryDntResult, querySichResult, queryJmrs } from "@/api/indexCom.js"; |
import { |
||||
import { JMRSL, JMSJDB, DNT, SICH } from "./index"; |
zlInfo |
||||
export default { |
} from "@/api/indexCom.js"; |
||||
name: "Post", |
import { |
||||
props: ["title"], |
diagnoseEcharts, |
||||
mixins: [resize], |
systemEcharts, |
||||
data() { |
physiqueEcharts, |
||||
return { |
postureEcharts |
||||
loading: false, |
} from "./index"; |
||||
JMRSLvalue: null, |
export default { |
||||
DNTvalue: null, |
name: "Post", |
||||
SICHvalue: null, |
props: ["title"], |
||||
// 查询参数 |
mixins: [resize], |
||||
queryParams: { |
data() { |
||||
param: { |
return { |
||||
timeType: 4, |
queryParams: { |
||||
startTime: "", |
param: { |
||||
endTime: "", |
startTime: "", |
||||
}, |
endTime: "", |
||||
}, |
}, |
||||
}; |
}, |
||||
}, |
loading: false, |
||||
created() { |
diagnoseValue: null, // 病种 |
||||
// this.getData(); |
systemValue: null, // 体系 |
||||
}, |
physiqueValue: null, // 体质 |
||||
methods: { |
postureValue:null, // 体态 |
||||
statistics(_data, _type) { |
|
||||
this.initial(_data, _type); // 处理数据 |
|
||||
this.loading = true; |
|
||||
this.getData(); // 获取数据 |
|
||||
}, |
|
||||
// 查询 |
|
||||
async getData() { |
|
||||
try { |
|
||||
//RSL 静脉溶栓率 |
|
||||
await queryJmrs(this.queryParams).then((res) => { |
|
||||
this.JMRSLvalue = res.data; |
|
||||
console.log("this.JMRSLvalue: ", this.JMRSLvalue); |
|
||||
this.columnar(); |
|
||||
}); |
|
||||
//DNT |
|
||||
await queryDntResult(this.queryParams).then((res) => { |
|
||||
this.DNTvalue = res.data; |
|
||||
console.log("this.DNTvalue: ", this.DNTvalue); |
|
||||
this.lineDNT(); |
|
||||
}); |
|
||||
// //数据对比 |
|
||||
await querySichResult(this.queryParams).then((res) => { |
|
||||
this.SICHvalue = res.data; |
|
||||
this.LineSICH(); |
|
||||
}); |
|
||||
|
|
||||
this.LineJM(); |
// 体系中文 |
||||
this.columnar(); |
systemObj: { |
||||
this.lineDNT(); |
"yxfpz": "隐形肥胖型", //隐形肥胖型 |
||||
this.LineSICH(); |
"zfgdx": "脂肪过多型", //脂肪过多型 |
||||
this.loading = false; |
"fpx": "肥胖型", //肥胖型 |
||||
} catch (e) {} |
"jrbzx": "肌肉不足型", //肌肉不足型 |
||||
}, |
"jkjcx": "健康匀称型", //健康匀称型 |
||||
// 静脉溶栓率` 数据对比 |
"czjrx": "超重肌肉型", //超重肌肉型 |
||||
LineJM() { |
"xsx": "消瘦型", //消瘦型 |
||||
JMSJDB.series[0].data = this.JMRSLvalue?.map((item) => { |
"dzfx": "低脂肪型", //低脂肪型 |
||||
return item.gailv; |
"ydyx": "运动员型", //运动员型 |
||||
}); |
}, |
||||
JMSJDB.series[1].data = this.JMRSLvalue?.map((item) => { |
// 体质 |
||||
return item.total; |
physiqueObj: { |
||||
}); |
"phz": "平和质", //平和质 |
||||
JMSJDB.xAxis[0].data = this.JMRSLvalue?.map((item) => { |
"qxz": "气虚质", //气虚质 |
||||
return item.date; //X轴 |
"yangxz": "阳虚质", //阳虚质 |
||||
}); |
"yinxz": "阴虚质", //阴虚质 |
||||
this.$nextTick(() => { |
"tsz": "痰湿质", //痰湿质 |
||||
// 基于准备好的dom,初始化echarts实例 |
"srz": "湿热质", //湿热质 |
||||
var myChart = echarts.init(document.getElementById("JMy"), null, { |
"xyz": "血瘀质", //血瘀质 |
||||
height: 300, |
"qyz": "气郁质", //气郁质 |
||||
}); |
"tlz": "特禀质", //特禀质 |
||||
myChart.setOption(JMSJDB, true); |
}, |
||||
myChart.resize(); |
}; |
||||
window.onresize = myChart.resize; |
}, |
||||
}); |
created() { |
||||
}, |
// this.Linepatient(); |
||||
// 静脉溶栓率 |
this.getData(); |
||||
columnar() { |
}, |
||||
JMRSL.series[0].data = this.JMRSLvalue?.map((item) => { |
methods: { |
||||
return item.decimal; |
statistics(_data, _type) { |
||||
}); |
this.initial(_data, _type); // 处理数据 |
||||
JMRSL.xAxis.data = this.JMRSLvalue?.map((item) => { |
this.loading = true; |
||||
return item.date; |
this.getData(); // 获取数据 |
||||
}); |
}, |
||||
JMRSL.series[0].data = this.JMRSLvalue?.map((item) => { |
//患者信息 |
||||
return item.decimal; |
async getData() { |
||||
}); |
try { |
||||
this.$nextTick(() => { |
await zlInfo(this.queryParams).then((res) => { |
||||
// 基于准备好的dom,初始化echarts实例 |
const { |
||||
var myChart = echarts.init(document.getElementById("JMz"), null, { |
jlfb, |
||||
height: 300, |
smfb, |
||||
}); |
sort, |
||||
myChart.setOption(JMRSL, true); |
ttfb, |
||||
myChart.resize(); |
txfb, |
||||
window.onresize = myChart.resize; |
zytz |
||||
}); |
} = res.data |
||||
}, |
// 病种(主要诊断) |
||||
lineDNT() { |
this.diagnoseValue = sort.sort((a, b) => a.total - b.total) |
||||
DNT.series[0].data = this.DNTvalue?.map((item) => { |
this.handleDiagnose() |
||||
return item.dy45; //≤45 |
// 体系 |
||||
}); |
this.systemValue = [] |
||||
DNT.series[1].data = this.DNTvalue?.map((item) => { |
delete txfb.total |
||||
return item.dy60; //≤60 |
for (let key in txfb) { |
||||
}); |
let data = { |
||||
DNT.series[2].data = this.DNTvalue?.map((item) => { |
name: this.systemObj[key], |
||||
return item.other; //>60 |
value: txfb[key] |
||||
}); |
} |
||||
DNT.xAxis.data = this.DNTvalue?.map((item) => { |
this.systemValue.push(data) |
||||
return item.date; //X轴 |
} |
||||
}); |
this.handleSystem() |
||||
this.$nextTick(() => { |
// 体质 |
||||
// 基于准备好的dom,初始化echarts实例 |
this.physiqueValue = [] |
||||
var myChart = echarts.init(document.getElementById("DNT"), null, { |
delete zytz.total |
||||
height: 300, |
for (let key in zytz) { |
||||
}); |
let data = { |
||||
myChart.setOption(DNT, true); |
name: this.physiqueObj[key], |
||||
myChart.resize(); |
value: zytz[key], |
||||
window.onresize = myChart.resize; |
} |
||||
}); |
this.physiqueValue.push(data) |
||||
}, |
} |
||||
LineSICH() { |
this.handlePhysique() |
||||
SICH.series[0].data = this.SICHvalue?.map((item) => { |
// 体态 |
||||
return item.decimal; //≤45 |
this.postureValue = [{ |
||||
}); |
value: ttfb.score1, |
||||
SICH.xAxis[0].data = this.SICHvalue?.map((item) => { |
name: "1分" |
||||
return item.time; //X轴 |
},{ |
||||
}); |
value: ttfb.score2, |
||||
this.$nextTick(() => { |
name: "2分" |
||||
// 基于准备好的dom,初始化echarts实例 |
},{ |
||||
var myChart = echarts.init(document.getElementById("sICH"), null, { |
value: ttfb.score3, |
||||
height: 300, |
name: "3分" |
||||
}); |
},{ |
||||
myChart.setOption(SICH, true); |
value: ttfb.score4, |
||||
myChart.resize(); |
name: "4分" |
||||
window.onresize = myChart.resize; |
},{ |
||||
}); |
value: ttfb.score5, |
||||
}, |
name: "5分" |
||||
// 数据处理 查询类型判断参数 |
}] |
||||
initial(_data, _type) { |
this.handlePosture() |
||||
_data[0] = this.$moment(_data[0]).format("YYYY-MM-DD"); |
}); |
||||
_data[1] = this.$moment(_data[1]).format("YYYY-MM-DD"); |
this.loading = false; |
||||
this.queryParams.param = { |
} catch (e) {} |
||||
timeType: _type, |
}, |
||||
startTime: _data[0] + " " + "00:00:00", |
// 病种(主要诊断) |
||||
endTime: _data[1] + " " + "23:59:59", |
handleDiagnose() { |
||||
}; |
diagnoseEcharts.series[0].data = this.diagnoseValue?.map((item) => { |
||||
}, |
return item.total; |
||||
// 重新渲染图标 |
}); |
||||
getRenew() { |
diagnoseEcharts.yAxis.data = this.diagnoseValue?.map((item) => { |
||||
this.LineJM(); |
return item.type; |
||||
this.columnar(); |
}); |
||||
this.lineDNT(); |
this.$nextTick(() => { |
||||
this.LineSICH(); |
var myChart = echarts.init(document.getElementById("diagnose"), null, { |
||||
}, |
height: 300, |
||||
}, |
}); |
||||
}; |
myChart.setOption(diagnoseEcharts, true); |
||||
|
myChart.resize(); |
||||
|
window.onresize = myChart.resize; |
||||
|
}); |
||||
|
}, |
||||
|
// 体系 |
||||
|
handleSystem() { |
||||
|
systemEcharts.series[0].data = this.systemValue?.map((item) => { |
||||
|
return item.value; |
||||
|
}); |
||||
|
systemEcharts.xAxis.data = this.systemValue?.map((item) => { |
||||
|
return item.name; |
||||
|
}); |
||||
|
this.$nextTick(() => { |
||||
|
var myChart = echarts.init(document.getElementById("system"), null, { |
||||
|
height: 300, |
||||
|
}); |
||||
|
myChart.setOption(systemEcharts, true); |
||||
|
myChart.resize(); |
||||
|
window.onresize = myChart.resize; |
||||
|
}); |
||||
|
}, |
||||
|
// 体质 |
||||
|
handlePhysique() { |
||||
|
physiqueEcharts.series[0].data = this.physiqueValue?.map((item) => { |
||||
|
return item.value; |
||||
|
}); |
||||
|
physiqueEcharts.xAxis.data = this.physiqueValue?.map((item) => { |
||||
|
return item.name; |
||||
|
}); |
||||
|
this.$nextTick(() => { |
||||
|
var myChart = echarts.init(document.getElementById("physique"), null, { |
||||
|
height: 300, |
||||
|
}); |
||||
|
myChart.setOption(physiqueEcharts, true); |
||||
|
myChart.resize(); |
||||
|
window.onresize = myChart.resize; |
||||
|
}); |
||||
|
}, |
||||
|
// 体态评估 |
||||
|
handlePosture() { |
||||
|
postureEcharts.series[0].data = this.postureValue |
||||
|
this.$nextTick(() => { |
||||
|
var myChart = echarts.init(document.getElementById("posture"), null, { |
||||
|
height: 300, |
||||
|
}); |
||||
|
myChart.setOption(postureEcharts, true); |
||||
|
myChart.resize(); |
||||
|
window.onresize = myChart.resize; |
||||
|
}); |
||||
|
}, |
||||
|
// 数据处理 查询类型判断参数 |
||||
|
initial(_data, _type) { |
||||
|
_data[0] = this.$moment(_data[0]).format("YYYY-MM-DD"); |
||||
|
_data[1] = this.$moment(_data[1]).format("YYYY-MM-DD"); |
||||
|
this.queryParams.param = { |
||||
|
startTime: _data[0] + " " + "00:00:00", |
||||
|
endTime: _data[1] + " " + "23:59:59", |
||||
|
}; |
||||
|
}, |
||||
|
// 重新渲染图标 |
||||
|
getRenew() { |
||||
|
this.Linepatient(); |
||||
|
this.columnar(); |
||||
|
}, |
||||
|
}, |
||||
|
}; |
||||
</script> |
</script> |
||||
<style scoped src="@/assets/styles/common.css"></style> |
<style scoped src="@/assets/styles/common.css"></style> |
||||
<style scoped> |
<style scoped> |
||||
>>> .el-card__body { |
>>>.el-card__body { |
||||
padding: 10px 0 !important; |
padding: 10px 0 !important; |
||||
} |
} |
||||
.dis { |
|
||||
display: flex; |
.dis { |
||||
} |
display: flex; |
||||
.header-title { |
} |
||||
font-size: 18px; |
|
||||
} |
.header-title { |
||||
.title-box { |
font-size: 18px; |
||||
padding: 10px 20px; |
} |
||||
border-bottom: 1px solid #dfe6ec; |
|
||||
} |
.title-box { |
||||
.dian-box { |
padding: 10px 20px; |
||||
align-items: center; |
border-bottom: 1px solid #dfe6ec; |
||||
} |
} |
||||
.dian { |
|
||||
display: inline-block; |
.dian-box { |
||||
width: 16px; |
align-items: center; |
||||
height: 16px; |
} |
||||
border-radius: 50%; |
|
||||
margin: 0 10px; |
.dian { |
||||
} |
display: inline-block; |
||||
.title-box { |
width: 16px; |
||||
justify-content: space-between; |
height: 16px; |
||||
} |
border-radius: 50%; |
||||
. >>> .el-radio--small.is-bordered { |
margin: 0 10px; |
||||
margin-right: 20px !important; |
} |
||||
margin-left: 0 !important; |
|
||||
} |
.title-box { |
||||
>>> .el-radio__input { |
justify-content: space-between; |
||||
display: none; |
} |
||||
} |
|
||||
>>> .el-radio__label { |
.>>>.el-radio--small.is-bordered { |
||||
padding-left: 5px; |
margin-right: 20px !important; |
||||
} |
margin-left: 0 !important; |
||||
.app-container { |
} |
||||
padding: 0; |
|
||||
} |
>>>.el-radio__input { |
||||
.title1 { |
display: none; |
||||
display: flex; |
} |
||||
align-items: center; |
|
||||
font-size: 20px; |
>>>.el-radio__label { |
||||
font-weight: 600; |
padding-left: 5px; |
||||
} |
} |
||||
.title-bor { |
|
||||
display: inline-block; |
.app-container { |
||||
height: 20px; |
padding: 0; |
||||
width: 6px; |
display: flex; |
||||
background: #4f8bff; |
justify-content: space-between; |
||||
margin-right: 10px; |
} |
||||
border-radius: 8px; |
|
||||
} |
.title { |
||||
|
display: flex; |
||||
|
align-items: center; |
||||
|
font-size: 20px; |
||||
|
font-weight: 600; |
||||
|
} |
||||
|
|
||||
|
.title-bor { |
||||
|
display: inline-block; |
||||
|
height: 20px; |
||||
|
width: 6px; |
||||
|
background: #4f8bff; |
||||
|
margin-right: 10px; |
||||
|
border-radius: 8px; |
||||
|
} |
||||
</style> |
</style> |
Loading…
Reference in new issue