sonata-project/SonataCoreBundle — pull request #77 by Claros (2014-06-28 14:03:16+00:00)
Title: Fix datetime picker format

Hello !

I noticed that when datetime picker has preset value, this value isn't formatted with the 'date_format' option. This problem break the widget and the widget no longer work.

That's why I made a very quick fix. It's a quick fix because there are some things that I don't understand.
The first thing is the "phpMomentMapping". The comment says that it defines a mapping between PHP date format to moment.js format. However, the key doesn't looks like the format used by PHP date().
The second thing is that I didn't know when the value should be formatted. So I did it in finishView().

To conclude, if someone has a better fix than mine... Thanks !