Merge branch 'main' of git.zdool.com:xs/ggfwjsc
This commit is contained in:
commit
63fa0ebd49
|
@ -106,7 +106,7 @@
|
|||
v-for="option in data.options"
|
||||
:key="option.value"
|
||||
:class="jz === option.value ? 'choose_1' : 'choose_2'"
|
||||
@click="jzChange(option.value)"
|
||||
@click="jzChange(option.value,option.label)"
|
||||
class="choose_0"
|
||||
>
|
||||
{{ option.label }}
|
||||
|
@ -115,6 +115,7 @@
|
|||
<ePie4
|
||||
:list="data.list.data"
|
||||
:year="data.list.year"
|
||||
:name="data.jzfxName"
|
||||
v-if="showEchart"
|
||||
></ePie4>
|
||||
</div>
|
||||
|
@ -344,8 +345,9 @@ const jypxList = reactive([
|
|||
]);
|
||||
// 救助分析tap切换
|
||||
const jz = ref("1");
|
||||
const jzChange = (value) => {
|
||||
const jzChange = (value,label) => {
|
||||
jz.value = value;
|
||||
data.jzfxName=label;
|
||||
data.list = data.dataAnalysis[value - 1];
|
||||
};
|
||||
const showEchart = ref(false);
|
||||
|
@ -356,6 +358,7 @@ const data = reactive({
|
|||
},
|
||||
list1: {},
|
||||
list2: {},
|
||||
jzfxName:'特困',
|
||||
options: [
|
||||
{ value: "1", label: "特困" },
|
||||
{ value: "2", label: "低保" },
|
||||
|
|
|
@ -3,7 +3,14 @@
|
|||
</template>
|
||||
|
||||
<script setup>
|
||||
import { onMounted, reactive, ref, onBeforeMount, defineProps,watch } from "vue";
|
||||
import {
|
||||
onMounted,
|
||||
reactive,
|
||||
ref,
|
||||
onBeforeMount,
|
||||
defineProps,
|
||||
watch,
|
||||
} from "vue";
|
||||
// 局部引入echarts核心模块
|
||||
import * as echarts from "echarts";
|
||||
|
||||
|
@ -16,9 +23,14 @@ const props = defineProps({
|
|||
type: Array,
|
||||
default: () => [],
|
||||
},
|
||||
name: {
|
||||
type: String,
|
||||
default: () => "",
|
||||
},
|
||||
});
|
||||
const chart = ref(); // 创建DOM引用
|
||||
const data = reactive({
|
||||
name:'特困',
|
||||
list: [6280, 6280, 6280, 5924, 1824],
|
||||
year: [2020, 2021, 2022, 2023, 2024],
|
||||
bg: [0, 0, 0, 0, 0],
|
||||
|
@ -94,7 +106,7 @@ const getOption = () => {
|
|||
},
|
||||
series: [
|
||||
{
|
||||
name: "手工零星报销人数",
|
||||
name: data.name,
|
||||
type: "line",
|
||||
stack: "Total",
|
||||
symbol: "emptyCircle",
|
||||
|
@ -114,32 +126,6 @@ const getOption = () => {
|
|||
borderWidth: 1,
|
||||
color: "#00FCFF",
|
||||
},
|
||||
// areaStyle: {
|
||||
// color: "#F4F65B",
|
||||
// normal: {
|
||||
// //线性渐变,前4个参数分别是x0,y0,x2,y2(范围0~1);相当于图形包围盒中的百分比。如果最后一个参数是‘true’,则该四个值是绝对像素位置。
|
||||
// color: new echarts.graphic.LinearGradient(
|
||||
// 0,
|
||||
// 0,
|
||||
// 0,
|
||||
// 1,
|
||||
// [
|
||||
// {
|
||||
// offset: 0,
|
||||
// // color: 'RGBA(184, 204, 241, 1)'
|
||||
// color: "rgba(0, 252, 255, 0.50)",
|
||||
// },
|
||||
// {
|
||||
// offset: 1,
|
||||
// color: "rgba(0, 252, 255, 0)",
|
||||
// },
|
||||
// ],
|
||||
// false
|
||||
// ),
|
||||
// shadowBlur: 0, //shadowBlur设图形阴影的模糊大小。配合shadowColor,shadowOffsetX/Y, 设置图形的阴影效果。
|
||||
// },
|
||||
// },
|
||||
|
||||
data: data.list,
|
||||
},
|
||||
{
|
||||
|
@ -165,8 +151,7 @@ watch(
|
|||
() => props.list,
|
||||
(newVal, oldVal) => {
|
||||
data.list = newVal;
|
||||
// data.year = props.year;
|
||||
console.log(data.list,data.year,newVal,'数据分析');
|
||||
data.name = props.name;
|
||||
getOption();
|
||||
setChart();
|
||||
}
|
||||
|
@ -175,6 +160,7 @@ watch(
|
|||
() => props.year,
|
||||
(newVal, oldVal) => {
|
||||
data.year = newVal;
|
||||
data.name = props.name;
|
||||
getOption();
|
||||
setChart();
|
||||
}
|
||||
|
@ -184,7 +170,7 @@ onBeforeMount(() => {
|
|||
setTimeout(() => {
|
||||
data.list = props.list;
|
||||
data.year = props.year;
|
||||
// console.log(data.list,data.year,'数据分析');
|
||||
data.name = props.name;
|
||||
getOption();
|
||||
setChart();
|
||||
}, 600);
|
||||
|
|
Loading…
Reference in New Issue