Merge pull request 'remove email from registration flow' (#3) from uwaa/amputoma-fe:pr-noemail into develop

Reviewed-on: https://git.rape.pet/ulith/amputoma-fe/pulls/3
This commit is contained in:
ulith 2025-01-21 00:21:52 +01:00
commit 1d99b00bb9
2 changed files with 1 additions and 47 deletions

View file

@ -8,13 +8,11 @@ const registration = {
setup () { return { v$: useVuelidate() } },
data: () => ({
user: {
email: '',
fullname: '',
username: '',
password: '',
confirm: '',
reason: '',
language: ''
},
captcha: {}
}),
@ -24,7 +22,6 @@ const registration = {
validations () {
return {
user: {
email: { required: requiredIf(() => this.accountActivationRequired) },
username: { required },
fullname: { required },
password: { required },
@ -32,8 +29,7 @@ const registration = {
required,
sameAs: sameAs(this.user.password)
},
reason: { required: requiredIf(() => this.accountApprovalRequired) },
language: {}
reason: { required: requiredIf(() => this.accountApprovalRequired) }
}
}
},
@ -71,9 +67,6 @@ const registration = {
this.user.captcha_solution = this.captcha.solution
this.user.captcha_token = this.captcha.token
this.user.captcha_answer_data = this.captcha.answer_data
if (this.user.language) {
this.user.language = localeService.internalToBackendLocale(this.user.language)
}
this.v$.$touch()

View file

@ -64,33 +64,6 @@
</ul>
</div>
<div
class="form-group"
:class="{ 'form-group--error': v$.user.email.$error }"
>
<label
class="form--label"
for="email"
>{{ $t('registration.email') }}</label>
<input
id="email"
v-model="v$.user.email.$model"
:disabled="isPending"
class="form-control"
type="email"
>
</div>
<div
v-if="v$.user.email.$dirty"
class="form-error"
>
<ul>
<li v-if="!v$.user.email.required">
<span>{{ $t('registration.validations.email_required') }}</span>
</li>
</ul>
</div>
<div class="form-group">
<label
class="form--label"
@ -162,18 +135,6 @@
</ul>
</div>
<div
class="form-group"
:class="{ 'form-group--error': v$.user.language.$error }"
>
<interface-language-switcher
for="email-language"
:prompt-text="$t('registration.email_language')"
:language="v$.user.language.$model"
:set-language="val => v$.user.language.$model = val"
/>
</div>
<div
v-if="accountApprovalRequired"
class="form-group"