This commit is contained in:
闫世杰 2024-08-01 17:29:20 +08:00
commit 6c38f6c9f9
4 changed files with 113 additions and 79 deletions

View File

@ -700,9 +700,9 @@ const minData = reactive({
zq: "1610",
},
minPieData2: {
wfgz: "1500",
xstp: "1610",
skym: "1610",
wfgz: "4754",
xstp: "31145",
skym: "13255",
},
});
//

View File

@ -10,11 +10,7 @@
>
<template #header="{ close, titleId, titleClass }">
<div class="my-header">
<el-icon
size="26"
color="#fff"
@click="closeDialog"
>
<el-icon size="26" color="#fff" @click="closeDialog">
<CircleCloseFilled />
</el-icon>
</div>
@ -49,6 +45,8 @@
height="100%"
:header-cell-style="{ background: '#008FCD' }"
:key="tableKey"
@row-click="handleRowClick"
class="custom-table-font"
>
<!-- <el-table-column
v-for="(item, index) in data.columns"
@ -88,6 +86,7 @@
<div class="pagePart">
<el-pagination
class="small-pagination"
background
layout="prev, pager, next,total"
:page-size="pagination.pageSize"
@ -113,6 +112,9 @@ import {
nextTick,
} from "vue";
import { CircleCloseFilled } from "@element-plus/icons-vue";
import { useRouter, useRoute } from "vue-router";
const router = useRouter();
const routers = useRoute();
const props = defineProps({
dialogShow: {
type: Boolean,
@ -144,7 +146,13 @@ const props = defineProps({
},
});
const emit = defineEmits(["close", "handle"]);
const handleRowClick = (row, column, event) => {
// row
console.log(row);
router.push({
path: `/home/index/person`,
});
};
//
const dialogShow = ref();
const data = reactive({
@ -269,7 +277,7 @@ const handle = (current) => {
}
.title {
margin: 10px auto;
margin: 0px auto;
display: flex;
flex-direction: column;
@ -285,9 +293,9 @@ const handle = (current) => {
.name {
font-family: PangMenZhengDao, PangMenZhengDao;
font-weight: 600;
font-size: 24px;
font-size: 22px;
color: #ffffff;
line-height: 38px;
line-height: 27px;
text-align: center;
font-style: normal;
letter-spacing: 2px;
@ -304,4 +312,14 @@ const handle = (current) => {
height: 19px;
}
}
.custom-table-font {
font-size: 10px;
}
:deep(.el-table:not(.el-table--border) .el-table__cell){
padding: 3px 0px;
}
:deep(.el-pagination ){
transform: scale(0.8);
}
</style>

View File

@ -70,17 +70,17 @@ const pieData = reactive([
{
name: "0-18岁", //
value: 0, //
per: 2,
per: 9.67,
},
{
name: "19-60岁",
value: 0,
per: 8,
per: 63.37,
},
{
name: "60岁以上",
value: 0,
per: 10,
per: 26.97,
},
]);

View File

@ -1237,7 +1237,7 @@ const getDatas = async (e, i) => {
}
if (cfJd.value != "") {
xkzCenter.map((item) => {
// item.number = 0;
item.swrs = 0;
res.data.committeeSwrs.map((items) => {
if (items.csq == item.name) {
item.swrs = items.swrs;
@ -1400,6 +1400,15 @@ const getDatas2 = async (e, i, cs) => {
}
}
});
if (choose.value.person == "") {
cs_dd_arr.value.map((item, index) => {
DGcreateCs(item, index);
});
} else {
cs_dd_arr.value.map((item, index) => {
DGcreateCs2(item, index);
});
}
};
//
//
@ -1600,13 +1609,13 @@ const to_jd = (item_name) => {
// console.log(111, choose.value.person);
cfJd.value = item_name;
let jdCenter = [];
if (item_name == "溪口镇") {
BMAP();
if (choose.value.person == "") {
getDatas("溪口镇", "");
}
loadCs(item_name);
addPolygonCountyCs();
getDataBq(cfJd.value, "");
if (choose.value.person == "") {
getDatas(cfJd.value, "");
}
if (
choose.value.person == "cjr" ||
choose.value.person == "dibian" ||
@ -1617,27 +1626,30 @@ const to_jd = (item_name) => {
choose.value.person == "kjer"
) {
getDataBqs2(cfJd.value, cfCs.value, choose.value.person, false);
getDatas("溪口镇", "");
getDatas(cfJd.value, "");
} else if (choose.value.person != "") {
if (choose.value.person == "9999") {
getDatas("溪口镇", "");
getDatas(cfJd.value, "");
} else {
if (choose.value.person == 1) {
getDatas("溪口镇", "0"); //0
getDatas(cfJd.value, "0"); //0
} else {
getDatas("溪口镇", choose.value.person - 1);
getDatas(cfJd.value, choose.value.person - 1);
}
}
}
loadCs(item_name);
addPolygonCountyCs();
mapTownCount.map((item) => {
if (item.name == item_name) {
jdCenter = item.center;
// if (title_jd.value == item.name) {
// } else {
// title_jd.value = item.name;
// }
mapTownCount.map((itemm) => {
if (itemm.name == item_name) {
jdCenter = itemm.center;
}
});
goMapCenter(jdCenter, 13);
}
// }
};
//
@ -2012,7 +2024,7 @@ const createCustomOverlayJd = (polygon, indexx) => {
div.setAttribute("name", this.properties.title);
var title = document.createElement("div");
title.style.fontSize = "10px";
title.style.fontSize = "12px";
title.style.fontWeight = "600";
title.style.color = "#000000";
div.appendChild(title);
@ -2053,14 +2065,14 @@ const createCustomOverlayJd2 = (polygon, indexx) => {
div.setAttribute("name", this.properties.title);
var title = document.createElement("div");
title.style.fontSize = "10px";
title.style.fontSize = "12px";
title.style.fontWeight = "600";
title.style.color = "#000000";
div.appendChild(title);
title.appendChild(document.createTextNode(this.properties.title));
content.appendChild(div);
var number = document.createElement("div");
number.style.fontSize = "12px";
number.style.fontSize = "13px";
number.style.fontWeight = "600";
number.style.color = "#FEFF6C";
number.style.textShadow = "0px 2px 4px rgba(0,0,0,0.5)";
@ -2217,15 +2229,15 @@ const addPolygonCountyCs = () => {
getDatas2(cfJd.value, choose.value.person, cfCs.value);
addCsChoose();
addCsUnChoose();
if (choose.value.person == "") {
cs_dd_arr.value.map((item, index) => {
DGcreateCs(item, index);
});
} else {
cs_dd_arr.value.map((item, index) => {
DGcreateCs2(item, index);
});
}
// if (choose.value.person == "") {
// cs_dd_arr.value.map((item, index) => {
// DGcreateCs(item, index);
// });
// } else {
// cs_dd_arr.value.map((item, index) => {
// DGcreateCs2(item, index);
// });
// }
});
}
});
@ -2319,11 +2331,12 @@ const addCsUnChoose = () => {
// ) {
// getDataBqs2(cfJd.value, cfCs.value, choose.value.person, false);
// }
if (choose.value.person == "") {
cs_dd_arr.value.map((item, index) => {
DGcreateCs(item, index);
});
} else if (
// if (choose.value.person == "") {
// cs_dd_arr.value.map((item, index) => {
// DGcreateCs(item, index);
// });
// } else
if (
choose.value.person == "cjr" ||
choose.value.person == "dibian" ||
choose.value.person == "db" ||
@ -2333,13 +2346,16 @@ const addCsUnChoose = () => {
choose.value.person == "kjer"
) {
getDataBqs2(cfJd.value, cfCs.value, choose.value.person, false);
} else {
setTimeout(() => {
cs_dd_arr.value.map((item, index) => {
DGcreateCs2(item, index);
});
}, 600);
}
// if (choose.value.person == "") {
// cs_dd_arr.value.map((item, index) => {
// DGcreateCs(item, index);
// });
// } else {
// cs_dd_arr.value.map((item, index) => {
// DGcreateCs2(item, index);
// });
// }
addCsChoose();
addCsUnChoose();
});
@ -2649,7 +2665,7 @@ const reset_font = () => {
}
};
onMounted(() => {
tools.data.set("token", "6b0e380b4a8f46baae4923f83faf670d");
// tools.data.set("token", "6b0e380b4a8f46baae4923f83faf670d");
reset_font();
initMap();
getData();