This commit is contained in:
sjl
2024-12-17 13:57:45 +08:00
parent fe8bc407d3
commit 645fb83bce
2 changed files with 5 additions and 4 deletions

View File

@@ -4,6 +4,7 @@
</template>
<script lang="ts" setup>
import * as echarts from "echarts";
import { ref } from "vue";
const chartsRef = ref();
const props = defineProps({
//饼图数据
@@ -75,7 +76,7 @@ const init = () => {
type: "pie",
radius: customData.value.isRing ? ["55", "75"] : "80%",
data: props.chartsData,
formatter: function (name) {
formatter: function (name: any) {
const item = props.chartsData.filter(item=>item.name==name)
console.log(item)
if(item)