diff --git a/src/views/home/index.vue b/src/views/home/index.vue index 44deeed..cc84890 100644 --- a/src/views/home/index.vue +++ b/src/views/home/index.vue @@ -187,7 +187,7 @@
-
+
@@ -200,7 +200,18 @@
-
+
+ +
+
@@ -208,19 +219,7 @@
-
- -
总资金:{{ toThousands(totalMoney) }}
-
@@ -317,7 +316,7 @@ import {getArticle} from "@/api/article"; const AuthStore = useAuthStore() const router = useRouter() const topLeftHeight = ref('') -const researchFundYear = ref('2024') +const researchFundYear = ref(new Date().getFullYear()+'') const activeName = ref('first') const docActiveTab = ref('first') const totalMoney = ref('45000') @@ -620,6 +619,7 @@ const getDoneList = () => { const changeResearchFundDataByYear=(year)=>{ if(year){ getResearchChart(year) + } } const getResearchChart = (year) => { @@ -628,9 +628,12 @@ const getResearchChart = (year) => { totalMoney.value = res.data.totalAmount moneyData.value = res.data.rdCompanyList if(res.data.rdCompanyList?.length ==0)return; + if (moneyPieOption.value.series && moneyPieOption.value.series?.length > 0) { moneyPieOption.value.series[0].data = res.data.rdCompanyList - initMoneyCharts() + nextTick(() => { + initMoneyCharts() + }) } } else { ElNotification({