mirror of
https://github.com/VueFileManager/vuefilemanager.git
synced 2026-04-18 08:12:15 +00:00
hide subscription, payment cards and invoices in profile menu when is 'Allow subscription payment' option disabled
frontend build
This commit is contained in:
@@ -2,7 +2,7 @@
|
||||
<PageTab :is-loading="isLoading" class="form-fixed-width">
|
||||
|
||||
<!--Stripe Information-->
|
||||
<PageTabGroup v-if="config.stripe_public_key">
|
||||
<PageTabGroup v-if="config.stripe_public_key && payments">
|
||||
<div class="form block-form">
|
||||
<FormLabel>{{ $t('admin_settings.payments.section_payments') }}</FormLabel>
|
||||
<InfoBox>
|
||||
@@ -143,10 +143,7 @@
|
||||
isLoading: true,
|
||||
isError: false,
|
||||
errorMessage: '',
|
||||
payments: {
|
||||
status: 1,
|
||||
configured: undefined,
|
||||
},
|
||||
payments: undefined,
|
||||
stripeCredentials: {
|
||||
key: '',
|
||||
secret: '',
|
||||
@@ -746,8 +743,10 @@
|
||||
.then(response => {
|
||||
this.isLoading = false
|
||||
|
||||
this.payments.configured = parseInt(response.data.payments_configured)
|
||||
this.payments.status = parseInt(response.data.payments_active)
|
||||
this.payments = {
|
||||
configured: parseInt(response.data.payments_configured),
|
||||
status: parseInt(response.data.payments_active),
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
@@ -172,7 +172,7 @@
|
||||
return this.user.data.attributes.subscription ? 'green' : 'purple'
|
||||
},
|
||||
canShowSubscriptionSettings() {
|
||||
return this.config.isSaaS
|
||||
return this.config.isSaaS && this.config.app_payments_active
|
||||
},
|
||||
canShowUpgradeWarning() {
|
||||
return this.config.storageLimit && this.user.relationships.storage.data.attributes.used > 95
|
||||
|
||||
Reference in New Issue
Block a user