-
Notifications
You must be signed in to change notification settings - Fork 16
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Set student loan plan for claim when it exists in student loan data f…
…or FE
- Loading branch information
Showing
14 changed files
with
243 additions
and
95 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
class Claim | ||
class ClaimsAwaitingDecisionFinder | ||
def initialize(policies:) | ||
@policies = policies | ||
end | ||
|
||
attr_reader :policies | ||
|
||
def claims_submitted_without_slc_data | ||
policies.map do |policy| | ||
journey_configuration = Journeys.for_policy(policy).configuration | ||
Claim | ||
.by_academic_year(journey_configuration.current_academic_year) | ||
.by_policy(policy) | ||
.awaiting_decision | ||
.where(submitted_using_slc_data: submitted_using_slc_data(policy)) | ||
end.reduce(&:or) | ||
end | ||
|
||
private | ||
|
||
def submitted_using_slc_data(policy) | ||
if policy == Policies::FurtherEducationPayments | ||
# For 2024/2025 academic year onwards, only FE claims prior to the deployment of LUPEYALPHA-1010 have submitted_using_slc_data = nil | ||
[false, nil] | ||
else | ||
false | ||
end | ||
end | ||
end | ||
end |
6 changes: 6 additions & 0 deletions
6
app/models/journeys/further_education_payments/answers_student_loans_details_updater.rb
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
module Journeys | ||
module FurtherEducationPayments | ||
class AnswersStudentLoansDetailsUpdater < Journeys::AnswersStudentLoansDetailsUpdater | ||
end | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.