Skip to content

[$500] Bank Account - Cursor in Routing number shown in "Account number"switching background to foreground #31363

Closed

Description

@izarutskaya

If you haven’t already, check out our contributing guidelines for onboarding and email contributors@expensify.com to request to join our Slack channel!


Version Number: 1.3.99-0
Reproducible in staging?: Y
Reproducible in production?: Y
If this was caught during regression testing, add the test name, ID and link from TestRail:
Email or phone of affected tester (no customers):
Logs: https://stackoverflow.com/c/expensify/questions/4856
Expensify/Expensify Issue URL:
Issue reported by: Applause-Internal Team
Slack conversation: @

Action Performed:

  1. Launch app
  2. Tap profile icon
  3. Tap Workspaces----Workspace
  4. Tap Bank account---Update to USD currency
  5. Tap connect manually
  6. Paste routing number
  7. Keep cursor in Account number
  8. Background the app
  9. Copy the account number
  10. Foreground the app

Expected Result:

When cursor placed in account number, and kept app in background and again bringing foreground, app cursor must be in the same "Account number" field.

Actual Result:

When cursor placed in "account number", and kept app in background and again bringing foreground, app cursor is in "routing number" field instead of "Account number".

Workaround:

Unknown

Platforms:

Which of our officially supported platforms is this issue occurring on?

  • Android: Native
  • Android: mWeb Chrome
  • iOS: Native
  • iOS: mWeb Safari
  • MacOS: Chrome / Safari
  • MacOS: Desktop

Screenshots/Videos

Add any screenshot/video evidence

Bug6277183_1700044938994.bgm.mp4

View all open jobs on GitHub

Upwork Automation - Do Not Edit
  • Upwork Job URL: https://www.upwork.com/jobs/~014a1de3bb375306db
  • Upwork Job ID: 1724770607844880384
  • Last Price Increase: 2023-11-22
  • Automatic offers:
    • getusha | Reviewer | 27951576
    • dukenv0307 | Contributor | 27951578

