Datepicker Input Problem

Hello I am working with a bit of a old system, and we are using webix to create a new interface using all json objects and webservices, now we have a few issues,
we have multiple date and time fields all around the system, and they can all have different formats.
I tried to create a prototype for the datepickers to use them, for date and time handling.
http://webix.com/snippet/bc2d33fe

It works great for selecting new dates to send to the system (output),
but we are having 2 issues with it.

  1. the display of the data from the database (input) Does not work
  2. If you put more than one, it resets the other one

Can any one help me with this?

Hello,

Webix Date helper cannot parse date strings without any delimiting symbols (like “20150225”), so you will have to call custom parsing logic for it.

To correctly set the value you need to parse it firstly, and then call the native setValue() logic of the datepicker.

Finally, modifying getValue causes lots of issue with the control’s inner logic, so it’s better to define and use the method with another name, e.g. getFormattedValue.

Please, check the following snippet: http://webix.com/snippet/3b09dd5b