diff --git a/api/js/etemplate/Et2Date/Et2Date.ts b/api/js/etemplate/Et2Date/Et2Date.ts index 05a76eb1d4..3e1e3cbb6c 100644 --- a/api/js/etemplate/Et2Date/Et2Date.ts +++ b/api/js/etemplate/Et2Date/Et2Date.ts @@ -395,6 +395,21 @@ export class Et2Date extends Et2InputWidget(FormControlMixin(ValidateMixin(LitFl return value; } + /** + * Change handler setting modelValue for validation + * + * @param _ev + * @returns + */ + _onChange(_ev : Event) : boolean + { + const ret = super._onChange(_ev); + + this.modelValue = this.getValue(); + + return ret; + } + /** * Set the minimum allowed date * @param {string | Date} min @@ -445,4 +460,4 @@ export class Et2Date extends Et2InputWidget(FormControlMixin(ValidateMixin(LitFl } // @ts-ignore TypeScript is not recognizing that Et2Date is a LitElement -customElements.define("et2-date", Et2Date); +customElements.define("et2-date", Et2Date); \ No newline at end of file