Browse Source

fit:1、地图3色

master
pengwei 3 months ago
parent
commit
dd8ff0271c
  1. 29
      src/views/datav/Jwpy.vue

29
src/views/datav/Jwpy.vue

@ -733,6 +733,7 @@ const option4 = ref({
// region
onMounted(async () => {
console.log('--------------')
await getDistributionFun();
console.log('-----end-------')
@ -833,6 +834,7 @@ async function getData() {
// tableData2.value = group2
// tableData3.value = group3
console.log('综合满意度排名.value', tableData2.value)
GetDITUFun()
});
//
@ -865,29 +867,32 @@ async function getData() {
});
//
getDistributionFun();
}
function GetDITUFun(){
GetDITU(selectYear.value).then((res) => {
tempMap.value = res
let valData = mapOrgNameMapping(tableData2.value,"FinalRP")
let listData = valData.sort((a, b) => Number(b["value"]) - Number(a["value"]));
console.log('valData',valData)
let listData = valData.sort((a, b) => b["value"]- a["value"]);
console.log('listData',listData)
option.value.visualMap.pieces=[
{min: listData[2].value, max: listData[0].value, label: "满意度前三", color: "#4987F6"},
{gte: listData[6].value, lte: listData[3].value, label: "满意度中等", color: "#F6A149"},
{gte: listData[listData.length - 1], label: "满意度较差", color: "#D34343"},
{min: listData[2].value, max: 100, label: "满意度前三", color: "#4987F6"},
{min: listData[6].value, max: listData[3].value, label: "满意度中等", color: "#F6A149"},
{max: listData[4].value, label: "满意度较差", color: "#D34343"},
]
console.log('option.value',option.value)
option.value.series.data =listData
mapDataList.value = tempMap.value.map(org => {
return {name: org.OrganizeName, value: org.OrganizeID};
})
option.value.series.data =listData
console.log('tempMap.value',tempMap.value)
console.log('option.value',option.value)
});
}
getDistributionFun();
}
/**

Loading…
Cancel
Save