You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The children served number is not including children served with kits appropriately
Why fix?
Consistency. Corrextness.
Details
Regarding the Annual Survey
This method:
def children_served_with_kits_containing_disposables
organization
.distributions
.for_year(year)
.joins(line_items: {item: :kit})
.merge(Item.disposable)
.where.not(items: {kit_id: nil})
.distinct
.count("kits.id")
end
counts kits that are disposables (which will be 0), not kits that have disposables
Fix it.
(You probably shouldn't take this one unless you are familiar with both the annual survey and kits. And you might need to do SQL for this. So it's a little advanced)
Criteria for completion
behaviour as decribed
tests to confirm the behaviour
The text was updated successfully, but these errors were encountered:
Summary
The children served number is not including children served with kits appropriately
Why fix?
Consistency. Corrextness.
Details
Regarding the Annual Survey
This method:
def children_served_with_kits_containing_disposables
organization
.distributions
.for_year(year)
.joins(line_items: {item: :kit})
.merge(Item.disposable)
.where.not(items: {kit_id: nil})
.distinct
.count("kits.id")
end
counts kits that are disposables (which will be 0), not kits that have disposables
Fix it.
(You probably shouldn't take this one unless you are familiar with both the annual survey and kits. And you might need to do SQL for this. So it's a little advanced)
Criteria for completion
The text was updated successfully, but these errors were encountered: