mirror of
https://github.com/edcommonwealth/sqm-dashboards.git
synced 2026-03-08 23:18:18 -07:00
include debugging
This commit is contained in:
parent
364b97d25e
commit
2597d919f5
1 changed files with 3 additions and 3 deletions
|
|
@ -66,10 +66,10 @@ class Category < ApplicationRecord
|
|||
else
|
||||
valid_child_categories += 1
|
||||
|
||||
# puts "ZONES: #{name} | #{cc.name} | #{cc.zones}"
|
||||
puts "ZONES: #{name} | #{cc.name} | #{cc.zones}"
|
||||
|
||||
cc.custom_zones.each_with_index do |zone, index|
|
||||
# puts "ZONE: #{name} | #{zone} | #{index}"
|
||||
puts "ZONE: #{name} | #{zone} | #{index}"
|
||||
total_zones[index] += zone
|
||||
end
|
||||
end
|
||||
|
|
@ -77,7 +77,7 @@ class Category < ApplicationRecord
|
|||
|
||||
if valid_child_categories > 0
|
||||
average_zones = total_zones.map { |zone| zone / valid_child_categories }
|
||||
# puts "TOTAL: #{name} | #{total_zones} | #{valid_child_categories} | #{average_zones} | #{zone_widths}"
|
||||
puts "TOTAL: #{name} | #{total_zones} | #{valid_child_categories} | #{average_zones} | #{zone_widths}"
|
||||
update(zones: average_zones.join(","))
|
||||
end
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue