Bottone Registrati: manca getlang che non funziona....

This commit is contained in:
paolo
2018-11-12 18:08:06 +01:00
parent 0e383f3493
commit f5b73414b1
16 changed files with 87 additions and 59 deletions

View File

@@ -4,7 +4,7 @@
<div class="text-center">
<p>
<!--<img src="../../../assets/quasar-logo-full.svg">-->
<img :src="`../../../assets/`+`${env('LOGO_REG')}`">
<img src="../../../assets/{{ logoimg }}">
</p>
</div>

View File

@@ -1,7 +1,7 @@
import { ISignupOptions } from '@/model'
import { required, minLength, email, sameAs } from 'vuelidate/lib/validators'
import { ValidationRuleset } from 'vuelidate'
import { complexity, registered } from '@/validation'
import { complexity, registereduser, registeredemail } from '@/validation'
export type TSignup = { signup: ISignupOptions, validationGroup: string[] }
@@ -17,11 +17,12 @@ export const validations = {
},
username: {
required,
registered
registereduser
},
email: {
required,
email
email,
registeredemail
},
terms: {
required

View File

@@ -10,7 +10,6 @@ import { validations, TSignup } from './signup-validate'
import { validationMixin } from 'vuelidate'
import './signup.scss'
import { complexity, registered } from '@/validation'
// import {Loading, QSpinnerFacebook, QSpinnerGears} from 'quasar'
@@ -46,6 +45,10 @@ export default class Signup extends Vue {
}
}
public logoimg() {
return process.env.LOGO_REG
}
get allowSubmit() {
let error = this.$v.$error || this.$v.$invalid
@@ -88,7 +91,7 @@ export default class Signup extends Vue {
}
}, */
env() {
public env() {
return process.env
}
@@ -117,6 +120,7 @@ export default class Signup extends Vue {
}
if (!item.required) return this.$t('reg.err.required')
if (!item.complexity) return this.$t('reg.err.complexity')
if (!item.minLength) return this.$t('reg.err.atleast') + ` ${item.$params.minLength.min} ` + this.$t('reg.err.char')
if (!item.maxLength) return this.$t('reg.err.notmore') + ` ${item.$params.maxLength.max} ` + this.$t('reg.err.char')
return ''
@@ -139,7 +143,7 @@ export default class Signup extends Vue {
}
submit() {
public submitOk() {
this.$v.signup.$touch()
this.duplicate_email = false
@@ -167,8 +171,6 @@ export default class Signup extends Vue {
this.$q.loading.hide()
})
// ...
}
}

View File

@@ -3,7 +3,7 @@
<div class="text-center">
<p>
<!--<img src="../../../assets/quasar-logo-full.svg">-->
<img :src="`../../../assets/`+`${env('LOGO_REG')}`">
<img :src="`../../../assets/${logoimg()}`">
</p>
</div>
@@ -76,13 +76,15 @@
:label="$t('reg.terms')"></q-checkbox>
</q-field>
<br>
<q-btn rounded size="lg" color="primary" @click="submitOk" :disabled='!allowSubmit'>{{$t('reg.submit')}}
</q-btn>
<!--
<div align="center">
<q-btn rounded size="lg" color="primary" @click="submit" :disable="">{{$t('reg.submit')}}
<div align="center">
<q-btn rounded size="lg" color="primary" @click="submitOk" :disable="">{{$t('reg.submit')}}
</q-btn>
</div>