Fixed header generation
This commit is contained in:
parent
2216cea6d5
commit
1bfe2f11fb
@ -59,14 +59,15 @@ module BodyTrackersHelper
|
||||
|
||||
# ...then rowspans
|
||||
single_columns = []
|
||||
spec.each_with_index do |row, i|
|
||||
single_columns.each { |q| row.delete(q) }
|
||||
spec[1..-1].each_with_index do |row, i|
|
||||
row.each do |q, span|
|
||||
if span == 1
|
||||
row[q] = -(spec.length - i)
|
||||
# Current span nil and previous span == 1
|
||||
if span.nil? && (spec[i][q] == 1)
|
||||
spec[i][q] = -(spec.length - i)
|
||||
single_columns << q
|
||||
end
|
||||
end
|
||||
single_columns.each { |q| row.delete(q) }
|
||||
end
|
||||
|
||||
spec
|
||||
|
Reference in New Issue
Block a user