From 9b8c27edd8942f84da68c36d9292e14e5f93cc14 Mon Sep 17 00:00:00 2001 From: wupengfei <834520024@qq.com> Date: 星期四, 15 五月 2025 14:06:14 +0800 Subject: [PATCH] Merge branch 'dev-3.4.5' of http://120.26.58.240:8888/r/12333GovernmentWeb into dev-3.4.5 --- src/views/Home/Home.vue | 86 +++++++++++++++++++++++++++++++++++------- 1 files changed, 71 insertions(+), 15 deletions(-) diff --git a/src/views/Home/Home.vue b/src/views/Home/Home.vue index c5ab28b..9d2cb7f 100644 --- a/src/views/Home/Home.vue +++ b/src/views/Home/Home.vue @@ -3,35 +3,60 @@ <AppContainer> <ChunkCell title="寰呭鐞�"> <div class="data-board-card-list"> - <DataBoardCard title="寰呭鏍镐紒涓�" :contentBetween="true"> - <DataBoardCardPrice :value="20000" :isInline="true" :useThousand="false" unit="瀹�" /> - <el-button type="primary" link>鍘诲鏍�</el-button> + <DataBoardCard title="寰呭鏍告壒娆�" :contentBetween="true"> + <DataBoardCardPrice + :value="detail?.waitCheckEnterpriseNumber ?? 0" + :isInline="true" + :useThousand="false" + unit="" + /> + <el-button type="primary" link @click="goToAudit">鍘诲鏍�</el-button> </DataBoardCard> <DataBoardCard title="濂栧姳閲戝緟鍙戞斁" :contentBetween="true"> - <DataBoardCardPrice :isInline="true" :value="20000" :useThousand="false" unit="瀹�" /> - <el-button type="primary" link>鍘诲彂鏀�</el-button> + <DataBoardCardPrice + :isInline="true" + :value="detail?.waitForSettleRewardNumber ?? 0" + :useThousand="false" + unit="" + /> + <el-button type="primary" link @click="goToGrant">鍘诲彂鏀�</el-button> </DataBoardCard> </div> </ChunkCell> <ChunkCell title="鏁版嵁鐪嬫澘"> <div class="data-board-card-list"> <DataBoardCard title="绱宸插鏍镐紒涓�"> - <DataBoardCardPrice :value="20000" :useThousand="false" unit="瀹�" /> + <DataBoardCardPrice + :value="detail?.accumulatedCheckEnterpriseNumber ?? 0" + :useThousand="false" + unit="瀹�" + /> </DataBoardCard> <DataBoardCard title="绱宸插鏍搁�氳繃浼佷笟"> - <DataBoardCardPrice :value="20000" :useThousand="false" unit="瀹�" /> + <DataBoardCardPrice + :value="detail?.accumulatedCheckPassEnterpriseNumber ?? 0" + :useThousand="false" + unit="瀹�" + /> </DataBoardCard> <DataBoardCard title="绱鏈鏍搁�氳繃浼佷笟"> - <DataBoardCardPrice :value="20000" :useThousand="false" unit="瀹�" /> + <DataBoardCardPrice + :value="detail?.accumulatedCheckRejectEnterpriseNumber ?? 0" + :useThousand="false" + unit="瀹�" + /> </DataBoardCard> - <DataBoardCard title="绱宸插彂鏀惧鍔遍噾"> - <DataBoardCardPrice :value="20000" unit="鍏�" /> + <DataBoardCard title="绱宸插彂鏀�"> + <DataBoardCardPrice :value="detail?.accumulatedHasSettleRewardAmount ?? 0" unit="鍏�" /> </DataBoardCard> - <DataBoardCard title="绱寰呭彂鏀惧鍔遍噾"> - <DataBoardCardPrice :value="20000" unit="鍏�" /> + <DataBoardCard title="绱寰呭彂鏀�"> + <DataBoardCardPrice + :value="detail?.accumulatedWaitForSettleRewardAmount ?? 0" + unit="鍏�" + /> </DataBoardCard> - <DataBoardCard title="绱宸蹭娇鐢ㄥ鍔遍噾"> - <DataBoardCardPrice :value="20000" unit="鍏�" /> + <DataBoardCard title="绱宸蹭娇鐢�"> + <DataBoardCardPrice :value="detail?.accumulatedUsedRewardAmount ?? 0" unit="鍏�" /> </DataBoardCard> </div> </ChunkCell> @@ -43,12 +68,43 @@ import { AppContainer, ChunkCell } from '@bole-core/components'; import DataBoardCard from '@/components/DataBoardCard/DataBoardCard.vue'; import DataBoardCardPrice from '@/components/DataBoardCard/DataBoardCardPrice.vue'; +import * as parkBountyApplyServices from '@/services/api/ParkBountyApply'; +import { useQuery, useQueryClient } from '@tanstack/vue-query'; defineOptions({ name: 'Home', }); -const isLoading = ref(false); +const router = useRouter(); + +const { data: detail, isLoading } = useQuery({ + queryKey: ['parkBountyApplyServices/getGoverDataBoard'], + queryFn: async () => { + return await parkBountyApplyServices.getGoverDataBoard({ + showLoading: false, + }); + }, + placeholderData: () => ({} as API.GetGoverDataBoardOutput), +}); + +function goToAudit() { + router.push({ + name: 'MaterialReviewList', + }); +} +function goToGrant() { + router.push({ + name: 'RewardGrant', + }); +} + +const queryClient = useQueryClient(); + +onMounted(async () => { + await queryClient.ensureQueryData({ + queryKey: ['parkBountyApplyServices/getGoverDataBoard'], + }); +}); </script> <style lang="scss" scoped> -- Gitblit v1.9.1