Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
43 changes: 16 additions & 27 deletions lib/reporting/drop_off_report.rb
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ module Events
IDV_DOC_AUTH_PHONE_VISITED = 'IdV: phone of record visited'
IDV_ENTER_PASSWORD_VISITED = 'idv_enter_password_visited'
OLD_IDV_ENTER_PASSWORD_VISITED = 'IdV: review info visited'
IDV_PENDING_GPO = 'IdV: USPS address letter enqueued'
IDV_ENTER_PASSWORD_SUBMITTED = 'idv_enter_password_submitted'
OLD_IDV_ENTER_PASSWORD_SUBMITTED = 'IdV: review complete'
IDV_PERSONAL_KEY_SUBMITTED = 'IdV: personal key submitted'
Expand Down Expand Up @@ -215,47 +216,31 @@ def dropoff_metrics_table
),
],
[
'Verified (event)',
idv_personal_key_submitted,
'USPS letter enqueued (event)',
idv_pending_gpo,
dropoff = idv_enter_password_submitted -
idv_personal_key_submitted,
idv_pending_gpo,
percent(
numerator: dropoff,
denominator: idv_enter_password_submitted,
),
percent(
numerator: idv_personal_key_submitted,
numerator: idv_pending_gpo,
denominator: idv_started,
),
],
[
'Blanket proofing rate',
'',
'',
'',
percent(
numerator: idv_personal_key_submitted,
denominator: idv_doc_auth_welcome_submitted,
),
],
[
'Actual proofing rate',
'',
'',
'',
'Verified (event)',
idv_personal_key_submitted,
dropoff = idv_enter_password_submitted -
idv_personal_key_submitted,
percent(
numerator: idv_enter_password_visited,
denominator: idv_doc_auth_image_vendor_submitted,
numerator: dropoff,
denominator: idv_enter_password_submitted,
),
],
[
'Verified proofing rate',
'',
'',
'',
percent(
numerator: idv_personal_key_submitted,
denominator: idv_doc_auth_image_vendor_submitted,
denominator: idv_started,
),
],
]
Expand Down Expand Up @@ -383,6 +368,10 @@ def idv_personal_key_submitted
data[Events::IDV_PERSONAL_KEY_SUBMITTED].count
end

def idv_pending_gpo
data[Events::IDV_PENDING_GPO].count
end

def as_tables
[
proofing_definition_table,
Expand Down
4 changes: 1 addition & 3 deletions spec/lib/reporting/drop_off_report_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -155,10 +155,8 @@ def expected_tables(strings: false)
['Phone finder (page view)'] + string_or_num(strings, 2, 0, 0.0, 0.4),
['Encrypt account: enter password (page view)'] + string_or_num(strings, 1, 1, 0.5, 0.2),
['Personal key input (page view)'] + string_or_num(strings, 1, 0, 0.0, 0.2),
['USPS letter enqueued (event)'] + string_or_num(strings, 0, 1, 1.0, 0.0),
['Verified (event)'] + string_or_num(strings, 1, 0, 0.0, 0.2),
['Blanket proofing rate', '', '', ''] + string_or_num(strings, 0.2),
['Actual proofing rate', '', '', ''] + string_or_num(strings, 0.25),
['Verified proofing rate', '', '', ''] + string_or_num(strings, 0.25),
],
]
end
Expand Down