Submit button enabling revisited
[arvados.git] / apps / workbench / app / views / application / _job_progress.html.erb
1 <% percent_total_tasks = 100 / (j[:tasks_summary][:done] + j[:tasks_summary][:running] + j[:tasks_summary][:failed] + j[:tasks_summary][:todo]) rescue 0 %>
2
3 <% if defined? scaleby %>
4   <% percent_total_tasks *= scaleby %>
5 <% end %>
6
7 <% if not defined? scaleby %>
8   <div class="progress">
9 <% end %>
10
11 <span class="progress-bar progress-bar-success" style="width: <%= j[:tasks_summary][:done] * percent_total_tasks rescue 0 %>%;">
12 </span>
13 <span class="progress-bar progress-bar-danger" style="width: <%= j[:tasks_summary][:failed] * percent_total_tasks rescue 0 %>%;">
14 </span>
15 <span class="progress-bar" style="width: <%= j[:tasks_summary][:running] * percent_total_tasks rescue 0 %>%;">
16 </span>
17
18 <% if not defined? scaleby %>
19 </div>
20 <% end %>