Dmx-show and dmx-bind:value not working with dmx-date-picker

Hi all,

Logging this as here as I think we’ve found a bug with the App Connect dmx date picker component.

In the screenshot below, my “Clear date” element should be shown if the initial value of the date picker is set. In the date picker code the initial value is set (even tried by manually entering a date). However, the “clear date” element doesn’t show until the user picks another date, even though the date picker has an initial value set.

When the date picker is created it creates a hidden input field. It looks like the hidden input value isn’t being set on initiating the date picker component which is causing the problem. Once the value is set, the dmx-show works on my “clear date” element.

Hoping someone might be able to help please or if indeed it is a bug for the team to look a fixing it please :slight_smile:

1 Like

I experience the same (seems to be only when the datepicker is in a data-detail region). The actual input displays the date but the hidden input that the date picker uses is empty. I thought it was just me so I haven’t reported it. It doesn’t happen all the time, but most of the time.

Also, if you submit the form with validation on the field it won’t submit as it doesn’t validate. And without validation, even with the value displayed it will enter a null value.

I hope this gets fixed.

Wappler v6.5.0 Stable

I am experiencing the same issue. In my case, this is happening in a SC form in a modal. The dmx-bind:value has been set to datetime var. The date is shown correctly in the input field but the value when submitting the form is empty.

If the date is reselected or a new date is selected from the date picker, the value gets set correctly.

I’m also getting this error in the dev console when resetting the form, which may be relevant to this issue.

1 Like

I’m glad other people are experiencing this. Thought it was just me. Thanks for reporting it. Hopefully it will get some attention.

2 Likes

Hi @patrick just wanted to see if you have any updates on this one please?

1 Like

Wasn’t able to reproduce the error yet, will do some more testing. If you have an online page where it occurs for me to test it would help.

Hi @patrick, I will send a DM shortly with the website details and notes on how to reproduce the error.

I’ve fixed a bug in the datepicker not correctly setting the value on form reset, not sure if it is related to your problem but here is the update.

dmxDatePicker.zip (9.2 KB)

In my case, the datepicker is setting the value. However, it seems to be setting it 1 day behind the date of dmx-bind:value. It loads correctly for the 1st time, but when the same modal is reopened, the date value is 1 day behind.

Awesome @patrick that’s fixed my problem :slight_smile: Hopefully also the same for everyone else here.

This seems to be fixed. At least I haven’t had any issues since the update.

Thanks!