On my insert page, I utilize the date field and it submits the date properly. When I display the data on a page, I can format it and it appears in the standard MM/dd/yyyy format.
The issue is on the update page. When using the date form field, nothing is displayed. As indicated in the above post, I changed the field from date to text and the date is displayed in the format saved in the database, 2018-10-17 21:09:30.
While I can understand this format and update it as needed, my end users will not be able to.
I have looked and clicked on everything I can think of, but I can not see how to format the date on an update field to a MM/dd/yyyy format.
Why not use the date picker component in your form, instead of the regular html5 date field?
You can then format the date on the front end as needed, while the date will be inserted in the standard MySQL date format.
Ok, I see what my issue is now. I need to not only use the text field with the date picker component in wappler, but also use a char field in the database, not a datetime field as mentioned in Date picker query
I have set up an update page and have been able to set up the date range picker to insert the dates into the database, but I am having trouble with displaying the start and end dates on the update page after the start and end dates have been inserted.
I tried using the Dynamic Attributes with the start date and nothing showed on the page.
I tried using the custom dates option and nothing showed on the page.
I tried using the Dynamic Attributes with the min and max dates and nothing showed on the page.
What would be the way to show the start and end date fields on an update page that has a field using the date range picker?
In my first example, I tried serverconnect1.data.queryprelimid[0].pc_preliminary_date_start alone as the value and that did not work.
I then tried serverconnect1.data.queryprelimid[0].pc_preliminary_date_start + ‘-’ + serverconnect1.data.queryprelimid[0].pc_preliminary_date_end and that did not work.
I then tried serverconnect1.data.queryprelimid[0].pc_preliminary_date_start + serverconnect1.data.queryprelimid[0].pc_preliminary_date_end and that did not work.
If this expression is returning a date from your database, then this is what you need to select in your date picker.
Please provide a link where I can check what's wrong.
Did you install “moments”? That’s where I got stuck. <input type="date" class="form-control" id="inp_startdate" name="startdate" dmx-bind:value="updatefill.data.query1[0].startdate" aria-describedby="inp_startdate_help" placeholder="Enter Startdate">