Skip to content

LG-10385 Add new columns for in-person proofing pending#8899

Merged
theabrad merged 7 commits intomainfrom
abrad-lg-10385-ipp-columns
Aug 1, 2023
Merged

LG-10385 Add new columns for in-person proofing pending#8899
theabrad merged 7 commits intomainfrom
abrad-lg-10385-ipp-columns

Conversation

@theabrad
Copy link
Contributor

@theabrad theabrad commented Jul 28, 2023

🎫 Ticket

LG-10382

🛠 Summary of changes

Created two new columns in IdV user's profile for in person verification:

in_person_verification_pending_at is a timestamp for when a profile gets "deactivated" for in person verification.

in_person_enrollment_pending_at is a timestamp for when a user has a pending enrollment. This column is meant to We can use #user.establishing_in_person_enrollment to replace the pending_profile&.proofing_components&.[]('document_check') == Idp::Constants::Vendors::USPS for an in_person_enrollment and make it more explicit in a user's profile.

theabrad added 3 commits July 27, 2023 17:51
added a column to check if a user has a pending in_person_enrollment
before their profile receives the in_person_verification_pending_at
timestamp.

this field is to replace the ProofingComponent 'document_check' for in person
enrollments
changelog: Internal, IdV IPP, add columns in profile for
in_person_proofing_pending
@theabrad theabrad requested a review from a team July 28, 2023 20:48
@kbighorse
Copy link
Contributor

👍🏾


def change
add_column :profiles, :in_person_verification_pending_at, :datetime
add_index :profiles, :in_person_verification_pending_at, algorithm: :concurrently
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we plan to query by this column in the future?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not that much. I'll remove the index. If we do need it we can add it back.

removed in_person_enrollment_pending_at as it is not needed. We can use
user.establishing_in_person_enrollment to check for enrollments
@soniaconnolly
Copy link
Contributor

Are we sure that having a single user.establishing_in_person_enrollment when a user can have multiple profiles won't cause an issue? Maybe that's more support for @jmhooper's proposal to have only one "current" profile at a time.

@theabrad
Copy link
Contributor Author

There's also a foreign_key for profiles so we can create a profile#establishing_in_person_enrollment I'll look into when the profile field gets populated for enrollments. I do agree that the multiple profiles could cause an issue.

@theabrad theabrad merged commit 234e7fc into main Aug 1, 2023
@theabrad theabrad deleted the abrad-lg-10385-ipp-columns branch August 1, 2023 20:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants