This commit is contained in:
姚宇浩 2024-08-13 10:09:27 +08:00
parent 8373cc7404
commit 1404413c5a
1 changed files with 67 additions and 62 deletions

View File

@ -904,7 +904,7 @@ const markera = (e) => {
}; };
// //
const buten = async (item) => { const buten = async (item) => {
if (choose.value.person == item.id) { if (choose.value.person == item.age) {
choose.value.person = ""; choose.value.person = "";
jdm_number_arr.value.forEach((item, index) => { jdm_number_arr.value.forEach((item, index) => {
map.removeOverlay(jdm_number_arr.value[index]); map.removeOverlay(jdm_number_arr.value[index]);
@ -1226,7 +1226,7 @@ const getDatas = async (e, i, y = true) => {
const getDatas2 = async (e, i, cs) => { const getDatas2 = async (e, i, cs) => {
let i1 = i; let i1 = i;
if ( if (
i == "残疾人" || i == "残疾人" ||
i == "低边" || i == "低边" ||
i == "低保" || i == "低保" ||
i == "高血压" || i == "高血压" ||
@ -1265,8 +1265,18 @@ const getDatas2 = async (e, i, cs) => {
personTotal.value[1].rksl = res.data.swrs; personTotal.value[1].rksl = res.data.swrs;
personTotal.value[1].ages = "近一年死亡"; personTotal.value[1].ages = "近一年死亡";
personTotal.value[1].percent = res.data.swrsPercent; personTotal.value[1].percent = res.data.swrsPercent;
// res.data.age.forEach((item, index) => {
// personTotal.value.push({
// id: index + 1,
// rksl: item.rksl,
// age: item.age + "",
// ages: item.age + "",
// percent: item.percent,
// });
// });
let before_age = ""; let before_age = "";
res.data.age.forEach((item, index) => { res.data.age.forEach((item, index) => {
if (index == 0 && item.age == 0) { if (index == 0 && item.age == 0) {
personTotal.value.push({ personTotal.value.push({
rksl: item.rksl, rksl: item.rksl,
@ -1382,7 +1392,6 @@ const getDataBq = async (jd, cs) => {
tagId: item.tagId, tagId: item.tagId,
}); });
}); });
} }
}); });
}; };
@ -1492,7 +1501,7 @@ const getDataBqs3 = async (jd, cs, bq) => {
}); });
if (cs == "" && jd == "") { if (cs == "" && jd == "") {
data = { data = {
tagId: tagIdBq, tagId: btagIdBqq,
}; };
vv = 1; vv = 1;
} else if (cs == "") { } else if (cs == "") {
@ -1540,6 +1549,8 @@ const getDataBqs3 = async (jd, cs, bq) => {
// //
const getDataBqJD = async (bq) => { const getDataBqJD = async (bq) => {
let data = {}; let data = {};
console.log(tsbq_id_total.value);
tsbq_id_total.value.forEach((item, index) => { tsbq_id_total.value.forEach((item, index) => {
if (bq == item.name) { if (bq == item.name) {
data = { data = {
@ -1566,6 +1577,13 @@ const getDataBqJD = async (bq) => {
}; };
// //
const changeRs = (id) => { const changeRs = (id) => {
// if (choose.value.person == id) {
// choose.value.person = "";
// jdm_number_arr.value.forEach((item, index) => {
// map.removeOverlay(jdm_number_arr.value[index]);
// });
// addJd();
// } else {
choose.value.person = id; choose.value.person = id;
jdm_arr.value.forEach((item, index) => { jdm_arr.value.forEach((item, index) => {
map.removeOverlay(jdm_arr.value[index]); map.removeOverlay(jdm_arr.value[index]);
@ -1574,8 +1592,16 @@ const changeRs = (id) => {
map.removeOverlay(jdm_number_arr.value[index]); map.removeOverlay(jdm_number_arr.value[index]);
}); });
addJd2(); addJd2();
// }
}; };
const changeRs2 = (id) => { const changeRs2 = (id) => {
// if (choose.value.person == id) {
// choose.value.person = "";
// jdm_number_arr.value.forEach((item, index) => {
// map.removeOverlay(jdm_number_arr.value[index]);
// });
// addJd();
// } else {
choose.value.person = id; choose.value.person = id;
jdm_arr.value.forEach((item, index) => { jdm_arr.value.forEach((item, index) => {
map.removeOverlay(jdm_arr.value[index]); map.removeOverlay(jdm_arr.value[index]);
@ -1584,6 +1610,7 @@ const changeRs2 = (id) => {
map.removeOverlay(jdm_number_arr.value[index]); map.removeOverlay(jdm_number_arr.value[index]);
}); });
addJd2(); addJd2();
// }
}; };
//---------------------- //----------------------
// //
@ -1669,7 +1696,7 @@ const to_jd = (item_name) => {
getDatas(cfJd.value, ""); getDatas(cfJd.value, "");
} }
if ( if (
choose.value.person == "残疾人" || choose.value.person == "残疾人" ||
choose.value.person == "低边" || choose.value.person == "低边" ||
choose.value.person == "低保" || choose.value.person == "低保" ||
choose.value.person == "高血压" || choose.value.person == "高血压" ||
@ -1718,7 +1745,7 @@ const open_detail = () => {
} else if (choose.value.person == "6666") { } else if (choose.value.person == "6666") {
age = ""; age = "";
} else if ( } else if (
choose.value.person == "残疾人" || choose.value.person == "残疾人" ||
choose.value.person == "低边" || choose.value.person == "低边" ||
choose.value.person == "低保" || choose.value.person == "低保" ||
choose.value.person == "高血压" || choose.value.person == "高血压" ||
@ -1769,7 +1796,7 @@ const handlePagination = (current) => {
} else if (choose.value.person == "6666") { } else if (choose.value.person == "6666") {
age = ""; age = "";
} else if ( } else if (
choose.value.person == "残疾人" || choose.value.person == "残疾人" ||
choose.value.person == "低边" || choose.value.person == "低边" ||
choose.value.person == "低保" || choose.value.person == "低保" ||
choose.value.person == "高血压" || choose.value.person == "高血压" ||
@ -2231,15 +2258,15 @@ const addPolygonCounty = () => {
getDatas(cfJd.value, ""); getDatas(cfJd.value, "");
} }
if ( if (
choose.value.person == "残疾人" || choose.value.person == "残疾人" ||
choose.value.person == "低边" || choose.value.person == "低边" ||
choose.value.person == "低保" || choose.value.person == "低保" ||
choose.value.person == "高血压" || choose.value.person == "高血压" ||
choose.value.person == "糖尿病" || choose.value.person == "糖尿病" ||
choose.value.person == "退役军人" || choose.value.person == "退役军人" ||
choose.value.person == "困境儿童" || choose.value.person == "困境儿童" ||
choose.value.person == "孤儿" || choose.value.person == "孤儿" ||
choose.value.person == "特困" choose.value.person == "特困"
) { ) {
getDataBqs2(cfJd.value, cfCs.value, choose.value.person, false); getDataBqs2(cfJd.value, cfCs.value, choose.value.person, false);
getDatas(cfJd.value, "", false); getDatas(cfJd.value, "", false);
@ -2393,7 +2420,7 @@ const createCustomOverlayJd2 = (polygon, indexx) => {
if (choose.value.person == "6666") { if (choose.value.person == "6666") {
num = "swrs"; num = "swrs";
} else if ( } else if (
choose.value.person == "残疾人" || choose.value.person == "残疾人" ||
choose.value.person == "低边" || choose.value.person == "低边" ||
choose.value.person == "低保" || choose.value.person == "低保" ||
choose.value.person == "高血压" || choose.value.person == "高血压" ||
@ -2507,15 +2534,15 @@ const addPolygonCountyCs = () => {
}); });
getDataBq(cfJd.value, cfCs.value); getDataBq(cfJd.value, cfCs.value);
if ( if (
choose.value.person == "残疾人" || choose.value.person == "残疾人" ||
choose.value.person == "低边" || choose.value.person == "低边" ||
choose.value.person == "低保" || choose.value.person == "低保" ||
choose.value.person == "高血压" || choose.value.person == "高血压" ||
choose.value.person == "糖尿病" || choose.value.person == "糖尿病" ||
choose.value.person == "退役军人" || choose.value.person == "退役军人" ||
choose.value.person == "困境儿童" || choose.value.person == "困境儿童" ||
choose.value.person == "孤儿" || choose.value.person == "孤儿" ||
choose.value.person == "特困" choose.value.person == "特困"
) { ) {
getDataBqs3(cfJd.value, cfCs.value, choose.value.person); getDataBqs3(cfJd.value, cfCs.value, choose.value.person);
} else { } else {
@ -2616,21 +2643,21 @@ const addCsUnChoose = () => {
unChooseList.value.push(itemm); unChooseList.value.push(itemm);
} }
}); });
getDataBq(cfJd.value, cfCs.value); getDataBq(cfJd.value, cfCs.value);
getDatas2(cfJd.value, choose.value.person, cfCs.value); getDatas2(cfJd.value, choose.value.person, cfCs.value);
if ( if (
choose.value.person == "残疾人" || choose.value.person == "残疾人" ||
choose.value.person == "低边" || choose.value.person == "低边" ||
choose.value.person == "低保" || choose.value.person == "低保" ||
choose.value.person == "高血压" || choose.value.person == "高血压" ||
choose.value.person == "糖尿病" || choose.value.person == "糖尿病" ||
choose.value.person == "退役军人" || choose.value.person == "退役军人" ||
choose.value.person == "困境儿童" || choose.value.person == "困境儿童" ||
choose.value.person == "孤儿" || choose.value.person == "孤儿" ||
choose.value.person == "特困" choose.value.person == "特困"
) { ) {
getDataBqs3(cfJd.value, cfCs.value, choose.value.person); getDataBqs3(cfJd.value, cfCs.value, choose.value.person);
} }
@ -2758,7 +2785,7 @@ const createCs2 = (polygon, indexx) => {
if (choose.value.person == "6666") { if (choose.value.person == "6666") {
num = "swrs"; num = "swrs";
} else if ( } else if (
choose.value.person == "残疾人" || choose.value.person == "残疾人" ||
choose.value.person == "低边" || choose.value.person == "低边" ||
choose.value.person == "低保" || choose.value.person == "低保" ||
choose.value.person == "高血压" || choose.value.person == "高血压" ||
@ -2786,18 +2813,7 @@ const createCs2 = (polygon, indexx) => {
map.addOverlay(cs_number_name_arr.value[indexx]); map.addOverlay(cs_number_name_arr.value[indexx]);
cs_number_name_arr.value[indexx].addEventListener("click", () => { cs_number_name_arr.value[indexx].addEventListener("click", () => {
cfCsZs.value = polygon.name; cfCsZs.value = polygon.name;
// if (
// choose.value.person == "cjr" ||
// choose.value.person == "dibian" ||
// choose.value.person == "db" ||
// choose.value.person == "gxy" ||
// choose.value.person == "tnb" ||
// choose.value.person == "tyjr" ||
// choose.value.person == "kjer"
// ) {
// } else {
open_detail(); open_detail();
// }
}); });
}; };
// //
@ -2906,7 +2922,7 @@ const DGcreateCs2 = (polygon, indexx) => {
if (choose.value.person == "6666") { if (choose.value.person == "6666") {
num = "swrs"; num = "swrs";
} else if ( } else if (
choose.value.person == "残疾人" || choose.value.person == "残疾人" ||
choose.value.person == "低边" || choose.value.person == "低边" ||
choose.value.person == "低保" || choose.value.person == "低保" ||
choose.value.person == "高血压" || choose.value.person == "高血压" ||
@ -2935,18 +2951,7 @@ const DGcreateCs2 = (polygon, indexx) => {
cs_dd_arr.value[indexx].addEventListener("click", () => { cs_dd_arr.value[indexx].addEventListener("click", () => {
console.log(cfJd.value, polygon.name); console.log(cfJd.value, polygon.name);
cfCsZs.value = polygon.name; cfCsZs.value = polygon.name;
// if (
// choose.value.person == "cjr" ||
// choose.value.person == "dibian" ||
// choose.value.person == "db" ||
// choose.value.person == "gxy" ||
// choose.value.person == "tnb" ||
// choose.value.person == "tyjr" ||
// choose.value.person == "kjer"
// ) {
// } else {
open_detail(); open_detail();
// }
}); });
}; };
// //