re-factor / cleanup

This commit is contained in:
2022-01-11 22:08:38 +00:00
parent e871708b20
commit e0be8a7cfe
251 changed files with 14680 additions and 15693 deletions

View File

@@ -4,9 +4,9 @@
<v-row v-if="formState.ready">
<v-col cols="12">
<v-text-field
name="username"
id="username"
v-model="obj.loginName"
name="username"
:readonly="true"
prepend-icon="$ayiUser"
:label="$ay.t('UserLogin')"
@@ -15,6 +15,7 @@
</v-col>
<v-col cols="12">
<v-text-field
ref="newPassword"
v-model="obj.newPassword"
:readonly="formState.readOnly"
:append-outer-icon="reveal ? '$ayiEye' : '$ayiEyeSlash'"
@@ -23,7 +24,6 @@
:type="reveal ? 'text' : 'password'"
:rules="[form().required(this, 'newPassword')]"
:error-messages="form().serverErrors(this, 'newPassword')"
ref="newPassword"
@input="fieldValueChanged('newPassword')"
@click:append-outer="reveal = !reveal"
></v-text-field>
@@ -31,6 +31,7 @@
<v-col cols="12">
<v-text-field
ref="confirmPassword"
v-model="obj.confirmPassword"
:readonly="formState.readOnly"
:append-outer-icon="reveal ? '$ayiEye' : '$ayiEyeSlash'"
@@ -42,7 +43,6 @@
form().confirmMatch(this, 'newPassword', 'confirmPassword')
]"
:error-messages="form().serverErrors(this, 'confirmPassword')"
ref="confirmPassword"
@input="fieldValueChanged('confirmPassword')"
@click:append-outer="reveal = !reveal"
></v-text-field>
@@ -52,8 +52,8 @@
:disabled="!canSave"
color="primary"
value="SUBMIT"
@click="submit()"
data-cy="submit"
@click="submit()"
>{{ $ay.t("Save") }}</v-btn
>
</v-col>
@@ -63,15 +63,6 @@
<script>
export default {
async created() {
const searchParams = new URLSearchParams(window.location.search);
//home-reset?rc={ResetCode}&tr={EffectiveTranslationId}&lg={loginName}
this.obj.passwordResetCode = searchParams.get("rc");
this.obj.loginName = searchParams.get("lg");
this.obj.translationId = parseInt(searchParams.get("tr"));
await initForm(this);
this.formState.ready = true;
},
data() {
return {
obj: {
@@ -100,6 +91,15 @@ export default {
return this.formState.valid && this.formState.dirty;
}
},
async created() {
const searchParams = new URLSearchParams(window.location.search);
//home-reset?rc={ResetCode}&tr={EffectiveTranslationId}&lg={loginName}
this.obj.passwordResetCode = searchParams.get("rc");
this.obj.loginName = searchParams.get("lg");
this.obj.translationId = parseInt(searchParams.get("tr"));
await initForm(this);
this.formState.ready = true;
},
methods: {
translation() {
return window.$gz.translation;