bcgov / entity

ServiceBC Registry Team working on Legal Entities
Apache License 2.0
23 stars 59 forks source link

NR UI: "find name request" errors are not well handled #5859

Closed severinbeauvais closed 3 years ago

severinbeauvais commented 3 years ago

If I search for an existing NR and the API fails to respond (eg, timeout after 30s or other error), then the UI does not handle this error well.

cameron-eyds commented 3 years ago

As Severin noticed before, our handling when quitting/cancelling payments has extended functionality that can cause potential data issues. Not sure the extent of the issues but this console error presents itself after cancelling said payment. Screen Shot 2020-12-09 at 12.40.51 PM.png

severinbeauvais commented 3 years ago

This has turned into a general "handle network errors" ticket... The following error handling is broken:

severinbeauvais commented 3 years ago

What I found/learned:

severinbeauvais commented 3 years ago

Test Notes

Please verify the following:

  1. Existing Name Request tab

    • retrieve valid NR
    • retrieve mismatched NR / phone / email
    • retrieve NR with a network error (*)
  2. Name Request summary page

    • click Edit then click return
    • click Edit with network error (*)
    • click Upgrade Priority then cancel
    • click Download Receipts then cancel
    • click Cancel and Refund then cancel
    • click Cancel Name Request then cancel
    • verify Extend Expiry then cancel (may not testable atm)
    • verify all the above with a network error (*)
  3. Upgrade Priority modal

    • verify Accept with a network error (*)
    • verify Accept
  4. Download Receipts modal

    • verify Download PDF with a network error (*)
    • verify Download PDF
  5. Cancel and Refund modal

    • verify Cancel this Name Request with a network error (*)
    • verify Cancel this Name Request
  6. Cancel Name Request modal

    • verify Cancel this Name Request with a network error (*)
    • verify Cancel this Name Request
  7. Extend Expiry (aka Reapply) modal

    • verify Accept with a network error (*)
    • verify Accept
  8. New Name Search tab

    • verify Payment modal (after Review and Confirm) with a network error (*)
    • verify Payment modal
    • verify Payment Complete modal (after return from Pay)

Note that some pages still do not have functional error handling -- see #5898 and #5899.

* to simulate a network error, go to dev console → network tab → set network = offline * all network errors should display some notification to the user, either red text on form or an error modal