Skip to content
This repository has been archived by the owner on Jan 23, 2020. It is now read-only.

Commit

Permalink
Fixes graph view job selected, mouseover behavior
Browse files Browse the repository at this point in the history
  • Loading branch information
sagemintblue committed Apr 3, 2013
1 parent fa45075 commit c679235
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions common/src/main/resources/web/js/ambrose/view/graph.js
Expand Up @@ -62,7 +62,7 @@ define(['jquery', 'd3', '../core', './core'], function(
self.handleJobsUpdated([job], 350);
});
workflow.on('jobSelected jobMouseOver', function(event, job, prev) {
self.handleJobsUpdated($.grep([prev, job], function(j) { j != null; }));
self.handleJobsUpdated($.grep([prev, job], function(j) { return j != null; }));
});
},

Expand Down Expand Up @@ -164,13 +164,10 @@ define(['jquery', 'd3', '../core', './core'], function(
var colors = this.params.colors;
var fill = function(node) {
var job = node.data;
var status = job.status;
var status = job.status || '';
if (job.mouseover) return colors.mouseover;
if (job.selected) return colors.selected;
if (status == 'RUNNING') return colors.running;
if (status == 'COMPLETE') return colors.complete;
if (status == 'FAILED') return colors.failed;
return '#555';
return colors[status.toLowerCase()] || '#555';
};
g.selectAll('g.node circle').attr('fill', fill);
},
Expand Down

0 comments on commit c679235

Please sign in to comment.