Date picker not workin

Wappler Version : 6.51
Operating System : windows 10 and 11 64bit
Server Model: php
Database Type:phpmyadmin
Hosting Type:shared
I have made no changes

Expected behavior

What do you think should happen?

We have an internal page that uses a modal to insert and update data. Typically when we click on a date to add a new job the modal comes up and dates fill in from the date clicked.

Actual behavior

What actually happens?

…They are appearing then disappearing and cannot be updates. The orhter fields do not fill either

If I click on a job in edit mode, all info fills in but date changes instantly change back.

How to reproduce

click to add, blank
image

edit mode
image
job comes up 4/30 date try change to 5/1 using date picker
image

Sorry but it’s not really clear what is not working from your description. What should we be looking at your screenshots? Maybe post a short video demonstrating the issue.

I click the date picker. Pick a date . It changes back to the date it was.

If you need a video, tell me how to do that

Well just attach a video demonstrating the issue here. Or maybe just provide a link where we can check this issue.

73565365652__824E37D3-D6C9-4AA9-A10D-EA7981368438

Its an internal site

Do you have the date and time component on your page? And if yes - is its interval set to seconds?

Yes and interval is days

Are you using the latest App Connect 2 and are there errors in the console?
Please double check if you don’t have a scheduler running or another date and time component added and set to seconds.

I did a search for dmx-datetime and it’ the only one on the page (set to days)

No errors in the console
image

I changed it to a text field from a date picker and it still updates as fast as I can change the text

Well something is affecting it. Can you provide access to your server where i can check the page in my browser?

trying but can’t

Ok then please zip and send me your page in a personal message.

There’s something wrong with your logic with the date field.

First you have this start date calendar in the modal:

<input id="inp_StartDateu" name="StartDate" type="text" class="form-control form-control-sm" dmx-bind:value="TaskDetail.data.DetailById[0].StartDate" is="dmx-date-picker">

this input gets its value from the TaskDetail server action:

dmx-bind:value="TaskDetail.data.DetailById[0].StartDate"

but then you have the TaskDetail server action actually filtered by the same date input in the modal:

<dmx-serverconnect id="TaskDetail" url="/dmxConnect/api/People/SchedDetail.php" dmx-param:id="TaskUpdateModal.TaskUpdateForm.inp_id.value.default(0)" dmx-param:starttask="TaskUpdateModal.TaskUpdateForm.inp_StartDateu.value" dmx-param:endtask="TaskUpdateModal.TaskUpdateForm.inp_EndDateu.value"></dmx-serverconnect>

it gets the value by the start calendar in your modal:

dmx-param:starttask="TaskUpdateModal.TaskUpdateForm.inp_StartDateu.value"

So what happens is:

  1. You get the initial date from the server action
  2. You change the date and it automatically refreshes the server action
  3. Then as the server action refreshes - the start date is set again, as the data has been reloaded

so you’re in a loop.

You need to rethink this logic.

But I have changed nothing and it has worked for months. How would this have been altered

I can try reloading the page from last week but I didn’t work on this page at all

I’ve reloaded the page from a few days ago and from a few weeks ago with the same result. How did it work then and not now?

I don’t know how is it possible that this worked until now, but i explained what the issue is. You are reloading the source that provides the initial date, so it also reloads with it. This is how dynamic bindings work.
You need to rethink the way you filter your server action or the way you get the data for the input.

I just removed the input parameters from the task detail and checked the No Auto load box. and I’ll test it there. This page has not been altered for many months yet it suddenly changed behaviors yesterday without me doing a thing. (as evidence by the restored files)