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

@@ -7,13 +7,13 @@
<v-dialog v-model="dlgtime" width="300px">
<template v-slot:activator="{ on }">
<v-text-field
v-on="on"
:value="readonlyFormat()"
:label="label"
prepend-icon="$ayiClock"
@click:prepend="dlgtime = true"
readonly
:error="!!hasErrors"
v-on="on"
@click:prepend="dlgtime = true"
></v-text-field>
</template>
<v-time-picker
@@ -42,11 +42,11 @@
<v-text-field
ref="timeField"
:value="timeValue"
@change="updateTimeValue"
:readonly="readonly"
:disabled="disabled"
type="time"
:data-cy="`${dataCy}:time`"
@change="updateTimeValue"
></v-text-field>
</v-col>
</template>
@@ -73,12 +73,6 @@
//NOTE: this control also captures the date even though it's time only
//this is an intentional design decision to support field change to date or date AND time and is considered a display issue
export default {
data: () => ({
dlgtime: false,
timeZoneName: window.$gz.locale.getResolvedTimeZoneName(),
languageName: window.$gz.locale.getResolvedLanguage(),
hour12: window.$gz.locale.getHour12()
}),
props: {
label: { type: String, default: null },
rules: { type: Array, default: undefined },
@@ -88,6 +82,12 @@ export default {
disabled: { type: Boolean, default: false },
dataCy: { type: String, default: null }
},
data: () => ({
dlgtime: false,
timeZoneName: window.$gz.locale.getResolvedTimeZoneName(),
languageName: window.$gz.locale.getResolvedLanguage(),
hour12: window.$gz.locale.getHour12()
}),
computed: {
hasErrors() {
return this.errorMessages != null && this.errorMessages.length > 0;