I have the following javascript code:
var date = record.get('Date'),
day = date.getDate(),
month = date.getMonth(),
year = date.getFullYear();
var formattedDate = year + '-' + month + '-' + day;
datePicker.selectedDates = {
formattedDate: formattedDate
};
The result of selectedDates right now is: formattedDate: '2014-7-27'
And I need the result to be
'2014-7-27' : '2014-7-27'
Any clue?