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

This commit is contained in:
姚宇浩 2024-05-24 15:40:57 +08:00
commit 2cac940e4f
3 changed files with 178 additions and 146 deletions

View File

@ -71,27 +71,27 @@ function getCookie(cname) {
// return '' // return ''
} }
// router.beforeEach((to, form, next) => { router.beforeEach((to, form, next) => {
// var token = getCookie('lytoken') var token = getCookie('lytoken')
// console.log('token', token) console.log('token', token)
// if (token == '') { if (token == '') {
// window.location.href = window.location.href =
// 'http://220.191.238.50:996/api/login?returnURL=' + 'http://220.191.238.50:996/api/login?returnURL=' +
// window.location.href window.location.href
// } else { } else {
// // http.get("/api/zzdn_event/auditToken?token=" + token).then((res) => { // http.get("/api/zzdn_event/auditToken?token=" + token).then((res) => {
// // if (res.code == '500') { // if (res.code == '500') {
// // window.location.href = // window.location.href =
// // 'http://220.191.238.50:996/api/login?returnURL=' + // 'http://220.191.238.50:996/api/login?returnURL=' +
// // window.location.href // window.location.href
// // } else { // } else {
// // tools.data.set('token',token) // tools.data.set('token',token)
// // next(); // next();
// // } // }
// // }); // });
// tools.data.set('token', token) tools.data.set('token', token)
// next(); next();
// } }
// }) })
export default router export default router

View File

