1
0

Measurement index improvements

This commit is contained in:
cryptogopher
2019-12-21 18:01:46 +01:00
parent d6b3fe3f60
commit b6dbf369d1
5 changed files with 16 additions and 10 deletions

View File

@@ -24,7 +24,12 @@
</tr>
<tr class="<%= row_class %>" style="display:none">
<td class="date" style="cursor: pointer;" onclick="$(this).closest('tr').prev('tr.primary').toggle(); $(this).closest('tr').prev('tr.primary').nextUntil('tr.primary', 'tr').toggle(); return false;">
<% if @quantities.length > 0
rows = (@extra_r[index].length - 1) / @quantities.length + 2
else
rows = 1
end %>
<td rowspan="<%= rows %>" class="date" style="cursor: pointer;" onclick="$(this).closest('tr').prev('tr.primary').toggle(); $(this).closest('tr').prev('tr.primary').nextUntil('tr.primary', 'tr').toggle(); return false;">
<span class="icon icon-bullet-closed"><%= format_datetime(m) %></span>
</td>
<% @requested_r[index].each do |q_name, value| %>
@@ -38,7 +43,6 @@
<% next unless @quantities.length > 0 %>
<% @extra_r[index].each_slice(@quantities.length).with_index do |values| %>
<tr class="extra <%= row_class %>" style="display:none">
<td class="space"></td>
<% values.each do |q_name, value| %>
<td class="extra">
<p class="quantity"><%= q_name %></p>