File tree Expand file tree Collapse file tree
frontend/pages/dashboard/[[id]] Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -11,7 +11,6 @@ import type { HashTabs } from '~/types/hashTabs'
1111
1212const {
1313 isLoggedIn,
14- premium_perks,
1514} = useUserStore ()
1615const showInDevelopment = Boolean (useRuntimeConfig ().public .showInDevelopment )
1716const { t : $t } = useTranslation ()
@@ -89,24 +88,10 @@ const {
8988
9089const {
9190 getProducts,
92- premiumProducts,
9391} = useProductsStore ()
9492
9593await useAsyncData (' get_products' , () => getProducts ())
9694
97- const hasReachedLimit = computed (() => {
98- const latestEffectiveBalance = overview .value ?.balances .effective_latest
99- const freeProduct = premiumProducts .value [' Free' ]
100- const effectiveBalanceLimitFreeProduct = freeProduct ?.premium_perks .effective_balance_per_dashboard
101- const effectiveBalancePerDashboard = premium_perks .value ?.effective_balance_per_dashboard
102- || effectiveBalanceLimitFreeProduct
103-
104- if (! latestEffectiveBalance || ! effectiveBalancePerDashboard ) {
105- return false
106- }
107- return isGreaterEquals (latestEffectiveBalance , effectiveBalancePerDashboard )
108- })
109-
11095await useAsyncData (' user_dashboards' , () => refreshDashboards (), { watch: [ isLoggedIn ] })
11196
11297const { error : validatorOverviewError } = await useAsyncData (
@@ -220,7 +205,7 @@ watch(
220205 <BcPageWrapper >
221206 <template #banner >
222207 <BcNotificationBanner
223- v-if =" hasReachedLimit "
208+ v-if =" overview?.is_above_effective_balance_limit "
224209 :title =" $t('dashboard.subsciprion_limit_reached_title')"
225210 >
226211 <BcTranslation
You can’t perform that action at this time.
0 commit comments