This commit is contained in:
@@ -50,7 +50,8 @@ todo: custom fields currency type control NOT implement yet, are there others to
|
|||||||
todo: custom fields date only and time only are not setting but combined date/time is setting
|
todo: custom fields date only and time only are not setting but combined date/time is setting
|
||||||
- It's possible I made a change in datetime that I need to also make in standalone separate ones to update properly
|
- It's possible I made a change in datetime that I need to also make in standalone separate ones to update properly
|
||||||
- Maybe in event emitted?
|
- Maybe in event emitted?
|
||||||
|
|
||||||
|
todo: are *all* custom field types working? Not certain
|
||||||
|
|
||||||
todo: apparently I can change the buttons to display the text not uppercase with class="text-none" or something
|
todo: apparently I can change the buttons to display the text not uppercase with class="text-none" or something
|
||||||
- https://github.com/vuetifyjs/vuetify/issues/3948
|
- https://github.com/vuetifyjs/vuetify/issues/3948
|
||||||
|
|||||||
@@ -207,7 +207,7 @@ export default {
|
|||||||
//Only process if value is non-null since all control types can handle null
|
//Only process if value is non-null since all control types can handle null
|
||||||
if (ret != null) {
|
if (ret != null) {
|
||||||
//check types that matter
|
//check types that matter
|
||||||
/*
|
/*thes are all types, not necessarily all custom field types
|
||||||
NoType = 0,
|
NoType = 0,
|
||||||
DateTime = 1,
|
DateTime = 1,
|
||||||
Date = 2,
|
Date = 2,
|
||||||
@@ -229,7 +229,6 @@ export default {
|
|||||||
case 2:
|
case 2:
|
||||||
case 3:
|
case 3:
|
||||||
//can it be parsed into a date using the same library as the components use?
|
//can it be parsed into a date using the same library as the components use?
|
||||||
//window.$gz.DateTime.fromISO(valueStart);
|
|
||||||
if (!window.$gz.DateTime.fromISO(ret).isValid) {
|
if (!window.$gz.DateTime.fromISO(ret).isValid) {
|
||||||
ret = null;
|
ret = null;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -68,9 +68,7 @@ export default {
|
|||||||
date() {
|
date() {
|
||||||
//this tortuous fuckery is required so that the input and change events only fire on a real change, not initial page load
|
//this tortuous fuckery is required so that the input and change events only fire on a real change, not initial page load
|
||||||
//also it shouldn't signal a change if the values are the same and nothing was effectively changed
|
//also it shouldn't signal a change if the values are the same and nothing was effectively changed
|
||||||
|
|
||||||
var hasChanged = false;
|
var hasChanged = false;
|
||||||
|
|
||||||
if (this.date != this.oldDate) {
|
if (this.date != this.oldDate) {
|
||||||
hasChanged = true;
|
hasChanged = true;
|
||||||
}
|
}
|
||||||
@@ -117,8 +115,13 @@ export default {
|
|||||||
);
|
);
|
||||||
},
|
},
|
||||||
set(value) {
|
set(value) {
|
||||||
|
//2017-08-15T12:10:34.4443084+03:00
|
||||||
|
var TimePortion = this.timeOnly;
|
||||||
|
if (!TimePortion) {
|
||||||
|
TimePortion = "00:00:00";
|
||||||
|
}
|
||||||
this.date = window.$gz.locale.localTimeDateStringToUTC8601String(
|
this.date = window.$gz.locale.localTimeDateStringToUTC8601String(
|
||||||
value + "T" + this.timeOnly,
|
value + "T" + TimePortion,
|
||||||
this.timeZoneName
|
this.timeZoneName
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
@@ -133,8 +136,24 @@ export default {
|
|||||||
);
|
);
|
||||||
},
|
},
|
||||||
set(value) {
|
set(value) {
|
||||||
|
var DatePortion = this.dateOnly;
|
||||||
|
if (!DatePortion) {
|
||||||
|
var v = new Date();
|
||||||
|
var fullYear = v.getFullYear();
|
||||||
|
var fullMonth = v.getMonth() + 1;
|
||||||
|
if (fullMonth < 10) {
|
||||||
|
fullMonth = "0" + fullMonth.toString();
|
||||||
|
}
|
||||||
|
var fullDay = v.getDate();
|
||||||
|
if (fullDay < 10) {
|
||||||
|
fullDay = "0" + fullDay.toString();
|
||||||
|
}
|
||||||
|
|
||||||
|
DatePortion = fullYear + "-" + fullMonth + "-" + fullDay;
|
||||||
|
}
|
||||||
|
|
||||||
this.date = window.$gz.locale.localTimeDateStringToUTC8601String(
|
this.date = window.$gz.locale.localTimeDateStringToUTC8601String(
|
||||||
this.dateOnly + "T" + value,
|
DatePortion + "T" + value,
|
||||||
this.timeZoneName
|
this.timeZoneName
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -74,7 +74,7 @@ export default {
|
|||||||
//this tortuous fuckery is required so that the input and change events only fire on a real change, not initial page load
|
//this tortuous fuckery is required so that the input and change events only fire on a real change, not initial page load
|
||||||
//also it shouldn't signal a change if the values are the same and nothing was effectively changed
|
//also it shouldn't signal a change if the values are the same and nothing was effectively changed
|
||||||
var hasChanged = false;
|
var hasChanged = false;
|
||||||
if (this.oldDate != null && this.date != this.oldDate) {
|
if (this.date != this.oldDate) {
|
||||||
hasChanged = true;
|
hasChanged = true;
|
||||||
}
|
}
|
||||||
this.oldDate = this.date;
|
this.oldDate = this.date;
|
||||||
@@ -113,8 +113,13 @@ export default {
|
|||||||
);
|
);
|
||||||
},
|
},
|
||||||
set(value) {
|
set(value) {
|
||||||
|
//2017-08-15T12:10:34.4443084+03:00
|
||||||
|
var TimePortion = this.timeOnly;
|
||||||
|
if (!TimePortion) {
|
||||||
|
TimePortion = "00:00:00";
|
||||||
|
}
|
||||||
this.date = window.$gz.locale.localTimeDateStringToUTC8601String(
|
this.date = window.$gz.locale.localTimeDateStringToUTC8601String(
|
||||||
value + "T" + this.timeOnly,
|
value + "T" + TimePortion,
|
||||||
this.timeZoneName
|
this.timeZoneName
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
@@ -129,8 +134,24 @@ export default {
|
|||||||
);
|
);
|
||||||
},
|
},
|
||||||
set(value) {
|
set(value) {
|
||||||
|
var DatePortion = this.dateOnly;
|
||||||
|
if (!DatePortion) {
|
||||||
|
var v = new Date();
|
||||||
|
var fullYear = v.getFullYear();
|
||||||
|
var fullMonth = v.getMonth() + 1;
|
||||||
|
if (fullMonth < 10) {
|
||||||
|
fullMonth = "0" + fullMonth.toString();
|
||||||
|
}
|
||||||
|
var fullDay = v.getDate();
|
||||||
|
if (fullDay < 10) {
|
||||||
|
fullDay = "0" + fullDay.toString();
|
||||||
|
}
|
||||||
|
|
||||||
|
DatePortion = fullYear + "-" + fullMonth + "-" + fullDay;
|
||||||
|
}
|
||||||
|
|
||||||
this.date = window.$gz.locale.localTimeDateStringToUTC8601String(
|
this.date = window.$gz.locale.localTimeDateStringToUTC8601String(
|
||||||
this.dateOnly + "T" + value,
|
DatePortion + "T" + value,
|
||||||
this.timeZoneName
|
this.timeZoneName
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user