This commit is contained in:
李想 2025-04-25 17:00:14 +08:00
parent d0f9f11c30
commit 4a38a94d9e
21 changed files with 364 additions and 533 deletions

Binary file not shown.

After

Width:  |  Height:  |  Size: 10 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 853 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 502 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.7 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 448 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 828 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 MiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.9 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

View File

@ -124,80 +124,8 @@ export default {
if (props.option) { if (props.option) {
Object.assign(option, cloneDeep(props.option)); Object.assign(option, cloneDeep(props.option));
} }
option.series = [ option.series[0].data = yDataColumn.value;
{ option.series[1].data = yDataLine.value;
name: '总产量(吨)',
type: 'bar',
data: yDataColumn.value,
barWidth: '15px',
barGap: '50%',
itemStyle: {
normal: {
borderColor: '#3681FF',
// color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
// {
// offset: 0,
// color: 'rgba(15, 51, 82, 1)',
// },
// {
// offset: 1,
// color: 'rgba(0, 168, 255, 1)',
// },
// ]),
},
},
label: {
show: false,
position: 'top',
fontSize: 12,
color: '#F5F5F5',
offset: [0, -5],
formatter: '{c}',
},
},
{
name: '平均产量(吨)',
type: 'line',
yAxisIndex: 1,
showSymbol: true,
symbolSize: 8,
smooth: true,
symbol: 'circle',
lineStyle: {
normal: {
color: '#02D6B0',
},
},
itemStyle: {
color: '#02D6B0',
borderColor: '#fff',
borderWidth: 1,
},
// areaStyle: {
// normal: {
// color: new echarts.graphic.LinearGradient(
// 0,
// 0,
// 0,
// 1,
// [
// {
// offset: 0,
// color: 'rgba(0, 255, 246, 0)',
// },
// {
// offset: 1,
// color: 'rgba(0, 255, 246, 0.5)',
// },
// ],
// false
// ),
// },
// },
data: yDataLine.value, // 线
},
];
option.xAxis.data = xData.value; option.xAxis.data = xData.value;
setOptions(option); setOptions(option);
// startAutoPlay({ // startAutoPlay({

View File

@ -27,7 +27,14 @@ export default {
}, },
option: { option: {
type: Object, type: Object,
default: () => ({}), default: () => ({
k: 1,
opacity: '0,6',
itemGap: 0.2,
itemHeight: 120,
autoItemHeight: 0,
legendSuffix: '',
}),
}, },
type: { type: {
type: String, type: String,
@ -51,18 +58,15 @@ export default {
const chartRef = ref(null); const chartRef = ref(null);
const { setOptions, getInstance, startAutoPlay } = useEcharts(chartRef); const { setOptions, getInstance, startAutoPlay } = useEcharts(chartRef);
const option = ref({}); const option = ref({});
const itemHeight = ref(120);
// let colors = ['#07daf2', '#64de8a', '#ecc23c', '#ffdb5c', '#ff9f7f', '#9fe6b8', '#67e0e3', '#32c5e9', '#fb7293', '#9A60B4', '#ea7ccc'];
watchEffect(() => { watchEffect(() => {
props.chartData && initCharts(); props.chartData && initCharts();
}); });
function initCharts() { function initCharts() {
if (props.option) { if (props.option) {
Object.assign(option, cloneDeep(props.option)); option.value = Object.assign(option, cloneDeep(props.option));
} }
option.value = getPie3D(props.chartData, 0.5); option.value = getPie3D(props.chartData, props.option.opacity);
setOptions(option.value); setOptions(option.value);
} }
@ -75,8 +79,8 @@ export default {
isSelected = false; isSelected = false;
} }
k = typeof k !== 'undefined' ? k : 1 / 3; k = typeof k !== 'undefined' ? k : 1 / 3;
const offsetX = Math.cos(midRadian) * 0.2; const offsetX = Math.cos(midRadian) * props.option.itemGap;
const offsetY = Math.sin(midRadian) * 0.2; const offsetY = Math.sin(midRadian) * props.option.itemGap;
const hoverRate = 1; const hoverRate = 1;
return { return {
u: { u: {
@ -127,7 +131,7 @@ export default {
let startValue = 0; let startValue = 0;
let endValue = 0; let endValue = 0;
const legendData = []; const legendData = [];
const k = 1; const k = props.option.k ?? 1;
for (let i = 0; i < pieData.length; i += 1) { for (let i = 0; i < pieData.length; i += 1) {
sumValue += pieData[i].value; sumValue += pieData[i].value;
@ -142,7 +146,7 @@ export default {
itemStyle: { itemStyle: {
// color: colors[i], // // color: colors[i], //
opacity: '0.6', opacity: props.option.opacity,
borderRadius: 300, borderRadius: 300,
borderColor: '#fff', borderColor: '#fff',
borderWidth: 0, borderWidth: 0,
@ -171,40 +175,41 @@ export default {
false, false,
false, false,
k, k,
itemHeight.value props.option.autoItemHeight > 0 ? props.option.autoItemHeight * series[i].pieData.value : props.option.itemHeight
); );
startValue = endValue; startValue = endValue;
legendData.push(series[i].name); legendData.push(series[i].name);
} }
const option = { const option = Object.assign(
tooltip: { {
position: function (point, params, dom, rect, size) { tooltip: {
var x = point[0]; position: function (point, params, dom, rect, size) {
var y = point[1]; var x = point[0];
var viewWidth = size.viewSize[0]; var y = point[1];
var viewHeight = size.viewSize[1]; var viewWidth = size.viewSize[0];
var boxWidth = size.contentSize[0]; var viewHeight = size.viewSize[1];
var boxHeight = size.contentSize[1]; var boxWidth = size.contentSize[0];
// tooltip 使 var boxHeight = size.contentSize[1];
if (x + boxWidth > viewWidth) { // tooltip 使
x = x - boxWidth; if (x + boxWidth > viewWidth) {
} x = x - boxWidth;
if (y + boxHeight > viewHeight) { }
y = y - boxHeight; if (y + boxHeight > viewHeight) {
} y = y - boxHeight;
// tooltip }
if (x < 0) { // tooltip
x = 0; if (x < 0) {
} x = 0;
if (y < 0) { }
y = 0; if (y < 0) {
} y = 0;
}
return [x, y]; return [x, y];
}, },
formatter: (params) => { formatter: (params) => {
if (params.seriesName !== 'mouseoutSeries') { if (params.seriesName !== 'mouseoutSeries') {
return ` return `
${params.seriesName}<br/> ${params.seriesName}<br/>
<span style="display:inline-block; <span style="display:inline-block;
margin-right:5px; margin-right:5px;
@ -214,63 +219,63 @@ export default {
background-color:${params.color};"></span> background-color:${params.color};"></span>
${option.series[params.seriesIndex].pieData.value} ${option.series[params.seriesIndex].pieData.value}
`; `;
} }
return ''; return '';
},
}, },
}, xAxis3D: {
xAxis3D: { min: -1,
min: -1, max: 1,
max: 1.5,
},
yAxis3D: {
min: -1,
max: 1.5,
},
zAxis3D: {
min: -1,
max: 1.5,
},
itemGap: 20,
grid3D: {
itemGap: 20,
show: false,
boxHeight: 5,
top: '0',
left: '-20%',
viewControl: {
//3d
alpha: 60, //( )
distance: 260, //zoom()
rotateSensitivity: 10, //0
zoomSensitivity: 10, //0
panSensitivity: 10, //0
autoRotate: true, //
autoRotateAfterStill: 2, //, autoRotate
}, },
}, yAxis3D: {
legend: { min: -1,
show: true, max: 1,
right: '5%',
top: '25%',
orient: 'vertical',
icon: 'circle',
itemHeight: 12,
itemWidth: 12,
itemGap: 10,
textStyle: {
color: '#fff',
fontSize: 14,
fontWeight: '400',
}, },
formatter: (name) => { zAxis3D: {
if (props.chartData.length) { min: -1,
const item = props.chartData.filter((item) => item.name === name)[0]; max: 1,
return ` ${name} ${item.value}万亩`;
}
}, },
grid3D: {
show: false,
boxHeight: 5,
top: '0',
left: '-20%',
viewControl: {
//3d
alpha: 60, //( )
distance: 240, //zoom()
rotateSensitivity: 10, //0
zoomSensitivity: 10, //0
panSensitivity: 10, //0
autoRotate: true, //
autoRotateAfterStill: 2, //, autoRotate
},
},
legend: {
show: true,
right: '5%',
top: '25%',
orient: 'vertical',
icon: 'circle',
itemHeight: 12,
itemWidth: 12,
itemGap: 10,
textStyle: {
color: '#fff',
fontSize: 14,
fontWeight: '400',
},
formatter: (name) => {
if (props.chartData.length) {
const item = props.chartData.filter((item) => item.name === name)[0];
return ` ${name} ${item.value}${props.option.legendSuffix ?? ''}`;
}
},
},
series,
}, },
series, props.option
}; );
return option; return option;
} }
function onClick(params) { function onClick(params) {

View File

@ -1,194 +1,67 @@
<template> <template>
<div class="benefit-charts"> <section class="price_container">
<custom-echart-bar :chart-data="chartsData.valData" height="100%" :option="chartsData.option" :is-series="true" /> <section class="_content">
</div> <section class="left_btn"></section>
<section class="_center">
<img :src="tomatoImg" alt="" />
</section>
<section class="right_btn"></section>
</section>
<section class="_footer">0000</section>
</section>
</template> </template>
<script setup> <script setup>
import { ref, reactive, onMounted } from 'vue'; import tomatoImg from '@/assets/images/entities/tomatoImg.png';
import a from '@/assets/images/entities/1.jpg';
const data = [1700, 800, 1700, 600, 800]; import b from '@/assets/images/entities/2.jpg';
const data2 = [2600, 1400, 3350, 1400, 1400]; import c from '@/assets/images/entities/3.jpg';
const colorArr1 = ['rgba(11, 83, 128)', 'rgba(2, 143, 224)', '#2a7fcc']; import d from '@/assets/images/entities/4.jpg';
const colorArr2 = ['rgb(12, 109, 122)', 'rgba(1, 241, 228)', '#5ce1d6']; import e from '@/assets/images/entities/5.jpg';
const color1 = { import f from '@/assets/images/entities/6.jpg';
type: 'linear', import g from '@/assets/images/entities/7.jpg';
x: 0, import h from '@/assets/images/entities/8.png';
x2: 1,
y: 0,
y2: 0,
colorStops: [
{
offset: 0,
color: colorArr1[0],
},
{
offset: 0.5,
color: colorArr1[0],
},
{
offset: 0.5,
color: colorArr1[1],
},
{
offset: 1,
color: colorArr1[1],
},
],
};
const color2 = {
type: 'linear',
x: 0,
x2: 1,
y: 0,
y2: 0,
colorStops: [
{
offset: 0,
color: colorArr2[0],
},
{
offset: 0.5,
color: colorArr2[0],
},
{
offset: 0.5,
color: colorArr2[1],
},
{
offset: 1,
color: colorArr2[1],
},
],
};
var barWidth = 18;
const chartsData = reactive({
option: {
legend: {
show: false,
},
tooltip: {
trigger: 'axis',
formatter: function (params) {
var str = params[0].name + ':';
params.filter(function (item) {
if (item.componentSubType == 'bar') {
str += '<br/>' + item.seriesName + '' + item.value;
}
});
return str;
},
},
//
grid: {
x: '16%',
x2: '5%',
y: '15%',
y2: '15%',
},
xAxis: {
data: ['肉类', '水果', '蔬菜', '水产', '谷物'],
//
axisLine: {
show: true,
lineStyle: {
width: 1,
color: '#214776',
},
textStyle: {
color: '#fff',
fontSize: '10',
},
},
type: 'category',
axisLabel: {
textStyle: {
color: '#C5DFFB',
fontWeight: 500,
fontSize: '14',
},
},
axisTick: {
textStyle: {
color: '#fff',
fontSize: '16',
},
show: false,
},
},
yAxis: {
name: ' ',
nameTextStyle: {
color: '#DEDEDE',
fontSize: 12,
padding: 10,
},
type: 'value',
splitLine: {
show: true,
lineStyle: {
type: 'dashed', //线 线0
opacity: 0.2, //
},
},
axisTick: {
show: false,
},
axisLine: {
show: false,
},
//
axisLabel: {
show: true,
textStyle: {
color: '#C5DFFB',
},
},
},
series: [
{
z: 1,
name: '绿色',
type: 'bar',
barWidth: barWidth,
barGap: '0%',
data: data,
itemStyle: {
normal: {
color: color2,
},
},
},
{
z: 3,
name: '绿色',
type: 'pictorialBar',
symbolPosition: 'end',
data: data,
symbol: 'diamond',
symbolOffset: ['0%', '-60%'],
symbolSize: [18, 12],
itemStyle: {
normal: {
borderWidth: 2,
color: colorArr2[2],
},
},
},
],
},
valData: [
{ value: 205, name: '肉类' },
{ value: 308, name: '水果' },
{ value: 359, name: '蔬菜' },
{ value: 452, name: '水产' },
{ value: 388, name: '谷物' },
],
});
onMounted(() => {});
</script> </script>
<style lang="scss" scoped> <style lang="scss" scoped>
.benefit-charts { .price_container {
display: flex;
flex-direction: column;
align-items: center;
width: 100%;
height: 100%; height: 100%;
._content {
flex: 1;
display: grid;
grid-template-columns: 25% calc(50% - 28px) 25%;
align-items: center;
justify-content: center;
gap: 14px;
width: 100%;
._center {
padding-top: 20px;
height: 100%;
text-align: center;
img {
width: 60%;
height: 60%;
}
background: url('../../../assets/images/entities/goodsBG.png') no-repeat center center / 100%;
background-position: bottom center;
}
.left_btn,
.right_btn {
aspect-ratio: 1 / 1;
background: url('../../../assets/images/entities/leftArrowBG.png') no-repeat center center / 100%;
}
.right_btn {
background: url('../../../assets/images/entities/rightArrowBG.png') no-repeat center center / 100%;
}
}
._footer {
height: 40px;
width: 60%;
background: url('../../../assets/images/basic/footerBtnTextBG.png') no-repeat center center / cover;
}
} }
</style> </style>

View File

@ -1,70 +1,63 @@
<template> <template>
<div class="category-charts"> <customEchartHyalineCake :chart-data="data" height="100%" :option="option" />
<custom-echart-pie :chart-data="plantBreed.valData" height="100%" :option="plantBreed.option" />
</div>
</template> </template>
<script setup>
import { ref, reactive, onMounted } from 'vue';
const plantBreed = reactive({ <script lang="ts" setup>
option: { import { reactive, ref } from 'vue';
color: ['#3685fe', '#41b879', '#ffd500'],
title: { /* --------------- data --------------- */
text: ' ', // #region
textStyle: { const data = ref([
color: '#333', {
}, name: '企业',
}, value: 10.8,
legend: { },
data: ['肉类', '水果', '蔬菜', '水产', '谷物'], {
right: '0', // 10% name: '合作社',
top: 'middle', // value: 8.4,
orient: 'vertical', // },
itemWidth: 15, // {
itemHeight: 8, // name: '村集体',
textStyle: { value: 4.3,
fontSize: 10, // },
color: '#fff', // {
}, name: '个体',
}, value: 3.7,
label: { },
color: '#333', ]);
}, const option = reactive({
series: [ k: 0.2,
{ opacity: 0.6,
type: 'pie', itemGap: 0,
radius: [20, 80], autoItemHeight: 10,
roseType: 'area', legend: {
center: ['40%', '50%'], orient: 'horizontal',
label: { bottom: 10,
show: false, left: 'center',
}, },
itemStyle: { grid3D: {
borderRadius: 5, show: false,
}, boxHeight: 5,
}, top: 'center',
], left: 'center',
viewControl: {
//3d
alpha: 30, //( )
distance: 160, //zoom()
rotateSensitivity: 10, //0
zoomSensitivity: 10, //0
panSensitivity: 10, //0
autoRotate: true, //
autoRotateAfterStill: 2, //, autoRotate
},
}, },
valData: [
{ value: 205, name: '肉类' },
{ value: 308, name: '水果' },
{ value: 359, name: '蔬菜' },
{ value: 452, name: '水产' },
{ value: 388, name: '谷物' },
],
}); });
// #endregion
onMounted(() => { /* --------------- methods --------------- */
if (plantBreed.valData && plantBreed.length) { // #region
plantBreed.valData.forEach((m, index) => {
let num = 100; // #endregion
m.value = (Number(m.value) + Math.random() + num).toFixed(2);
});
}
});
</script> </script>
<style lang="scss" scoped>
.category-charts { <style lang="scss" scoped></style>
height: 100%;
}
</style>

View File

@ -3,6 +3,7 @@
</template> </template>
<script setup> <script setup>
import { reactive } from 'vue'; import { reactive } from 'vue';
import * as echarts from 'echarts';
const state = reactive({ const state = reactive({
data: [ data: [
@ -30,19 +31,18 @@ const state = reactive({
type: 'shadow', type: 'shadow',
}, },
formatter: (data) => { formatter: (data) => {
console.log('data', data);
const params = data[0]; const params = data[0];
let str = `<div class="custom-echarts-tips"> let str = `<div class="custom-echarts-tips">
<span>${params.name}</span><br/> <span>${params.name}</span><br/>
<span>${params.marker} ${params.data} 万亩</span> <span>${params.marker} ${params.data} </span><br />
<span>${data[1].marker} ${data[1].data} </span>
</div>`; </div>`;
return str; return str;
}, },
}, },
barStyle: { barStyle: {
barWidth: 15, barWidth: 15,
itemStyle: {
borderRadius: [8, 8, 0, 0],
},
color: { color: {
type: 'linear', type: 'linear',
x: 0, x: 0,
@ -74,8 +74,7 @@ const state = reactive({
yAxis: [ yAxis: [
{ {
type: 'value', type: 'value',
name: '人数 / 千人', barWidth: 15,
splitNumber: 5,
nameTextStyle: { nameTextStyle: {
color: '#fff', color: '#fff',
fontSize: 12, fontSize: 12,
@ -105,6 +104,7 @@ const state = reactive({
{ {
splitNumber: 5, splitNumber: 5,
type: 'value', type: 'value',
show: false,
nameTextStyle: { nameTextStyle: {
color: '#fff', color: '#fff',
fontSize: 12, fontSize: 12,
@ -127,6 +127,73 @@ const state = reactive({
}, },
}, },
], ],
legend: {
itemWidth: 12,
itemHeight: 8,
itemGap: 20,
right: '2%',
top: '3%',
x: 'center',
textStyle: {
fontSize: 14,
color: '#fff',
},
data: ['总产量(吨)', '平均产量(吨)'],
selectedMode: false,
},
series: [
{
name: '总产量(吨)',
type: 'bar',
data: [],
barWidth: '15px',
barGap: '50%',
itemStyle: {
normal: {
borderRadius: [8, 8, 0, 0],
color: new echarts.graphic.LinearGradient(0, 0, 0, 1, [
{
offset: 0,
color: 'rgba(53,208,192,1)',
},
{
offset: 1,
color: 'rgba(53,208,192,0)',
},
]),
},
},
label: {
show: false,
position: 'top',
fontSize: 12,
color: '#F5F5F5',
offset: [0, -5],
formatter: '{c}',
},
},
{
data: [], // 线
name: '平均产量(吨)',
type: 'line',
yAxisIndex: 1,
showSymbol: true,
symbolSize: 8,
smooth: true,
symbol: 'circle',
lineStyle: {
normal: {
color: 'rgba(53,208,192,1)',
},
},
itemStyle: {
color: 'rgba(254,249,6,1)',
borderColor: '#fff',
borderWidth: 1,
},
},
],
}, },
}); });
</script> </script>

View File

@ -1,119 +1,62 @@
<template> <template>
<div class="demo roll-list-lentities" style="height: 90%"> <customEchartHyalineCake :chart-data="data" height="100%" :option="option" />
<div class="list-item-header item-warp" :style="{ flex: listKeys.length }">
<template v-for="(h, indexh) in listKeys" :key="indexh">
<div class="item-td" :style="{ width: 'calc(100% / ' + listKeys.length + ')' }">{{ listKeysHeader[h] }}</div>
</template>
</div>
<vue3ScrollSeamless class="scroll-wrap" :class-options="classOptions" :data-list="list">
<div v-for="(item, index) in list" :key="index" class="list-item">
<div class="list-item-content">
<div class="list-item-boday item-warp" :style="{ flex: listKeys.length }">
<template v-for="(b, indexb) in listKeys" :key="indexb">
<div class="item-td" :class="{ 'zebra-b': (index + 1) % 2 == 0 }" :style="{ width: 'calc(100% / ' + listKeys.length + ')' }">
{{ item[b] }}
</div>
</template>
</div>
</div>
</div>
</vue3ScrollSeamless>
</div>
<!-- </div> -->
</template> </template>
<script setup> <script lang="ts" setup>
import { ref, onMounted, onUnmounted, computed, reactive } from 'vue'; import { reactive, ref } from 'vue';
import { vue3ScrollSeamless } from 'vue3-scroll-seamless';
const props = defineProps({
// items: {
// type: Array,
// default: () => [],
// },
});
let list = reactive([ /* --------------- data --------------- */
{ title: '信达农资有限公司', type: '农药', time: '2025.01.02', duration: 8 }, // #region
{ title: '方大种源有限公司', type: '种源', time: '2025.01.01', duration: 10 }, const data = ref([
{ title: '信誉种源有限公司', type: '种源', time: '2025.01.02', duration: 11 }, {
{ title: '嘉兴包装有限公司', type: '生产加工', time: '2025.01.01', duration: 15 }, name: '烟草',
{ title: '达国有限公司', type: '农资', time: '2025.01.02', duration: 14 }, value: 60.8,
{ title: '华威种植专业合作社', type: '合作社', time: '2025.01.01', duration: 8 }, },
{ title: '信誉种源合作社', type: '合作社', time: '2025.01.02', duration: 15 }, {
{ title: '华泰种源有限公司', type: '种源', time: '2025.01.01', duration: 13 }, name: '甘蔗',
{ title: '嘉德食品包装包装有限公司', type: '生产加工', time: '2025.01.02', duration: 5 }, value: 44.4,
},
{
name: '核桃',
value: 24.3,
},
{
name: '蔬菜',
value: 32.7,
},
{
name: '其他',
value: 32.9,
},
]); ]);
const option = reactive({
const listKeys = reactive(['title', 'type', 'time', 'duration']); k: 0.3,
const listKeysHeader = reactive({ opacity: 1,
title: '主体名称', itemGap: 0,
type: '主体类别', autoItemHeight: 2,
time: '注册时间', grid3D: {
duration: '经营时间', show: false,
boxHeight: 5,
top: '0',
left: '-20%',
viewControl: {
//3d
alpha: 30, //( )
distance: 160, //zoom()
rotateSensitivity: 10, //0
zoomSensitivity: 10, //0
panSensitivity: 10, //0
autoRotate: true, //
autoRotateAfterStill: 2, //, autoRotate
},
},
}); });
// #endregion
const classOptions = { /* --------------- methods --------------- */
singleHeight: 48, // #region
};
// #endregion
</script> </script>
<style scoped lang="scss"> <style lang="scss" scoped></style>
.roll-list-lentities {
margin-top: 8px;
.scroll-wrap {
height: 80%;
width: 100%;
margin: 4px auto;
overflow: hidden;
}
.list-item-header {
background: #144482;
font-size: 10px;
width: 100%;
.item-td {
padding: 8px 6px;
}
}
.list-item-boday {
background: transparent;
width: 100%;
.item-td {
padding: 4px 6px;
&.td-title {
color: #6beff9 !important;
}
&.zebra-b {
background: #051225 !important;
}
}
}
.item-warp {
display: inline-flex;
justify-content: space-around;
.item-td {
display: inline-block;
vertical-align: middle;
text-align: center;
color: #fff;
}
}
.list-item {
// border-bottom: 1px dashed rgba(255, 255, 255, 0.2);
line-height: 18px;
.list-item-content {
display: inline-flex;
width: 100%;
justify-content: space-around;
position: relative;
}
}
}
.demo {
// display: flex;
// align-items: center;
// justify-content: center;
// margin-top: 10px;
}
</style>

View File

@ -11,7 +11,7 @@
<div class="left-charts-item"> <div class="left-charts-item">
<customBack top-title="全县各作物产值对比" :top-postion="'left'"> <customBack top-title="全县各作物产值对比" :top-postion="'left'">
<template #back> <template #back>
<entitiesStatistics></entitiesStatistics> <entitieslist></entitieslist>
</template> </template>
</customBack> </customBack>
</div> </div>

View File

@ -1,9 +1,9 @@
<template> <template>
<customEchartHyalineCake :chart-data="data" height="100%" /> <customEchartHyalineCake :chart-data="data" height="100%" :option="option" />
</template> </template>
<script lang="ts" setup> <script lang="ts" setup>
import { ref } from 'vue'; import { ref, reactive } from 'vue';
/* --------------- data --------------- */ /* --------------- data --------------- */
// #region // #region
@ -33,6 +33,28 @@ const data = ref([
value: 32.1, value: 32.1,
}, },
]); ]);
const option = reactive({
opacity: 0.6,
itemGap: 0.2,
legendSuffix: '万亩',
itemHeight: 120,
grid3D: {
show: false,
boxHeight: 5,
top: '0',
left: '-20%',
viewControl: {
//3d
alpha: 30, //( )
distance: 260, //zoom()
rotateSensitivity: 10, //0
zoomSensitivity: 10, //0
panSensitivity: 10, //0
autoRotate: true, //
autoRotateAfterStill: 2, //, autoRotate
},
},
});
// #endregion // #endregion
/* --------------- methods --------------- */ /* --------------- methods --------------- */