New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
AFE eligibility logic #35192
AFE eligibility logic #35192
Conversation
dashboard/app/models/school.rb
Outdated
if stats.nil? || stats.frl_eligible_total.nil? || stats.students_total.nil? | ||
return false | ||
end | ||
stats.frl_eligible_total.to_f / stats.students_total.to_f >= 0.5 | ||
end | ||
|
||
# determines if school meets Amazon Fugure Engineer criteria | ||
# eligible if a) title I school, >40% URM, or >40% eligible for free and reduced meals |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: is there supposed to be a b)
etc.?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry think I meant to put the different criteria on different lines, will fix.
dashboard/app/models/school.rb
Outdated
return false if stats.nil? | ||
|
||
# To align with maker_high_needs? definition above, returning false | ||
# if we don't have all data for a given school |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
super nit: please end sentences with .
as it makes it a lot easier to read than when newlines might or might not imply end of sentence. :)
Schools are eligible for AFE benefits if they meet any of the following criteria:
Will be used in AFE eligibility flow -- skeleton of UI here.
Testing story
Added new unit tests in
School
model.Reviewer Checklist: