ggfwjsc/src/view/analyze.vue

698 lines
16 KiB
Vue
Raw Normal View History

2024-04-12 09:26:48 +08:00
<template>
<div class="module">
2024-06-14 09:40:18 +08:00
<div class="displayFlex left_bg">
2024-06-14 16:16:41 +08:00
<div class="flex11">
2024-06-14 09:40:18 +08:00
<div class="yd_title left_1">
<div class="animate-border">
<i></i>
<i></i>
2024-04-12 09:26:48 +08:00
</div>
</div>
2024-06-14 10:49:19 +08:00
<div class="hypertension">
<pie3dMt1 :list="data.gxy"></pie3dMt1>
<edxs
:list="data.whistleblower.culeTotal.data"
:month="data.whistleblower.culeTotal.time"
></edxs>
</div>
</div>
<div class="flex1">
<div class="yd_title left_2">
<div class="animate-border">
<i></i>
<i></i>
</div>
</div>
<div class="ViewData">
2024-06-14 11:31:54 +08:00
<div class="ViewDatalist">
2024-06-14 16:16:41 +08:00
<div
class="ViewDataTop"
v-for="(item, index) in data.ViewData"
:key="item.name"
@click="onViewData(item.name, index)"
>
<div
class="ViewDataTopimg"
:class="{ ViewDataBottomimg: item.show }"
>
{{ item.value }}
2024-06-14 11:31:54 +08:00
</div>
2024-06-14 16:16:41 +08:00
<div
class="ViewDataTopimg_1"
:class="{ ViewDataBottomimg_1: item.show }"
></div>
<span> {{ item.name }}</span>
2024-06-14 11:31:54 +08:00
</div>
</div>
2024-06-17 09:58:05 +08:00
<eP2 :list="data.DataViewing" :year="data.leftCenterYear"></eP2>
2024-06-14 10:49:19 +08:00
</div>
2024-04-12 09:26:48 +08:00
</div>
2024-06-14 09:40:18 +08:00
</div>
<div class="displayFlex center_bg">
<div class="flex1">
<div class="yd_title center_0">
<div class="animate-border">
<i></i>
<i></i>
2024-04-12 09:26:48 +08:00
</div>
</div>
2024-06-14 10:46:56 +08:00
<div class="minTopTitle"></div>
<div class="minTopNum">
2024-06-14 10:51:23 +08:00
<div
class="numItem"
2024-06-17 17:04:26 +08:00
v-for="(item, index) in minData.minTop"
2024-06-14 10:51:23 +08:00
:key="index"
>
{{ item }}
</div>
2024-06-14 10:46:56 +08:00
</div>
2024-06-14 16:16:41 +08:00
<div style="overflow: hidden; margin-top: 20px">
2024-06-14 11:33:07 +08:00
<div class="minPie">
2024-06-14 16:16:41 +08:00
<div class="minPieImg" style="letter-spacing: 1px">
集聚类型分布
</div>
2024-06-14 11:33:07 +08:00
<Pie3dMt :list="minData.minPieData1"></Pie3dMt>
</div>
<div class="minPie">
<div class="minPieImg">年龄分布</div>
<Pie3dMt2 :list="minData.minPieData2"></Pie3dMt2>
</div>
</div>
2024-06-14 16:16:41 +08:00
<div style="width: 100%; height: 200px; margin: 20px 0">
2024-06-14 11:33:07 +08:00
<img
src="../assets/images/sjfx/minImg.jpg"
2024-06-14 16:16:41 +08:00
style="width: 100%; height: 100%"
2024-06-14 11:33:07 +08:00
alt=""
2024-06-14 16:16:41 +08:00
/>
2024-06-14 10:54:03 +08:00
</div>
2024-04-12 09:26:48 +08:00
</div>
2024-06-14 09:40:18 +08:00
<div class="flex1">
<div class="yd_title center_1">
<div class="animate-border">
<i></i>
<i></i>
2024-04-12 09:26:48 +08:00
</div>
</div>
2024-06-14 11:31:54 +08:00
<ylXZZC :list1="data.zccs1" :list2="data.zccs2"></ylXZZC>
2024-04-12 09:26:48 +08:00
</div>
</div>
2024-06-14 09:40:18 +08:00
<div class="displayFlex right_bg">
2024-04-12 09:26:48 +08:00
<div class="flex1">
2024-06-14 09:40:18 +08:00
<div class="yd_title right_1">
<div class="animate-border">
<i></i>
<i></i>
</div>
2024-04-12 09:26:48 +08:00
</div>
2024-06-14 11:33:07 +08:00
<right1></right1>
2024-04-12 09:26:48 +08:00
</div>
<div class="flex1">
2024-06-14 09:40:18 +08:00
<div class="yd_title right_2">
<div class="animate-border">
<i></i>
<i></i>
2024-04-12 09:26:48 +08:00
</div>
</div>
2024-06-17 09:58:05 +08:00
<!-- <img src="@/assets/images/sjfx/right3D.png" alt="" class="right3d" /> -->
2024-06-14 11:53:51 +08:00
<right2></right2>
2024-04-12 09:26:48 +08:00
</div>
<div class="flex1">
2024-06-14 09:40:18 +08:00
<div class="yd_title right_3">
<div class="animate-border">
<i></i>
<i></i>
2024-04-12 09:26:48 +08:00
</div>
</div>
2024-06-14 16:16:41 +08:00
<img src="@/assets/images/sjfx/map.png" alt="" class="map" />
2024-04-12 09:26:48 +08:00
</div>
2024-06-14 09:40:18 +08:00
</div>
2024-04-12 09:26:48 +08:00
</div>
</template>
<script setup>
2024-06-17 11:50:40 +08:00
import {
ref,
reactive,
onMounted,
onBeforeMount,
onBeforeUnmount,
computed,
} from "vue";
2024-06-14 10:51:07 +08:00
import right2 from "./echart_analyze/right2.vue";
import right1 from "./echart_analyze/right1.vue";
2024-06-14 09:40:18 +08:00
import http from "@/utils/request.js";
2024-06-14 11:31:54 +08:00
import Pie3dMt from "./echart_analyze/pie3dMt.vue";
2024-06-14 11:35:09 +08:00
import Pie3dMt2 from "./echart_analyze/pie3dMt2.vue";
2024-06-14 10:49:19 +08:00
import pie3dMt1 from "./echart_analyze/pie3dMt1.vue";
import edxs from "./echart_analyze/edXS.vue";
import eP2 from "./echart_analyze/eP2.vue";
2024-06-14 11:31:54 +08:00
import ylXZZC from "./echart_analyze/ylXZZC.vue";
2024-06-14 09:40:18 +08:00
2024-06-14 16:16:41 +08:00
import ViewDataimg from "@/assets/images/sjfx/sjfx.png";
import ViewDataimg1 from "@/assets/images/sjfx/sjfx1.png";
import ViewDataimg2 from "@/assets/images/sjfx/sjfx2.png";
import ViewDataimg3 from "@/assets/images/sjfx/sjfx3.png";
2024-06-14 09:56:52 +08:00
const showR = ref(false); //loading
const data = reactive({
2024-06-14 16:16:41 +08:00
datashow: null,
backgroundImageUrl: ViewDataimg,
backgroundImageUrl1: ViewDataimg1,
2024-06-14 09:56:52 +08:00
leftTop1: [],
2024-06-14 10:49:19 +08:00
gxy: [], //高血压
whistleblower: {
culeTotal: {
data: ["100", "120", "199", "133", "210"],
time: ["61-70", "71-80", "81-90", "91-100", "100以上"],
},
}, //高血压柱状图
2024-06-14 16:16:41 +08:00
ViewData: [
{
name: "医保支出万元以上",
value: "11112",
2024-06-17 09:58:05 +08:00
show: true,
2024-06-14 16:16:41 +08:00
data: ["100", "120", "199", "133", "210"], //医保支出万元以上
},
{
name: "大病住院",
value: "120",
show: false,
2024-06-14 16:57:58 +08:00
data: ["10", "12", "19", "13", "21"], //大病住院
2024-06-14 16:16:41 +08:00
},
{
name: "高血压",
value: "2345",
show: false,
2024-06-14 16:57:58 +08:00
data: ["100", "10", "199", "13", "210"], //高血压
2024-06-14 16:16:41 +08:00
},
{
name: "糖尿病",
value: "1241",
show: false,
2024-06-17 09:58:05 +08:00
data: ["100", "120", "19", "133", "210"], //糖尿病
2024-06-14 16:16:41 +08:00
},
{
name: "高血脂",
value: "1414",
show: false,
2024-06-17 09:58:05 +08:00
data: ["100", "120", "199", "13", "210"], //高血脂
2024-06-14 16:16:41 +08:00
},
{
name: "高血糖",
value: "2355",
show: false,
2024-06-17 09:58:05 +08:00
data: ["100", "120", "199", "133", "10"], //高血糖
2024-06-14 16:16:41 +08:00
},
{
name: "残疾",
value: "455",
show: false,
data: ["100", "120", "199", "133", "210"], //残疾
},
{
name: "低保",
value: "142",
show: false,
data: ["100", "120", "199", "133", "210"], //低保
},
{
name: "特困",
value: "98",
show: false,
data: ["100", "120", "199", "133", "210"], //特困
},
{
name: "其他疾病",
value: "144",
show: false,
data: ["100", "120", "199", "133", "210"], //其他疾病
},
],
2024-06-17 09:58:05 +08:00
DataViewing: [
{
name: "医保支出万元以上",
data: ["100", "120", "199", "133", "210"], //医保支出万元以上
},
], //数据查看
2024-06-14 10:51:23 +08:00
leftCenterYear: ["2019", "2020", "2021", "2022", "2023"], //年份
2024-06-17 09:58:05 +08:00
// leftCenter1: ["100", "120", "199", "133", "210"], //医保支出万元以上
// leftCenter3: ["100", "80", "199", "133", "210"], //大病住院
// leftCenter4: ["100", "120", "199", "133", "210"], //糖尿病
2024-06-14 16:16:41 +08:00
zccs1: ["图书馆", "交通出行", "景区"], //一码通
zccs2: ["100", "130", "220"], //一码通
2024-06-14 10:51:23 +08:00
});
2024-06-14 10:46:56 +08:00
const minData = reactive({
2024-06-14 10:51:23 +08:00
minTop: ["4", "9", "1", "6", "2", "人"],
2024-06-14 10:46:56 +08:00
minPieData1: {
2024-06-14 10:51:23 +08:00
wfgz: "1500",
xstp: "1610",
skym: "1610",
xxdc: "1610",
dzzh: "1610",
zq: "1610",
},
2024-06-14 11:33:07 +08:00
minPieData2: {
wfgz: "1500",
xstp: "1610",
2024-06-14 16:16:41 +08:00
skym: "1610",
2024-06-14 11:33:07 +08:00
},
2024-06-14 09:40:18 +08:00
});
2024-06-14 16:16:41 +08:00
// 数据查看
const onViewData = (value, i) => {
2024-06-17 11:50:40 +08:00
clearInterval(interval); //清除定时器
2024-06-14 16:16:41 +08:00
data.ViewData[i].show = !data.ViewData[i].show;
data.DataViewing = data.ViewData.filter((item) => item.show).map((item) => ({
name: item.name,
data: item.data,
}));
2024-06-17 11:50:40 +08:00
};
const onViewData1 = (i) => {
data.ViewData[i].show = !data.ViewData[i].show;
data.DataViewing = data.ViewData.filter((item) => item.show).map((item) => ({
name: item.name,
data: item.data,
}));
};
2024-06-14 09:40:18 +08:00
2024-06-17 11:50:40 +08:00
let interval;
let currentIndex = ref(0);
const toggleShow = () => {
const length = data.ViewData.length;
if (length === 0) return;
const current = currentIndex.value;
const nextIndex = (currentIndex.value + 1) % length;
// 取反当前索引和下一个索引的 show 值
// data.ViewData[current].show = !data.ViewData[current].show;
data.ViewData[nextIndex].show = !data.ViewData[nextIndex].show;
onViewData1(current);
currentIndex.value = nextIndex;
};
const startAutoSwitching = () => {
interval = setInterval(toggleShow, 6000); // 每6秒切换一次
2024-06-14 16:16:41 +08:00
};
2024-06-17 11:50:40 +08:00
onMounted(() => {
startAutoSwitching();
});
2024-06-14 09:40:18 +08:00
2024-06-14 16:16:41 +08:00
onBeforeMount(() => {});
2024-06-17 11:50:40 +08:00
onBeforeUnmount(() => {
clearInterval(interval); //清除定时器
});
2024-04-12 09:26:48 +08:00
</script>
<style lang="scss" scoped>
.displayFlex {
2024-06-14 09:40:18 +08:00
box-sizing: border-box;
height: 100%;
2024-04-12 09:26:48 +08:00
display: flex;
flex-direction: column;
2024-06-14 09:40:18 +08:00
// flex: 1;
width: 30%;
2024-04-12 09:26:48 +08:00
}
2024-06-14 09:40:18 +08:00
2024-04-12 09:26:48 +08:00
.flex1 {
flex: 1;
2024-06-14 09:40:18 +08:00
// padding: 0 28px;
2024-04-12 09:26:48 +08:00
box-sizing: border-box;
}
2024-06-14 09:40:18 +08:00
2024-04-12 09:26:48 +08:00
.module {
display: flex;
2024-06-14 09:40:18 +08:00
width: 100%;
2024-04-12 09:26:48 +08:00
}
2024-06-14 09:40:18 +08:00
.left_bg {
width: 642px;
// height: 100%;
box-sizing: border-box;
padding-left: 50px;
padding-right: 20px;
margin-right: 28px;
background-image: url(@/assets/images/left_bg.png);
2024-04-12 09:26:48 +08:00
background-repeat: no-repeat;
background-size: 100% 100%;
2024-06-14 09:40:18 +08:00
}
.center_bg {
width: 582px;
2024-04-12 09:26:48 +08:00
box-sizing: border-box;
2024-06-14 09:40:18 +08:00
padding-left: 10px;
padding-right: 10px;
background-image: url(@/assets/images/center_bg.png);
background-repeat: no-repeat;
background-size: 100% 100%;
}
.right_bg {
width: 642px;
box-sizing: border-box;
padding-right: 50px;
padding-left: 20px;
margin-left: 28px;
background-image: url(@/assets/images/right_bg.png);
background-repeat: no-repeat;
background-size: 100% 100%;
}
.left_1 {
background-image: url(@/assets/images/sjfx/lnrsjfx.png);
background-repeat: no-repeat;
background-size: 100% 100%;
}
2024-06-14 10:49:19 +08:00
.left_2 {
background-image: url(@/assets/images/sjfx/znfxSJCK.png);
background-repeat: no-repeat;
background-size: 100% 100%;
height: 28px;
}
2024-06-14 09:40:18 +08:00
.center_0 {
background-image: url(@/assets/images/sjfx/bft.png);
background-repeat: no-repeat;
background-size: 100% 100%;
}
.center_1 {
background-image: url(@/assets/images/sjfx/ymt.png);
background-repeat: no-repeat;
background-size: 100% 100%;
}
.right_1 {
background-image: url(@/assets/images/sjfx/wjybry.png);
background-repeat: no-repeat;
background-size: 100% 100%;
}
.right_2 {
background-image: url(@/assets/images/sjfx/xxts.png);
background-repeat: no-repeat;
background-size: 100% 100%;
}
.right_3 {
background-image: url(@/assets/images/sjfx/jtzk.png);
background-repeat: no-repeat;
background-size: 100% 100%;
}
.yd_title {
box-sizing: border-box;
width: 98%;
height: 42px;
2024-04-12 09:26:48 +08:00
position: relative;
2024-06-14 09:40:18 +08:00
overflow: hidden;
2024-04-12 09:26:48 +08:00
.text {
2024-06-14 09:40:18 +08:00
display: flex;
position: absolute;
2024-04-12 09:26:48 +08:00
font-size: 16px;
font-family: SourceHanSansCN;
font-weight: bold;
color: #ffffff;
position: absolute;
2024-06-14 09:40:18 +08:00
right: 5px;
2024-04-12 09:26:48 +08:00
top: 3px;
2024-06-14 09:40:18 +08:00
} /* 利用伪元素和两个i元素产生4条线 */
.animate-border {
position: absolute;
top: 0px;
width: 100%;
height: 100%;
&::before,
&::after {
content: "";
position: absolute;
width: 100%;
height: 2px;
2024-04-12 09:26:48 +08:00
}
2024-06-14 09:40:18 +08:00
i {
position: absolute;
display: inline-block;
height: 100%;
width: 2px;
2024-04-12 09:26:48 +08:00
}
2024-06-14 09:40:18 +08:00
&::before {
top: 0;
left: -100%;
background-image: linear-gradient(
90deg,
transparent,
#03e9f4,
transparent
);
2024-04-12 09:26:48 +08:00
2024-06-14 09:40:18 +08:00
animation: one 4s linear infinite;
2024-04-12 09:26:48 +08:00
}
2024-06-14 09:40:18 +08:00
i:nth-child(1) {
top: -100%;
right: 0;
background-image: linear-gradient(
180deg,
transparent,
#03e9f4,
transparent
);
/* 动画名称 动画持续时间 动画渲染函数 动画延迟时间 动画执行次数 */
animation: two 4s linear 1s infinite;
2024-04-12 09:26:48 +08:00
}
2024-06-14 09:40:18 +08:00
&::after {
bottom: 0;
right: -100%;
background-image: linear-gradient(
-90deg,
transparent,
#03e9f4,
transparent
);
animation: three 4s linear 2s infinite;
}
i:nth-child(2) {
bottom: -100%;
left: 0;
background-image: linear-gradient(
360deg,
transparent,
#03e9f4,
transparent
);
animation: four 4s linear 3s infinite;
2024-04-12 09:26:48 +08:00
}
}
}
2024-06-14 09:40:18 +08:00
@keyframes one {
0% {
left: -100%;
}
50%,
100% {
left: 100%;
2024-04-12 09:26:48 +08:00
}
}
2024-06-14 09:40:18 +08:00
@keyframes two {
0% {
top: -100%;
2024-04-12 09:26:48 +08:00
}
2024-06-14 09:40:18 +08:00
50%,
100% {
top: 100%;
2024-04-12 09:26:48 +08:00
}
}
2024-06-14 09:40:18 +08:00
@keyframes three {
0% {
right: -100%;
2024-04-12 09:26:48 +08:00
}
2024-06-14 09:40:18 +08:00
50%,
100% {
right: 100%;
2024-04-12 09:26:48 +08:00
}
}
2024-06-14 09:40:18 +08:00
@keyframes four {
0% {
bottom: -100%;
2024-04-12 09:26:48 +08:00
}
2024-06-14 09:40:18 +08:00
50%,
100% {
bottom: 100%;
}
}
.mechanism {
background-image: url(@/assets/YLTitle/titleImg10.png);
background-repeat: no-repeat;
background-size: 100% 100%;
}
.flex11 {
padding: 12px 0;
}
2024-06-14 10:51:07 +08:00
.map {
width: 560px;
height: 268px;
margin-top: 12px;
}
2024-06-14 11:33:07 +08:00
.right3d {
width: 560px;
2024-06-14 10:51:07 +08:00
height: 220px;
}
2024-06-14 09:40:18 +08:00
/* 滚动条整体部分 */
.rolling::-webkit-scrollbar {
width: 5px;
// height: 10px;
}
/* 滚动槽 */
.rolling::-webkit-scrollbar-track {
border-radius: 1px;
background: rgba(0, 128, 231, 0.56);
-webkit-box-shadow: inset 0 0 6px rgba(139, 139, 139, 0.3);
}
/* 滚动条滑块样式 */
.rolling::-webkit-scrollbar-thumb {
background-clip: content-box;
border-radius: 6px;
background: rgba(0, 162, 231, 1);
-webkit-box-shadow: inset 0 0 6px rgba(20, 20, 20, 0.3);
2024-04-12 09:26:48 +08:00
}
2024-06-14 10:49:19 +08:00
.hypertension {
display: flex;
}
2024-06-14 11:31:54 +08:00
.ViewData {
.ViewDatalist {
2024-06-14 16:16:41 +08:00
display: flex;
flex-wrap: wrap;
color: #ffffff;
2024-06-17 17:04:26 +08:00
margin-top: 14px;
2024-06-14 11:31:54 +08:00
.ViewDataTop {
2024-06-14 16:16:41 +08:00
width: 114px;
2024-06-17 17:04:26 +08:00
height: 132px;
2024-06-14 11:31:54 +08:00
display: flex;
align-items: center;
flex-direction: column;
2024-06-14 16:16:41 +08:00
.ViewDataTopimg {
background-image: url(@/assets/images/sjfx/sjfx.png);
background-repeat: no-repeat;
background-size: 100% 100%;
width: 80px;
height: 80px;
2024-06-17 17:04:26 +08:00
margin-bottom: -28px;
2024-06-14 16:16:41 +08:00
text-align: center;
line-height: 100px;
2024-06-17 17:04:26 +08:00
animation: moveUpDown 2s infinite;
2024-06-14 16:16:41 +08:00
}
.ViewDataTopimg_1 {
background-image: url(@/assets/images/sjfx/sjfx1.png);
background-repeat: no-repeat;
background-size: 100% 100%;
width: 105px;
height: 57px;
}
.ViewDataBottomimg {
background-image: url(@/assets/images/sjfx/sjfx2.png);
2024-06-17 17:04:26 +08:00
animation: scaleUpDown 2s infinite;
2024-06-14 16:16:41 +08:00
}
.ViewDataBottomimg_1 {
background-image: url(@/assets/images/sjfx/sjfx3.png);
2024-06-17 17:04:26 +08:00
margin-top: 4px;
}
@keyframes moveUpDown {
0%,
100% {
transform: translateY(0);
}
50% {
transform: translateY(-10px);
}
}
@keyframes scaleUpDown {
0%,
100% {
transform: scale(1);
}
50% {
transform: scale(1.1);
}
2024-06-14 16:16:41 +08:00
}
2024-06-14 11:31:54 +08:00
}
}
}
2024-06-14 10:46:56 +08:00
.minTopTitle {
width: 100%;
height: 28px;
background-image: url(@/assets/images/sjfx/yjj.png);
background-repeat: no-repeat;
background-size: 100% 100%;
margin: 4px auto;
2024-06-14 10:48:25 +08:00
margin-top: 13px;
2024-06-14 10:46:56 +08:00
}
.minTopNum {
width: 100%;
height: 120px;
display: flex;
align-items: center;
justify-content: center;
.numItem {
width: 72px;
height: 114px;
text-align: center;
line-height: 114px;
font-weight: 400;
font-size: 60px;
margin: 0 3px;
color: #ffffff;
text-shadow: 0px 2px 4px rgba(0, 0, 0, 0.5);
background-image: url(@/assets/images/sjfx/mtNum.png);
background-repeat: no-repeat;
background-size: 100% 100%;
}
.numItem:last-child {
width: 72px;
height: 114px;
text-align: center;
line-height: 114px;
font-weight: 400;
font-size: 36px;
margin: 0 3px;
color: #ffffff;
text-shadow: 0px 2px 4px rgba(0, 0, 0, 0.5);
background-image: url(@/assets/images/sjfx/mtNum2.png);
background-repeat: no-repeat;
background-size: 100% 100%;
}
}
2024-06-14 10:51:23 +08:00
.minPie {
2024-06-14 11:33:07 +08:00
width: 50%;
2024-06-14 10:46:56 +08:00
position: relative;
2024-06-14 11:33:07 +08:00
float: left;
2024-06-14 10:51:23 +08:00
.minPieImg {
2024-06-14 11:33:07 +08:00
position: absolute;
width: 137px;
height: 20px;
background-image: url(@/assets/images/sjfx/minPieT.png);
background-repeat: no-repeat;
background-size: 100% 100%;
text-align: center;
font-size: 16px;
color: #ffffff;
line-height: 22px;
letter-spacing: 4px;
top: 140px;
left: 75px;
z-index: 2;
2024-06-14 10:46:56 +08:00
}
}
2024-04-12 09:26:48 +08:00
</style>