in src/js/components/DateTimeFormatPicker.react.js [52:76]
inferFormat() {
let format = '';
let m = {};
if (this.expectedDateTime() != null) {
m = phpFormatMoment.parseZone(this.expectedDateTime());
// TODO: WE DISABLE THE INFERING FOR NOW UNTIL WE FIND A WAY TO
// CONVERT ISO TO PHP
// if (m.isValid()) {
// format = m.creationData().format;
// }
}
format =
this.props.property.format != ''
? this.props.property.format
: DEFAULT_FORMAT;
this.setState({
moment: m,
displayedDateTime:
m && this.props.property.format
? m.formatPHP(this.props.property.format)
: null,
});
this.formatChanged(format);
}