Activity

  1. added
    ExternalAdded to denote the issue can be worked on by a contributor
    BugSomething is broken. Auto assigns a BugZero manager.
    on Nov 15, 2023
  2. changed the title [-]Bank Account - Cursor in Routing number shown in "Account number"switching background to foreground[/-] [+][$500] Bank Account - Cursor in Routing number shown in "Account number"switching background to foreground[/+] on Nov 15, 2023
  3. melvin-bot commented on Nov 15, 2023

    @melvin-bot
  4. melvin-bot commented on Nov 15, 2023

    @melvin-bot

    Triggered auto assignment to @trjExpensify (Bug), see https://stackoverflow.com/c/expensify/questions/14418 for more details.

  5. added
    Help WantedApply this label when an issue is open to proposals by contributors
    on Nov 15, 2023
  6. melvin-bot commented on Nov 15, 2023

    @melvin-bot

    Bug0 Triage Checklist (Main S/O)

    • This "bug" occurs on a supported platform (ensure Platforms in OP are ✅)
    • This bug is not a duplicate report (check E/App issues and #expensify-bugs)
      • If it is, comment with a link to the original report, close the issue and add any novel details to the original issue instead
    • This bug is reproducible using the reproduction steps in the OP. S/O
      • If the reproduction steps are clear and you're unable to reproduce the bug, check with the reporter and QA first, then close the issue.
      • If the reproduction steps aren't clear and you determine the correct steps, please update the OP.
    • This issue is filled out as thoroughly and clearly as possible
      • Pay special attention to the title, results, platforms where the bug occurs, and if the bug happens on staging/production.
    • I have reviewed and subscribed to the linked Slack conversation to ensure Slack/Github stay in sync
  7. melvin-bot commented on Nov 15, 2023

    @melvin-bot

    Triggered auto assignment to Contributor-plus team member for initial proposal review - @getusha (External)

  8. tienifr commented on Nov 15, 2023

    @tienifr
    Contributor

    Proposal

    Please re-state the problem that we are trying to solve in this issue.

    Bank Account - Cursor in Routing number shown in "Account number"switching background to foreground

    What is the root cause of that problem?

    We're checking isLoading using isLoadingReportData

    const isLoading =
    (this.props.isLoadingReportData || this.props.account.isLoading || this.props.reimbursementAccount.isLoading) &&

    When users comeback from background to foreground, we will call API ReconnectApp that makes isLoadingReportData is true

    -> Connect bank account page is unmounted
    -> Loading indicator is shown

    When isLoadingReportData comes false, Connect bank account page is mounted again and the routing number is focused (by default)

    What changes do you think we should make in order to solve the problem?

    We should check isLoadingReportData to show the loading indicator at the first time

    1. Update isLoadingReportData default value to true like what we did in other places.
    2. In here add new state
            hasReportDataLoaded = !this.props.isLoadingReportData
    
    1. Update it in componentDidUpdate
     if(!this.state.hasReportDataLoaded && !this.props.isLoadingReportData){
               this.setState({
                    hasReportDataLoaded:true
                })
            }
    
    1. Use !this.state.hasReportDataLoaded in here instead of isLoadingReportData

    Result

    Screen.Recording.2023-11-15.at.20.35.08.mov
  9. dukenv0307 commented on Nov 15, 2023

    @dukenv0307
    Contributor

    Proposal

    Please re-state the problem that we are trying to solve in this issue.

    Cursor in Routing number shown in "Account number"switching background to foreground

    What is the root cause of that problem?

    After we come back from the background, ReconnectApp API is called which makes this.props.isLoadingReportData is true. So the first step component is unmounted and then after loading is completed, the first input is focused by default.

    (this.props.isLoadingReportData || this.props.account.isLoading || this.props.reimbursementAccount.isLoading) &&

    What changes do you think we should make in order to solve the problem?

    We should replace IS_LOADING_REPORT_DATA with IS_LOADING_APP which will only be true when OpenApp API is called and rename isLoadingReportData prop by isLoadingApp. That can prevent loading is shown when the user comes back from the background.

    What alternative solutions did you explore? (Optional)

  10. trjExpensify commented on Nov 15, 2023

    @trjExpensify
    Contributor

    Hm, I'm not sure it's worth making a change here. @nkuoch @MariaHCD I assume there's a pretty good reason why we show the loader here on the bank account page?

  11. tienifr commented on Nov 16, 2023

    @tienifr
    Contributor

    @trjExpensify But I don't think showing the loading indicator whenever users background then foreground is the good idea. We have nothing to load.

  12. 22 remaining items

  13. trjExpensify commented on Dec 4, 2023

    @trjExpensify
    Contributor

    @joelbettner can you review this proposal please so we can move to a PR? Thanks!

  14. joelbettner commented on Dec 4, 2023

    @joelbettner
    Contributor

    @dukenv0307's proposal looks good to me.

  15. removed
    Help WantedApply this label when an issue is open to proposals by contributors
    on Dec 4, 2023
  16. melvin-bot commented on Dec 4, 2023

    @melvin-bot

    📣 @getusha 🎉 An offer has been automatically sent to your Upwork account for the Reviewer role 🎉 Thanks for contributing to the Expensify app!

    Offer link
    Upwork job

  17. melvin-bot commented on Dec 4, 2023

    @melvin-bot

    📣 @dukenv0307 🎉 An offer has been automatically sent to your Upwork account for the Contributor role 🎉 Thanks for contributing to the Expensify app!

    Offer link
    Upwork job
    Please accept the offer and leave a comment on the Github issue letting us know when we can expect a PR to be ready for review 🧑‍💻
    Keep in mind: Code of Conduct | Contributing 📖

  18. added
    ReviewingHas a PR in review
    and removed on Dec 5, 2023
  19. dukenv0307 commented on Dec 5, 2023

    @dukenv0307
    Contributor

    @getusha The PR is ready for review

  20. getusha commented on Dec 25, 2023

    @getusha
    Contributor

    @trjExpensify PR was deployed to production 2 weeks a go, seems like automation failed.

  21. trjExpensify commented on Jan 3, 2024

    @trjExpensify
    Contributor

    Hey, back from the festive break! Confirming payments as follows:

    $500 - @getusha for the C+ review
    $500 - @dukenv0307 for the fix.

    Settled up, closing!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

BugSomething is broken. Auto assigns a BugZero manager.ExternalAdded to denote the issue can be worked on by a contributorReviewingHas a PR in reviewWeeklyKSv2

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions