- favicon fix

- checkout fix
- stripe prefered locales
- color theme
- stripe card info box in dev version
This commit is contained in:
Peter Papp
2021-03-26 16:02:02 +01:00
parent ee1a8a6719
commit a3d4dfec3b
19 changed files with 320 additions and 55 deletions
+22 -17
View File
@@ -19,10 +19,24 @@
</ValidationProvider>
</div>
<div class="block-wrapper">
<label>Plan:</label>
<ValidationProvider tag="div" mode="passive" class="input-wrapper" rules="required" name="Plan" v-slot="{ errors }">
<SelectInput v-model="user.plan"
:default="user.country"
:options="plans"
placeholder="Vyberte plan"
:isError="errors[0]" />
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
</ValidationProvider>
</div>
<FormLabel class="mt-70">{{ $t('user_settings.title_billing') }}</FormLabel>
<!--Name-->
<div class="block-wrapper">
<label>ICO:</label>
<ValidationProvider tag="div" mode="passive" class="input-wrapper" name="ICO" rules="required" v-slot="{ errors }">
<label>ICO (volitelne):</label>
<ValidationProvider tag="div" mode="passive" class="input-wrapper" name="ICO" v-slot="{ errors }">
<input v-model="user.ico" placeholder="Type ICO" type="text" class="focus-border-theme" :class="{'is-error': errors[0]}" />
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
<small v-if="fullDetails" class="input-help">
@@ -111,8 +125,8 @@
</div>
<div class="block-wrapper">
<label>{{ $t('user_settings.phone_number') }}:</label>
<ValidationProvider tag="div" mode="passive" class="input-wrapper" rules="required" name="Phone Number" v-slot="{ errors }">
<label>{{ $t('user_settings.phone_number') }} (volitelne):</label>
<ValidationProvider tag="div" mode="passive" class="input-wrapper" name="Phone Number" v-slot="{ errors }">
<input v-model="user.phone_number"
:placeholder="$t('user_settings.phone_number_plac')"
type="text"
@@ -122,18 +136,6 @@
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
</ValidationProvider>
</div>
<div class="block-wrapper">
<label>Plan:</label>
<ValidationProvider tag="div" mode="passive" class="input-wrapper" rules="required" name="Plan" v-slot="{ errors }">
<SelectInput v-model="user.plan"
:default="user.country"
:options="plans"
placeholder="Vyberte plan"
:isError="errors[0]" />
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
</ValidationProvider>
</div>
</div>
<div class="form-group">
@@ -237,8 +239,11 @@
if (error.response.data.errors['email']) {
this.$refs.createUser.setErrors({
'email': error.response.data.errors['email']
'Email': error.response.data.errors['email']
});
// Scroll top
document.getElementById('single-page').scrollTop = 0
}
} else {
+10 -3
View File
@@ -4,7 +4,7 @@
<MobileHeader :title="$router.currentRoute.meta.title" />
<div class="content-page">
<div class="plan-title">
<credit-card-icon size="42" class="title-icon"></credit-card-icon>
<credit-card-icon size="42" class="title-icon text-theme" />
<h1>{{ $t('page_upgrade_account.title') }}</h1>
<h2>{{ $t('page_upgrade_account.desription') }}</h2>
</div>
@@ -16,7 +16,7 @@
<!-- Pay by new credit card -->
<div class="register-card">
<InfoBox v-if="config.isDemo">
<InfoBox v-if="config.isDemo || config.isDev">
<p>For test your payment please use <b>4242 4242 4242 4242</b> or <b>5555 5555 5555 4444</b> as a card number, <b>11/22</b>
as the expiration date and <b>123</b> as CVC number and ZIP <b>12345</b>.</p>
</InfoBox>
@@ -43,6 +43,7 @@
:placeholder="$t('user_settings.name_plac')"
type="text"
:class="{'is-error': errors[0]}"
class="focus-border-theme"
/>
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
</ValidationProvider>
@@ -57,6 +58,7 @@
:placeholder="$t('user_settings.address_plac')"
type="text"
:class="{'is-error': errors[0]}"
class="focus-border-theme"
/>
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
</ValidationProvider>
@@ -72,6 +74,7 @@
:placeholder="$t('user_settings.city_plac')"
type="text"
:class="{'is-error': errors[0]}"
class="focus-border-theme"
/>
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
</ValidationProvider>
@@ -86,6 +89,7 @@
:placeholder="$t('user_settings.postal_code_plac')"
type="text"
:class="{'is-error': errors[0]}"
class="focus-border-theme"
/>
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
</ValidationProvider>
@@ -115,6 +119,7 @@
:placeholder="$t('user_settings.state_plac')"
type="text"
:class="{'is-error': errors[0]}"
class="focus-border-theme"
/>
<small class="input-help">
State, county, province, or region.
@@ -132,6 +137,7 @@
:placeholder="$t('user_settings.phone_number_plac')"
type="text"
:class="{'is-error': errors[0]}"
class="focus-border-theme"
/>
<span class="error-message" v-if="errors[0]">{{ errors[0] }}</span>
</ValidationProvider>
@@ -385,6 +391,7 @@
axios.get('/api/user/subscription/setup-intent')
.then(response => {
this.clientSecret = response.data.client_secret
this.isLoading = false
})
.catch(() => {
this.$isSomethingWrong()
@@ -601,7 +608,7 @@
margin: 0 auto 80px;
path, line, polyline, rect, circle {
color: $theme;
color: inherit;
}
h1 {
+2 -2
View File
@@ -6,7 +6,7 @@
<!--Page Title-->
<div class="plan-title">
<cloud-icon size="42" class="title-icon"></cloud-icon>
<cloud-icon size="42" class="title-icon text-theme" />
<h1>{{ $t('page_pricing_tables.title') }}</h1>
<h2>{{ $t('page_pricing_tables.description') }}</h2>
</div>
@@ -81,7 +81,7 @@
margin: 0 auto 80px;
path, line, polyline, rect, circle {
color: $theme;
color: inherit;
}
h1 {
@@ -18,7 +18,7 @@
<!-- Pay by new credit card -->
<div class="register-card form block-form">
<InfoBox v-if="config.isDemo">
<InfoBox v-if="config.isDemo || config.isDev">
<p>For test your payment please use <b>4242 4242 4242 4242</b> or <b>5555 5555 5555 4444</b> as a card number, <b>11/22</b>
as the expiration date and <b>123</b> as CVC number and ZIP <b>12345</b>.</p>
</InfoBox>
@@ -33,10 +33,11 @@
</div>
</div>
<InfoBox>
<InfoBox v-if="requestedPlan">
<ListInfo class="billing">
<ListInfoItem class="billing-item" title="Spolecnost" content="CMPortal, s.r.o." />
<ListInfoItem class="billing-item" title="Adresa" content="Korytná 47/3, Praha 10000, Česká Republika" />
<ListInfoItem class="billing-item" title="Spolecnost" :content="requestedPlan.data.relationships.user.data.attributes.name" />
<ListInfoItem v-if="requestedPlan.data.relationships.user.data.attributes.ico" class="billing-item" title="ICO" :content="requestedPlan.data.relationships.user.data.attributes.ico" />
<ListInfoItem class="billing-item" title="Adresa" :content="address" />
</ListInfo>
</InfoBox>
</div>
@@ -152,6 +153,9 @@
return this.requestedPlan.data.relationships.plan.data.attributes.tax_rates.find(taxRate => {
return taxRate.country === this.requestedPlan.data.relationships.user.data.attributes.country
})
},
address() {
return this.requestedPlan.data.relationships.user.data.attributes.address + ', ' + this.requestedPlan.data.relationships.user.data.attributes.postal_code + ', ' + this.requestedPlan.data.relationships.user.data.attributes.city
}
},
data() {