Fixed date format issue in geofencing

This commit is contained in:
charitha 2018-10-30 20:47:31 +05:30
parent 1bd160f551
commit 10672ea534
2 changed files with 2 additions and 2 deletions

View File

@ -554,5 +554,5 @@ function formatDate(date) {
hours = hours ? hours : 12; // the hour '0' should be '12'
minutes = minutes < 10 ? '0'+minutes : minutes;
var strTime = hours + ':' + minutes + ' ' + ampm;
return date.getDate() + "/" + date.getMonth()+1 + "/" + date.getFullYear() + " " + strTime;
return date.getDate() + "/" + (date.getMonth() + 1) + "/" + date.getFullYear() + " " + strTime;
}

View File

@ -419,7 +419,7 @@ function formatDate(date) {
hours = hours ? hours : 12; // the hour '0' should be '12'
minutes = minutes < 10 ? '0' + minutes : minutes;
var strTime = hours + ':' + minutes + ' ' + ampm;
return date.getDate() + "/" + date.getMonth() + 1 + "/" + date.getFullYear() + " " + strTime;
return date.getDate() + "/" + (date.getMonth() + 1) + "/" + date.getFullYear() + " " + strTime;
}
function timeSince(date) {