2936: fix job progress bars
authorTim Pierce <twp@curoverse.com>
Tue, 17 Jun 2014 19:03:07 +0000 (15:03 -0400)
committerTim Pierce <twp@curoverse.com>
Tue, 17 Jun 2014 19:05:00 +0000 (15:05 -0400)
commitee69f7031612132f0b27fb9b05d24bc1201ead69
tree2252f57baff03e1606e4f29c9ddb9c3700525da8
parent4b8a53c9cfc81a942f985f1799dbc6e27deb3bc2
2936: fix job progress bars

Add edge case settings for when a crunch job could not be started, or
when no tasks were ever created.

Calculate percent_total_tasks as a float, to ensure that it will be
nonzero even if there are more than 100 tasks altogether. Calculate
percentages of individual task progress with .ceil to ensure that there
will be at least 1% shown for each nonzero task status.

Refs #2936
apps/workbench/app/views/application/_job_progress.html.erb