Jump to 0.3.1

This commit is contained in:
Wu Cheng-Han 2015-07-02 00:10:20 +08:00
parent f7f8c901f4
commit 10c9811fc5
49 changed files with 2336 additions and 448 deletions

View file

@ -319,8 +319,9 @@ function parseToHistory(list, notehistory, callback) {
else if (notehistory && notehistory.length > 0) {
for (var i = 0; i < notehistory.length; i++) {
//parse time to timestamp and fromNow
notehistory[i].timestamp = moment(notehistory[i].time, 'MMMM Do YYYY, h:mm:ss a').unix();
notehistory[i].timestamp = moment(notehistory[i].time, 'MMMM Do YYYY, h:mm:ss a').valueOf();
notehistory[i].fromNow = moment(notehistory[i].time, 'MMMM Do YYYY, h:mm:ss a').fromNow();
notehistory[i].time = moment(notehistory[i].time, 'MMMM Do YYYY, h:mm:ss a').format('llll');
if (list.get('id', notehistory[i].id).length == 0)
list.add(notehistory[i]);
}