Merge branch 'main' of git.zdool.com:xs/ggfwjsc

This commit is contained in:
lnn19986213 2024-06-24 16:15:03 +08:00
commit 04cc012444
14 changed files with 239 additions and 97 deletions

BIN
dist.zip Normal file

Binary file not shown.

View File

@ -9,7 +9,7 @@
</div> </div>
</div> </div>
<div class="hypertension"> <div class="hypertension">
<pie3dMt1 :list="data.gxy"></pie3dMt1> <pie3dMt1 :list="data.analysis.lnr"></pie3dMt1>
<edxs <edxs
:list="data.whistleblower.culeTotal.data" :list="data.whistleblower.culeTotal.data"
:month="data.whistleblower.culeTotal.time" :month="data.whistleblower.culeTotal.time"
@ -122,7 +122,7 @@
</div> </div>
</div> </div>
<!-- <img src="@/assets/images/sjfx/right3D.png" alt="" class="right3d" /> --> <!-- <img src="@/assets/images/sjfx/right3D.png" alt="" class="right3d" /> -->
<right2></right2> <right2 :list="data.analysis.push"></right2>
</div> </div>
<div class="flex1"> <div class="flex1">
<div class="yd_title right_3"> <div class="yd_title right_3">
@ -261,12 +261,35 @@ const data = reactive({
}, },
], // ], //
leftCenterYear: ["2019", "2020", "2021", "2022", "2023"], // leftCenterYear: ["2019", "2020", "2021", "2022", "2023"], //
// leftCenter1: ["100", "120", "199", "133", "210"], //
// leftCenter3: ["100", "80", "199", "133", "210"], //
// leftCenter4: ["100", "120", "199", "133", "210"], //尿
zccs1: ["图书馆", "交通出行", "景区"], // zccs1: ["图书馆", "交通出行", "景区"], //
zccs2: ["100", "130", "220"], // zccs2: ["100", "130", "220"], //
analysis: {
lnr: {
fgxy: { rs: "1610", zb: "51.77" },
gxy: { rs: "1500", zb: "48.23" },
rksj: {
man: "196576",
nl17: "48.23", // 17
nl60: "0", // 60
nl100: "0", // 100,
nl110: "0", // 1-10
nl1120: "0", // 11-20
nl1834: "0", // 18-34
nl2130: "0", // 21-30
nl3140: "0", // 31-40
nl3569: "0", // 35-69
nl4150: "0", // 41-50
nl5160: "0", // 51-60
nl6170: "0", // 61-70
nl7180: "0", // 71-80
nl8190: "0", // 81-90
nl91100: "0", // 91-100
rkzs: "390754",
woman: "194178",
},
},
push: [{ name: "小奔通", num: 4196 }],
},
}); });
const minData = reactive({ const minData = reactive({
minTop: 49162, minTop: 49162,
@ -320,11 +343,26 @@ const toggleShow = () => {
const startAutoSwitching = () => { const startAutoSwitching = () => {
interval = setInterval(toggleShow, 6000); // 6 interval = setInterval(toggleShow, 6000); // 6
}; };
const getData = async () => {
await http.get("/api/ggfwyth/analysis").then((res) => {
if (res.code == 200) {
// console.log(res.data, "");
data.analysis = res.data;
const ageBt = ["nl6170", "nl7180", "nl8190", "nl91100", "nl100"];
ageBt.forEach((key, index) => {
data.whistleblower.culeTotal.data[index] = res.data.lnr.rksj[key];
});
}
});
};
onMounted(() => { onMounted(() => {
startAutoSwitching(); startAutoSwitching();
}); });
onBeforeMount(() => {}); onBeforeMount(() => {
getData();
});
onBeforeUnmount(() => { onBeforeUnmount(() => {
clearInterval(interval); // clearInterval(interval); //

View File

@ -67,6 +67,7 @@ const updateSeries = () => {
]; ];
if (data.list.length > 0) { if (data.list.length > 0) {
// if (!data.list) {
data.list.forEach((item, index) => { data.list.forEach((item, index) => {
const color = data.bgColor[index % data.bgColor.length]; const color = data.bgColor[index % data.bgColor.length];
data.series.push({ data.series.push({

View File

@ -35,8 +35,8 @@ const getOption = () => {
}, },
grid: { grid: {
top: "20%", top: "20%",
left: "1%", left: "0%",
right: "5%", right: "3%",
bottom: "0%", bottom: "0%",
containLabel: true, containLabel: true,
}, },
@ -186,12 +186,12 @@ const setChart = () => {
var myChart = echarts.init(chart.value); var myChart = echarts.init(chart.value);
myChart.setOption(data.option); myChart.setOption(data.option);
}; };
// 使 // 使
onBeforeMount(() => { onBeforeMount(() => {
setTimeout(() => { setTimeout(() => {
data.list = props.list; data.list = props.list;
data.month = props.month; data.month = props.month;
// console.log(data.list, props.month, "");
getOption(); getOption();
setChart(); setChart();
}, 600); }, 600);

View File

@ -1,8 +1,5 @@
<template> <template>
<div <div ref="chart" style="width: 50%; height: 230px"></div>
ref="chart"
style="width: 50%; height: 230px"
></div>
</template> </template>
<script setup> <script setup>
@ -261,6 +258,7 @@ function getPie3D(pieData, internalDiameterRatio) {
} }
}, },
}, },
// //
tooltip: { tooltip: {
backgroundColor: "rgba(18, 55, 85, 0.8);", backgroundColor: "rgba(18, 55, 85, 0.8);",
@ -287,6 +285,23 @@ function getPie3D(pieData, internalDiameterRatio) {
} }
}, },
}, },
label: {
show: true,
// position: "outside",
// padding: [30, -180],
formatter: function (pieData) {
console.log("optionsData", pieData);
return (
"{name|" +
pieData.name +
"}" +
"{vlaueA|" +
pieData.value +
"亿元" +
"}"
);
},
},
xAxis3D: {}, xAxis3D: {},
yAxis3D: {}, yAxis3D: {},
zAxis3D: {}, zAxis3D: {},
@ -550,13 +565,13 @@ const setChart = () => {
// 使 // 使
onBeforeMount(() => { onBeforeMount(() => {
setTimeout(() => { setTimeout(() => {
// data.list = props.list; data.list = props.list;
data.list = { // data.list = {
gxy:"1500", // gxy: "1500",
notGxy:"1610", // notGxy: "1610",
} // };
pieData[0].value = data.list.gxy; pieData[0].value = data.list.fgxy.rs;
pieData[1].value = data.list.notGxy; pieData[1].value = data.list.gxy.rs;
getOption(); getOption();
setChart(); setChart();

View File

@ -7,6 +7,15 @@ import { onMounted, onBeforeMount, reactive, ref } from "vue";
// echarts // echarts
import * as echarts from "echarts"; import * as echarts from "echarts";
const props = defineProps({
list: {
type: Array,
default: () => {
return [];
},
},
});
const chart = ref(); // DOM const chart = ref(); // DOM
const colors = [ const colors = [
@ -33,10 +42,21 @@ const colors = [
}, },
]; ];
const maxList = ref([]); const maxList = ref([]);
const valueList = [20, 53, 47, 65, 29, 11, 10]; // const valueList = [20, 53, 47, 65, 29, 11, 10];
const data = reactive({ const data = reactive({
list: [],
option: {}, option: {},
Max: 100, Max: 200,
valueList: [20, 53, 47, 65, 29, 11, 10],
xxname: [
"小奔通",
"两慢病",
"水费",
"就业招工",
"零工市厂匹配",
"医保",
"交通出行",
],
}); });
// 5: // 5:
//c0:c1,c2:c3 //c0:c1,c2:c3
@ -156,21 +176,13 @@ const getOption = () => {
left: 10, left: 10,
right: 0, right: 0,
bottom: 20, bottom: 20,
top: 20, top: 30,
containLabel: true, containLabel: true,
}, },
xAxis: [ xAxis: [
{ {
type: "category", type: "category",
data: [ data: data.xxname,
"小奔通",
"两慢病",
"水费",
"就业招工",
"零工市厂匹配",
"医保",
"交通出行",
],
axisLine: { axisLine: {
show: false, show: false,
}, },
@ -190,15 +202,7 @@ const getOption = () => {
}, },
{ {
type: "category", type: "category",
data: [ data: data.xxname,
"小奔通",
"两慢病",
"水费",
"就业招工",
"零工市厂匹配",
"医保",
"交通出行",
],
axisLine: { axisLine: {
show: false, show: false,
}, },
@ -216,9 +220,8 @@ const getOption = () => {
], ],
yAxis: { yAxis: {
min: 0, min: 0,
// max: 200,
max: data.Max, max: data.Max,
interval: 20, // interval: 100,
type: "value", type: "value",
axisLine: { axisLine: {
show: true, show: true,
@ -247,7 +250,7 @@ const getOption = () => {
{ {
type: "custom", type: "custom",
renderItem: function (params, api) { renderItem: function (params, api) {
console.log(api); // console.log(api);
const location = api.coord([api.value(0), api.value(1)]); const location = api.coord([api.value(0), api.value(1)]);
return { return {
type: "group", type: "group",
@ -399,7 +402,7 @@ const getOption = () => {
}; };
}, },
data: valueList, data: data.valueList,
}, },
// //
{ {
@ -418,7 +421,7 @@ const getOption = () => {
color: "rgba(221, 242, 255, 0)", color: "rgba(221, 242, 255, 0)",
}, },
data: valueList.map((item) => item + 5), data: data.valueList.map((item) => parseInt(item) + 5),
barWidth: 20, barWidth: 20,
}, },
], ],
@ -429,21 +432,30 @@ const setChart = () => {
myChart.setOption(data.option); myChart.setOption(data.option);
}; };
const getMaxCeilingValue = (arr) => { const getMaxCeilingValue = (arr) => {
let max = Math.max(...arr); let max = Math.max(...arr);//
return Math.ceil(max / 100) * 100; return Math.ceil(max / 100) * 100;// 100
};
const setChart1 = () => {
data.valueList = [];
data.xxname = [];
if (data.list.length !== 0) {
data.list.forEach((item) => {
data.xxname.push(item.name); //
data.valueList.push(item.num); //
});
}
}; };
onBeforeMount(() => { onBeforeMount(() => {
setTimeout(() => { setTimeout(() => {
data.Max = getMaxCeilingValue(valueList); data.list = props.list;
maxList.value = valueList.map((item) => data.Max * 0.9); setChart1();
data.Max = getMaxCeilingValue(data.valueList);
maxList.value = data.valueList.map((item) => parseInt(data.Max) * 0.9);// data.Max 90%
getOption(); getOption();
setChart(); setChart();
}, 600); }, 800);
}); });
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped></style>
</style>

View File

@ -138,6 +138,8 @@ const resultData = [
value: 100, value: 100,
}, },
]; ];
var max = 0;
var number = 0;
const getOption1 = () => { const getOption1 = () => {
// data.list[0].value = data.list.nl17; // data.list[0].value = data.list.nl17;
// data.list[1].value = data.list.nl1834; // data.list[1].value = data.list.nl1834;
@ -157,11 +159,20 @@ const getOption1 = () => {
data.list[10].value = parseInt(data.list1.nl100); data.list[10].value = parseInt(data.list1.nl100);
let sum = 0; let sum = 0;
data.list.forEach((item) => { data.list.forEach((item) => {
if (item.value > max) {
max = item.value;
}
sum += item.value; sum += item.value;
}); });
//
number = Math.round(max * 0.2);
data.list.forEach((item) => { data.list.forEach((item) => {
optionData.push({ value: item.value, name: item.name }); optionData.push({
value: item.value + number,
name: item.name,
});
optionData.push({ optionData.push({
name: "", name: "",
value: sum / 100, value: sum / 100,
@ -224,7 +235,7 @@ const getOption = () => {
let res = ""; let res = "";
const { marker, name, value } = params; const { marker, name, value } = params;
if (name !== "") { if (name !== "") {
res += `${marker}${name}:${value}`; res += `${marker}${name}:${value-number}`;
} }
return res; return res;
}, },

View File

@ -326,7 +326,7 @@ onBeforeMount(() => {
setTimeout(() => { setTimeout(() => {
data.list = props.list; data.list = props.list;
data.day = props.list.day; data.day = props.list.day;
console.log(data.list, "助老服务"); // console.log(data.list, "");
setChart1(); setChart1();
getOption(); getOption();
setChart(); setChart();

View File

@ -92,32 +92,32 @@
<div class="schoolb"> <div class="schoolb">
<img src="../assets/eduImg/xxgkTop.png" class="gkTop" alt="" /> <img src="../assets/eduImg/xxgkTop.png" class="gkTop" alt="" />
<div class="grade"> <div class="grade">
<div class="schoolbs" @click="showDialog('学校', '')"> <div class="schoolbs" @click="showDialog('学校', '/api/ggfwyth/schoolList')">
<span class="spot">初中</span> <span class="spot">初中</span>
<span>{{ data.xxgk.czxxsl }}</span> <span>{{ data.xxgk.czxxsl }}</span>
</div> </div>
<div class="schoolbs" @click="showDialog('学校', '')"> <div class="schoolbs" @click="showDialog('学校', '/api/ggfwyth/schoolList')">
<span class="spot">高中</span> <span class="spot">高中</span>
<span>{{ data.xxgk.gzxxsl }}</span> <span>{{ data.xxgk.gzxxsl }}</span>
</div> </div>
</div> </div>
<div class="grade"> <div class="grade">
<div class="schoolbs" @click="showDialog('学校', '')"> <div class="schoolbs" @click="showDialog('学校', '/api/ggfwyth/schoolList')">
<span class="spot">小学</span> <span class="spot">小学</span>
<span>{{ data.xxgk.xxxxsl }}</span> <span>{{ data.xxgk.xxxxsl }}</span>
</div> </div>
<div class="schoolbs" @click="showDialog('学校', '')"> <div class="schoolbs" @click="showDialog('学校', '/api/ggfwyth/schoolList')">
<span class="spot">中职</span> <span class="spot">中职</span>
<span>{{ data.xxgk.zzxxsl }}</span> <span>{{ data.xxgk.zzxxsl }}</span>
</div> </div>
</div> </div>
<div class="grade grade1"> <div class="grade grade1">
<div class="schoolbs" @click="showDialog('学校', '')"> <div class="schoolbs" @click="showDialog('学校', '/api/ggfwyth/schoolList')">
<span class="spot">幼儿园</span> <span class="spot">幼儿园</span>
<span>{{ data.xxgk.yeyxxsl }}</span> <span>{{ data.xxgk.yeyxxsl }}</span>
</div> </div>
<div class="schoolbs"> <div class="schoolbs">
<span class="spot" @click="showDialog('学校', '')" <span class="spot" @click="showDialog('学校', '/api/ggfwyth/schoolList')"
>特殊教育</span >特殊教育</span
> >
<span>{{ data.xxgk.tsjyxxsl }}</span> <span>{{ data.xxgk.tsjyxxsl }}</span>
@ -426,21 +426,50 @@ const tableType = reactive({
url: "", url: "",
title: "", title: "",
columns: [ columns: [
// {
// label: "",
// property: "school",
// },
// {
// label: "",
// property: "teacher",
// },
// {
// label: "",
// property: "student",
// },
// {
// label: "",
// property: "banji",
// },
{ {
label: "学校", label: "班级数",
property: "school", property: "bjs",
}, },
{ {
label: "教师数", label: " 教师数",
property: "teacher", property: "jss",
},
{
label: "区域",
property: "qq",
},
{
label: "学段",
property: "xd",
}, },
{ {
label: "学生数", label: "学生数",
property: "student", property: "xss",
}, },
{ {
label: "班级数", label: " 学校名称",
property: "banji", property: "xxmc",
},
{
label: "性质",
property: "xz",
}, },
], ],
data: [], data: [],
@ -460,20 +489,20 @@ const showDialog = (title, url) => {
tableType.url = url; tableType.url = url;
pagination.currentPage = 1; pagination.currentPage = 1;
dialogShow.value = true; dialogShow.value = true;
// getTable(url, pagination.currentPage); getTable(url, pagination.currentPage);
}; };
// //
const getTable = (url, currentPage) => { const getTable = (url, currentPage) => {
dialogShow.value = true; dialogShow.value = true;
// http http
// .get(`${url}?page=${currentPage}&size=${pagination.pageSize}`) .get(`${url}?page=${currentPage}&size=${pagination.pageSize}`)
// .then((res) => { .then((res) => {
// if (res.code == 200) { if (res.code == 200) {
// tableType.data = res.data; tableType.data = res.data;
// pagination.total = res.count; pagination.total = res.count;
// dialogShow.value = true; dialogShow.value = true;
// } }
// }); });
}; };
const close = () => { const close = () => {
dialogShow.value = false; dialogShow.value = false;
@ -1789,6 +1818,34 @@ onMounted(() => {
} }
} }
} }
:deep(.el-table) {
background: rgba(32, 64, 115, 1);
--el-table-border-color: none;
border: 1px solid #7aceff;
}
.table {
:deep(.el-table td.el-table__cell, .el-table th.el-table__cell.is-leaf) {
border: none !important;
padding-left: 10px !important;
}
:deep(.el-table td.el-table__cell) {
padding-left: 10px;
}
}
:deep(.el-table--enable-row-hover .el-table__body tr:hover > td) {
background-color: #2f4b74;
}
:deep(.el-table__empty-block) {
background-color: #122560;
}
:deep(.el-table .el-table__row) {
border-bottom: none;
}
</style> </style>
<style lang="scss"> <style lang="scss">
.selectBox { .selectBox {

View File

@ -271,7 +271,10 @@ onBeforeMount(async () => {
getData(); getData();
}); });
onMounted(() => { onMounted(() => {
startAutoScroll(); setTimeout(()=>{
startAutoScroll();
},600)
// console.log( // console.log(
// mainRef.value.scrollTop, // mainRef.value.scrollTop,
// mainRef.value.scrollHeight, // mainRef.value.scrollHeight,

View File

@ -397,7 +397,7 @@
class="ylws_item" class="ylws_item"
v-for="(item, index) in data.ylwsList" v-for="(item, index) in data.ylwsList"
:key="index" :key="index"
@click="showDialog2(item.name, '')" @click="showDialog2(item.name, '/api/ggfwyth/yywsyList')"
> >
<div class="name">{{ item.name }}</div> <div class="name">{{ item.name }}</div>
<div class="value">{{ item.value }}</div> <div class="value">{{ item.value }}</div>
@ -745,15 +745,15 @@ const columnss = reactive({
const ylws_columns = ref([ const ylws_columns = ref([
{ {
label: "医院名称", label: "医院名称",
property: "name", property: "yymc",
}, },
{ {
label: "医生数", label: "医生数",
property: "ys", property: "zyyss",
}, },
{ {
label: "护士数", label: "护士数",
property: "hs", property: "zchss",
}, },
{ {
label: "家庭医生签约数", label: "家庭医生签约数",
@ -761,7 +761,7 @@ const ylws_columns = ref([
}, },
{ {
label: "床位数", label: "床位数",
property: "cws", property: "hdcws",
}, },
]); ]);
const tableType = reactive({ const tableType = reactive({
@ -808,7 +808,7 @@ const showDialog2 = (title, url) => {
tableType.url = url; tableType.url = url;
tableType.columns = ylws_columns.value; tableType.columns = ylws_columns.value;
dialogShow.value = true; dialogShow.value = true;
// getTable(url, pagination.currentPage); getTable(url, pagination.currentPage);
} }
}; };
@ -1278,6 +1278,7 @@ const getTable = (url, currentPage) => {
.get(`${url}?page=${currentPage}&size=${pagination.pageSize}`) .get(`${url}?page=${currentPage}&size=${pagination.pageSize}`)
.then((res) => { .then((res) => {
if (res.code == 200) { if (res.code == 200) {
console.log(res,'表格数据');
tableType.data = res.data; tableType.data = res.data;
pagination.total = res.count; pagination.total = res.count;
dialogShow.value = true; dialogShow.value = true;

View File

@ -454,7 +454,9 @@ const startAutoSwitching = () => {
interval = setInterval(toggleShow, 6000); // 6 interval = setInterval(toggleShow, 6000); // 6
}; };
onMounted(() => { onMounted(() => {
startAutoScroll(); setTimeout(()=>{
startAutoScroll();
},600)
startAutoSwitching(); startAutoSwitching();
}); });

View File

@ -1207,6 +1207,7 @@ const getData = () => {
color: #ffffff; color: #ffffff;
} }
} }
:deep(.el-table) { :deep(.el-table) {
background: rgba(32, 64, 115, 1); background: rgba(32, 64, 115, 1);

View File

@ -15,7 +15,8 @@ export default defineConfig({
// 第一个代理 // 第一个代理
"/api": { "/api": {
// 匹配到啥来进行方向代理 // 匹配到啥来进行方向代理
target: "http://192.168.2.42:8095/", //本地 // target: "http://192.168.2.42:8095/", //本地
target: "http://192.168.2.17:8095/", //刘进
// target: "http://220.191.238.50:996/", //线上 // target: "http://220.191.238.50:996/", //线上
changeOrigin: true, //是否支持跨域 changeOrigin: true, //是否支持跨域
//rewrite: (path) => path.replace(/^\/api/, '') // 如果不需要api 直接把路径上的api 替换成空,这个 //rewrite: (path) => path.replace(/^\/api/, '') // 如果不需要api 直接把路径上的api 替换成空,这个
@ -38,7 +39,7 @@ export default defineConfig({
build: { build: {
chunkSizeWarningLimit: 1500, chunkSizeWarningLimit: 1500,
assetsDir: 'assets', // 指定生成静态文件目录 assetsDir: "assets", // 指定生成静态文件目录
}, },
base: './' base: "./",
}); });