This commit is contained in:
@@ -8,6 +8,10 @@ WIFI change 5g channel to 52,56,60 and 2g channel to 8
|
|||||||
|
|
||||||
todo: datetime should support keyboard entry if typing
|
todo: datetime should support keyboard entry if typing
|
||||||
|
|
||||||
|
todo: server error not displaying properly for broken rules?
|
||||||
|
widget start date invalid format or missing I guess was the issue but no feedback
|
||||||
|
{"error":{"code":"2200","details":[{"target":"StartDate","error":"2201"}],"message":"Object did not pass validation"}}
|
||||||
|
|
||||||
todo: if dbid in url query parameter of contact form on server it should include that in the message
|
todo: if dbid in url query parameter of contact form on server it should include that in the message
|
||||||
also something needs to be fixed there, it's been in notes forever
|
also something needs to be fixed there, it's been in notes forever
|
||||||
|
|
||||||
|
|||||||
@@ -1,33 +1,38 @@
|
|||||||
<template>
|
<template>
|
||||||
<div>
|
<div>
|
||||||
<!-- <div>
|
<v-row>
|
||||||
Value:{{ value }}, dateValue: {{ dateValue }}, timeValue: {{ timeValue }}
|
{{ internalValue }}
|
||||||
</div> -->
|
<v-col cols="6">
|
||||||
<v-text-field
|
<v-text-field
|
||||||
ref="dateField"
|
ref="dateField"
|
||||||
:value="dateControlFormat()"
|
:value="dateControlFormat()"
|
||||||
@input="handleDateInput"
|
@input="handleDateInput"
|
||||||
:readonly="readonly"
|
:readonly="readonly"
|
||||||
:disabled="disabled"
|
:disabled="disabled"
|
||||||
:label="label"
|
:label="label"
|
||||||
:rules="rules"
|
:rules="rules"
|
||||||
type="date"
|
type="date"
|
||||||
></v-text-field>
|
></v-text-field>
|
||||||
|
</v-col>
|
||||||
<v-text-field
|
<v-col cols="6">
|
||||||
ref="timeField"
|
<v-text-field
|
||||||
:value="timeControlFormat()"
|
ref="timeField"
|
||||||
@input="handleTimeInput"
|
:value="timeControlFormat()"
|
||||||
:readonly="readonly"
|
@input="handleTimeInput"
|
||||||
:disabled="disabled"
|
:readonly="readonly"
|
||||||
:label="label"
|
:disabled="disabled"
|
||||||
:rules="rules"
|
type="time"
|
||||||
type="time"
|
></v-text-field>
|
||||||
></v-text-field>
|
</v-col>
|
||||||
|
<v-col cols="12">
|
||||||
<p v-show="error" class="form__error v-messages theme--light error--text">
|
<p
|
||||||
{{ error }}
|
v-show="error"
|
||||||
</p>
|
class="form__error v-messages theme--light error--text"
|
||||||
|
>
|
||||||
|
{{ error }}
|
||||||
|
</p>
|
||||||
|
</v-col>
|
||||||
|
</v-row>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
@@ -81,68 +86,45 @@ export default {
|
|||||||
);
|
);
|
||||||
},
|
},
|
||||||
handleDateInput(value) {
|
handleDateInput(value) {
|
||||||
console.log("handle date input called with ", value);
|
//combine the time and dates into a consolidated value
|
||||||
// //combine the time and dates into a consolidated value
|
let TimePortion = window.$gz.locale.utcDateStringToLocal8601TimeOnlyString(
|
||||||
// let TimePortion = this.timeValue;
|
this.internalValue,
|
||||||
// if (!TimePortion) {
|
this.timeZoneName
|
||||||
// TimePortion = "00:00:00";
|
);
|
||||||
// }
|
let newValue = window.$gz.locale.localTimeDateStringToUTC8601String(
|
||||||
|
value + "T" + TimePortion,
|
||||||
|
this.timeZoneName
|
||||||
|
);
|
||||||
|
|
||||||
// let DatePortion = this.dateValue;
|
this.$emit("input", newValue);
|
||||||
// if (!DatePortion) {
|
|
||||||
// let v = new Date();
|
|
||||||
// let fullYear = v.getFullYear();
|
|
||||||
// let fullMonth = v.getMonth() + 1;
|
|
||||||
// if (fullMonth < 10) {
|
|
||||||
// fullMonth = "0" + fullMonth.toString();
|
|
||||||
// }
|
|
||||||
// let fullDay = v.getDate();
|
|
||||||
// if (fullDay < 10) {
|
|
||||||
// fullDay = "0" + fullDay.toString();
|
|
||||||
// }
|
|
||||||
|
|
||||||
// DatePortion = fullYear + "-" + fullMonth + "-" + fullDay;
|
|
||||||
// }
|
|
||||||
|
|
||||||
// let fullValue = window.$gz.locale.localTimeDateStringToUTC8601String(
|
|
||||||
// DatePortion + "T" + value,
|
|
||||||
// this.timeZoneName
|
|
||||||
// );
|
|
||||||
// console.log("handle input emitting ", fullValue);
|
|
||||||
// this.$emit("input", fullValue);
|
|
||||||
// // this.internalValue = value;
|
|
||||||
// // this.formattedValue = value;
|
|
||||||
},
|
},
|
||||||
handleTimeInput(value) {
|
handleTimeInput(value) {
|
||||||
console.log("handle time input called with ", value);
|
console.log("handle time input called with ", value);
|
||||||
// //combine the time and dates into a consolidated value
|
let DatePortion = window.$gz.locale.utcDateStringToLocal8601DateOnlyString(
|
||||||
// let TimePortion = this.timeValue;
|
this.internalValue,
|
||||||
// if (!TimePortion) {
|
this.timeZoneName
|
||||||
// TimePortion = "00:00:00";
|
);
|
||||||
// }
|
if (!DatePortion) {
|
||||||
|
let v = new Date();
|
||||||
|
let fullYear = v.getFullYear();
|
||||||
|
let fullMonth = v.getMonth() + 1;
|
||||||
|
if (fullMonth < 10) {
|
||||||
|
fullMonth = "0" + fullMonth.toString();
|
||||||
|
}
|
||||||
|
let fullDay = v.getDate();
|
||||||
|
if (fullDay < 10) {
|
||||||
|
fullDay = "0" + fullDay.toString();
|
||||||
|
}
|
||||||
|
|
||||||
// let DatePortion = this.dateValue;
|
DatePortion = fullYear + "-" + fullMonth + "-" + fullDay;
|
||||||
// if (!DatePortion) {
|
}
|
||||||
// let v = new Date();
|
|
||||||
// let fullYear = v.getFullYear();
|
|
||||||
// let fullMonth = v.getMonth() + 1;
|
|
||||||
// if (fullMonth < 10) {
|
|
||||||
// fullMonth = "0" + fullMonth.toString();
|
|
||||||
// }
|
|
||||||
// let fullDay = v.getDate();
|
|
||||||
// if (fullDay < 10) {
|
|
||||||
// fullDay = "0" + fullDay.toString();
|
|
||||||
// }
|
|
||||||
|
|
||||||
// DatePortion = fullYear + "-" + fullMonth + "-" + fullDay;
|
let newValue = window.$gz.locale.localTimeDateStringToUTC8601String(
|
||||||
// }
|
DatePortion + "T" + value,
|
||||||
|
this.timeZoneName
|
||||||
// let fullValue = window.$gz.locale.localTimeDateStringToUTC8601String(
|
);
|
||||||
// DatePortion + "T" + value,
|
//console.log("handle input emitting ", newValue);
|
||||||
// this.timeZoneName
|
this.$emit("input", newValue);
|
||||||
// );
|
|
||||||
// console.log("handle input emitting ", fullValue);
|
|
||||||
// this.$emit("input", fullValue);
|
|
||||||
// // this.internalValue = value;
|
// // this.internalValue = value;
|
||||||
// // this.formattedValue = value;
|
// // this.formattedValue = value;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user