@ -1,5 +1,5 @@
<template> <template>
<div ref="chart" style="width: 100%; height:100%;"></div> <div ref="chart" style="width: 100%; height: 100%"></div>
</template> </template>
<script setup> <script setup>
@ -10,140 +10,172 @@ import * as echarts from "echarts";
const chart = ref(); // DOM const chart = ref(); // DOM
const datas = { const datas = {
value: 92.96, value: 92.96,
} };
let option = { let option = {
series: [ series: [
// //
{ {
type: "pie", type: "pie",
center: ["55%", "55%"], center: ["55%", "55%"],
radius: ["70%", "90%"], radius: ["70%", "90%"],
hoverAnimation: false, hoverAnimation: false,
clockWise: false, clockWise: false,
itemStyle: { // startAngle: 180,
normal: { // endAngle: 360,
borderWidth: 1, itemStyle: {
borderColor: "rgba(193, 229, 255, .1)", normal: {
color: new echarts.graphic.LinearGradient(1, 1, 1, 0, [ borderWidth: 1,
{ borderColor: "rgba(193, 229, 255, .1)",
offset: 1, color: new echarts.graphic.LinearGradient(1, 1, 1, 0, [
color: "rgba(127, 242, 255, .2)", {
}, offset: 1,
{ color: "rgba(127, 242, 255, .2)",
offset: 0,
color: "rgba(109, 195, 255, 0)",
},
]),
},
}, },
tooltip: { {
show: false, offset: 0,
color: "rgba(109, 195, 255, 0)",
}, },
label: { ]),
show: false,
},
data: [100],
}, },
/*内心原型图,展示整体数据概览*/ },
tooltip: {
show: false,
},
label: {
show: false,
},
data: [100],
},
/*内心原型图,展示整体数据概览*/
{
// name: "pie",
type: "pie",
roundCap: true,
clockWise: true,
radius: ["50%", "70%"],
center: ["55%", "55%"],
startAngle: 180,
labelLine: {
show: false,
},
hoverAnimation: false,
data: [
{ {
name: 'pie', value: datas.value,
type: 'pie', label: {
roundCap: true, normal: {
clockWise: true, position: "center",
startAngle: 180, show: true,
labelLine: { textStyle: {
show: false fontSize: "24",
fontWeight: "normal",
color: "#fff",
fontSize: 16,
lineHeight: 30,
rich: {
cell: {
fontSize: "24",
fontWeight: "normal",
color: "#fff",
},
text: {
fontSize: 16,
fontFamily: "FZLanTingHeiS-L-GB",
color: "#fff",
},
},
},
}, },
radius: ['50%', '70%'], },
hoverAnimation: false, itemStyle: {
center: ['55%', '55%'], normal: {
data: [ color: new echarts.graphic.LinearGradient(0, 1, 1, 0, [
{ {
value: datas.value, offset: 0,
label: { color: "rgba(0, 255, 250, 0.29)",
normal: {
position: 'center',
show: true,
textStyle: {
fontSize: '24',
fontWeight: 'normal',
color: '#fff',
fontSize: 16,
lineHeight: 30,
rich: {
cell: {
fontSize: '24',
fontWeight: 'normal',
color: '#fff',
},
text: {
fontSize: 16,
fontFamily: 'FZLanTingHeiS-L-GB',
color: '#fff',
}
}
}
}
},
itemStyle: {
normal: {
color: new echarts.graphic.LinearGradient(0, 1, 1, 0, [{
offset: 0,
color: 'rgba(0, 255, 250, 0.29)'
},
{
offset: 0.5,
color: 'rgba(0, 255, 250, 0.8)'
}, {
offset: 1,
color: 'rgba(0, 255, 250, 1)'
}]),
shadowColor: 'rgba(1,1,1,0.5)',
shadowBlur: 1
}
}
}, },
{ {
value: 100 - datas.value, offset: 0.5,
name: '', color: "rgba(0, 255, 250, 0.8)",
itemStyle: { },
normal: { {
color: '#095b9b', // offset: 1,
label: { color: "rgba(0, 255, 250, 1)",
show: false },
}, ]),
labelLine: { shadowColor: "rgba(1,1,1,0.5)",
show: false shadowBlur: 1,
} },
}, },
emphasis: { },
color: '#095b9b' // {
} value: 100 - datas.value,
} name: "",
}] itemStyle: {
} normal: {
] color: "#095b9b", //
label: {
show: false,
},
labelLine: {
show: false,
},
},
emphasis: {
color: "#095b9b", //
},
},
},
],
},
],
}; };
// let option = {
// tooltip: {
// trigger: 'item'
// },
// legend: {
// top: '5%',
// left: 'center'
// },
// series: [
// {
// name: 'Access From',
// type: 'pie',
// radius: ['40%', '70%'],
// center: ['50%', '70%'],
// // adjust the start and end angle
// startAngle: 180,
// endAngle: 360,
// data: [
// { value: 1048, name: 'Search Engine' },
// { value: 735, name: 'Direct' },
// { value: 580, name: 'Email' },
// { value: 484, name: 'Union Ads' },
// { value: 300, name: 'Video Ads' }
// ]
// }
// ]
// };
// 使 // 使
onMounted(() => { onMounted(() => {
// domecharts // domecharts
// var myChart = echarts.init(document.getElementById('main')); // var myChart = echarts.init(document.getElementById('main'));
// Vue3 // Vue3
var myChart = echarts.init(chart.value); var myChart = echarts.init(chart.value);
// init(); // vue3.2this // init(); // vue3.2this
// 使 // 使
myChart.setOption(option); myChart.setOption(option);
// : // :
// window.addEventListener("resize", () => { // window.addEventListener("resize", () => {
// myChart.resize(); // myChart.resize();
// }); // });
}); });
</script> </script>
<style scoped></style> <style scoped></style>

View File

@ -375,11 +375,11 @@ const getData = async () => {
background-size: 100% 100%; background-size: 100% 100%;
} }
.left_2 { // .left_2 {
background-image: url(@/assets/images/hygiene/left_title_2.png); // background-image: url(@/assets/images/hygiene/left_title_2.png);
background-repeat: no-repeat; // background-repeat: no-repeat;
background-size: 100% 100%; // background-size: 100% 100%;
} // }
.left_3 { .left_3 {
background-image: url(@/assets/images/hygiene/new_lmb.png); background-image: url(@/assets/images/hygiene/new_lmb.png);