This commit is contained in:
@@ -45,9 +45,11 @@ export default {
|
||||
oldDate: null,
|
||||
dlgdate: false,
|
||||
//cache display format stuff
|
||||
timeZoneName: window.$gz.locale.getBrowserTimeZoneName(),
|
||||
languageName: window.$gz.locale.getBrowserLanguages(),
|
||||
defaultLocale: window.$gz.locale.getBrowserFirstLanguage().split("-", 1)[0]
|
||||
timeZoneName: window.$gz.translation.getBrowserTimeZoneName(),
|
||||
languageName: window.$gz.translation.getBrowserLanguages(),
|
||||
defaultLocale: window.$gz.translation
|
||||
.getBrowserFirstLanguage()
|
||||
.split("-", 1)[0]
|
||||
}),
|
||||
props: {
|
||||
label: String,
|
||||
@@ -61,7 +63,7 @@ export default {
|
||||
},
|
||||
methods: {
|
||||
lt(ltKey) {
|
||||
return window.$gz.locale.get(ltKey);
|
||||
return window.$gz.translation.get(ltKey);
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
@@ -84,7 +86,7 @@ export default {
|
||||
},
|
||||
computed: {
|
||||
formatDateTime() {
|
||||
return window.$gz.locale.utcDateToShortDateAndTimeLocalized(
|
||||
return window.$gz.translation.utcDateToShortDateAndTimeLocalized(
|
||||
this.value,
|
||||
this.timeZoneName,
|
||||
this.languageName,
|
||||
@@ -92,14 +94,14 @@ export default {
|
||||
);
|
||||
},
|
||||
formatDate() {
|
||||
return window.$gz.locale.utcDateToShortDateLocalized(
|
||||
return window.$gz.translation.utcDateToShortDateLocalized(
|
||||
this.value,
|
||||
this.timeZoneName,
|
||||
this.languageName
|
||||
);
|
||||
},
|
||||
formatTime() {
|
||||
return window.$gz.locale.utcDateToShortTimeLocalized(
|
||||
return window.$gz.translation.utcDateToShortTimeLocalized(
|
||||
this.value,
|
||||
this.timeZoneName,
|
||||
this.languageName,
|
||||
@@ -109,7 +111,7 @@ export default {
|
||||
dateOnly: {
|
||||
get() {
|
||||
//return date only portion converted to local working time zone: YYYY-MM-DD
|
||||
return window.$gz.locale.utcDateStringToLocal8601DateOnlyString(
|
||||
return window.$gz.translation.utcDateStringToLocal8601DateOnlyString(
|
||||
this.value,
|
||||
this.timeZoneName
|
||||
);
|
||||
@@ -120,7 +122,7 @@ export default {
|
||||
if (!TimePortion) {
|
||||
TimePortion = "00:00:00";
|
||||
}
|
||||
this.date = window.$gz.locale.localTimeDateStringToUTC8601String(
|
||||
this.date = window.$gz.translation.localTimeDateStringToUTC8601String(
|
||||
value + "T" + TimePortion,
|
||||
this.timeZoneName
|
||||
);
|
||||
@@ -130,7 +132,7 @@ export default {
|
||||
//expects just the hours minutes seconds portion: 18:18:49
|
||||
//Needs to convert into and out of the desired time zone or the control will show the UTC time instead
|
||||
get() {
|
||||
return window.$gz.locale.utcDateStringToLocal8601TimeOnlyString(
|
||||
return window.$gz.translation.utcDateStringToLocal8601TimeOnlyString(
|
||||
this.value,
|
||||
this.timeZoneName
|
||||
);
|
||||
@@ -152,7 +154,7 @@ export default {
|
||||
DatePortion = fullYear + "-" + fullMonth + "-" + fullDay;
|
||||
}
|
||||
|
||||
this.date = window.$gz.locale.localTimeDateStringToUTC8601String(
|
||||
this.date = window.$gz.translation.localTimeDateStringToUTC8601String(
|
||||
DatePortion + "T" + value,
|
||||
this.timeZoneName
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user