Topic: Bug in binding the DatePicker value (WriteValue)
Rotmandev
priority
asked 4 days ago
We are binding a value to the datepicker through a form control in TypeScript, it was working on the previous version, but in the new version, it is not
Check the mdb-angular-ui-kit-datepicker.mjs , the WriteValue method is missing the line to write the value as in the timepicker "this.value = value;"

Arkadiusz Idzikowski
staff
answered 2 days ago
Datepicker writeValue is still updated in the datepicker, it is just handled a bit differently than in timepicker component.
We are already aware of some problems with the datepicker value updates in the latest MDB Angular version. It seems that there are some edge cases where this value is updated too early, which causes the input value not to be updated correctly. As a workaround please try to move the code to ngAfterViewInit hook or use Promise.resolve() to delay the update:
Promise.resolve().then(() => {
// update value here
});
FREE CONSULTATION
Hire our experts to build a dedicated project. We'll analyze your business requirements, for free.
Answered
- ForumUser: Priority
- Premium support: Yes
- Technology: MDB Angular
- MDB Version: MDB5 10.0.0
- Device: All
- Browser: All
- OS: All
- Provided sample code: No
- Provided link: No