Skip to content

Commit

Permalink
Merge branch 'hotfix/142'
Browse files Browse the repository at this point in the history
  • Loading branch information
amitsharmaak committed Jul 8, 2015
2 parents 7e714f9 + b6ae28a commit 3dd892e
Show file tree
Hide file tree
Showing 4 changed files with 14 additions and 15 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -172,10 +172,10 @@ define([
}).append($("<img/>", {src: '../images/genie.gif', class: 'genie-icon'}))).html();

var createdDt = new Date(applicationObj.created);
applicationObj.createTimeFormatted = moment(createdDt).format('MM/DD/YYYY HH:mm:ss');
applicationObj.createTimeFormatted = moment(createdDt).utc().format('MM/DD/YYYY HH:mm:ss');

var updatedDt = new Date(applicationObj.updated);
applicationObj.updateTimeFormatted = moment(updatedDt).format('MM/DD/YYYY HH:mm:ss');
applicationObj.updateTimeFormatted = moment(updatedDt).utc().format('MM/DD/YYYY HH:mm:ss');

applicationObj.formattedTags = applicationObj.tags.join("<br />");

Expand Down Expand Up @@ -233,10 +233,10 @@ define([
console.log(applicationObj);

var createdDt = new Date(applicationObj.created);
applicationObj.createTimeFormatted = moment(createdDt).format('MM/DD/YYYY HH:mm:ss');
applicationObj.createTimeFormatted = moment(createdDt).utc().format('MM/DD/YYYY HH:mm:ss');

var updatedDt = new Date(applicationObj.updated);
applicationObj.updateTimeFormatted = moment(updatedDt).format('MM/DD/YYYY HH:mm:ss');
applicationObj.updateTimeFormatted = moment(updatedDt).utc().format('MM/DD/YYYY HH:mm:ss');

applicationObj.formattedTags = applicationObj.tags.join("<br />");

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -173,10 +173,10 @@ define([
}).append($("<img/>", {src: '../images/genie.gif', class: 'genie-icon'}))).html();

var createdDt = new Date(clusterObj.created);
clusterObj.createTimeFormatted = moment(createdDt).format('MM/DD/YYYY HH:mm:ss');
clusterObj.createTimeFormatted = moment(createdDt).utc().format('MM/DD/YYYY HH:mm:ss');

var updatedDt = new Date(clusterObj.updated);
clusterObj.updateTimeFormatted = moment(updatedDt).format('MM/DD/YYYY HH:mm:ss');
clusterObj.updateTimeFormatted = moment(updatedDt).utc().format('MM/DD/YYYY HH:mm:ss');

clusterObj.formattedTags = clusterObj.tags.join("<br />");

Expand Down Expand Up @@ -236,10 +236,10 @@ define([
console.log(clusterObj);

var createdDt = new Date(clusterObj.created);
clusterObj.createTimeFormatted = moment(createdDt).format('MM/DD/YYYY HH:mm:ss');
clusterObj.createTimeFormatted = moment(createdDt).utc().format('MM/DD/YYYY HH:mm:ss');

var updatedDt = new Date(clusterObj.updated);
clusterObj.updateTimeFormatted = moment(updatedDt).format('MM/DD/YYYY HH:mm:ss');
clusterObj.updateTimeFormatted = moment(updatedDt).utc().format('MM/DD/YYYY HH:mm:ss');

clusterObj.formattedTags = ck=clusterObj.tags.join("<br />");

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -186,10 +186,10 @@ define([
}).append($("<img/>", {src: '../images/genie.gif', class: 'genie-icon'}))).html();

var createdDt = new Date(commandObj.created);
commandObj.createTimeFormatted = moment(createdDt).format('MM/DD/YYYY HH:mm:ss');
commandObj.createTimeFormatted = moment(createdDt).utc().format('MM/DD/YYYY HH:mm:ss');

var updatedDt = new Date(commandObj.updated);
commandObj.updateTimeFormatted = moment(updatedDt).format('MM/DD/YYYY HH:mm:ss');
commandObj.updateTimeFormatted = moment(updatedDt).utc().format('MM/DD/YYYY HH:mm:ss');

commandObj.formattedTags = commandObj.tags.join("<br />");

Expand Down Expand Up @@ -247,10 +247,10 @@ define([
//console.log(command);

var createdDt = new Date(commandObj.created);
commandObj.createTimeFormatted = moment(createdDt).format('MM/DD/YYYY HH:mm:ss');
commandObj.createTimeFormatted = moment(createdDt).utc().format('MM/DD/YYYY HH:mm:ss');

var updatedDt = new Date(commandObj.updated);
commandObj.updateTimeFormatted = moment(updatedDt).format('MM/DD/YYYY HH:mm:ss');
commandObj.updateTimeFormatted = moment(updatedDt).utc().format('MM/DD/YYYY HH:mm:ss');

commandObj.formattedTags = commandObj.tags.join("<br />");

Expand Down
5 changes: 2 additions & 3 deletions genie-server/src/main/resources/META-INF/resources/js/job.js
Original file line number Diff line number Diff line change
Expand Up @@ -182,14 +182,13 @@ define([
}).append($("<img/>", {src: '../images/genie.gif', class: 'genie-icon'}))).html();

var startDt = new Date(jobObj.created);
jobObj.startTimeFormatted = moment(startDt).format('MM/DD/YYYY HH:mm:ss');
jobObj.startTimeFormatted = moment(startDt).utc().format('MM/DD/YYYY HH:mm:ss');

var endDt = new Date(jobObj.finished);

// TODO checking against PST Epoch time. This should be changed once we fix the server side.
if (jobObj.status != 'RUNNING') {
jobObj.endTimeFormatted = moment (endDt).format('MM/DD/YYYY HH:mm:ss');
//jobObj.diffTimeFormatted = moment.duration(moment(endDt).diff(moment(startDt))).format("d[d] hh:mm:ss", {trim: false});
jobObj.endTimeFormatted = moment (endDt).utc().format('MM/DD/YYYY HH:mm:ss');
jobObj.diffTimeFormatted = moment.duration(moment(endDt).diff(moment(startDt))).format("d[d] hh[h] mm[m] ss[s]", {trim:false});
} else {
jobObj.endTimeFormatted = '';
Expand Down

0 comments on commit 3dd892e

Please sign in to comment.