-
Notifications
You must be signed in to change notification settings - Fork 2.9k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[No QA] Improve VBA deep link routing #3711
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good! I noticed that the Tests
and WebQA
sections are empty. Is that intentional?
// When the step changes we will navigate to update the route params. This is mostly cosmestic as we only use | ||
// the route params when the component first mounts to jump to a specific route instead of picking up where the | ||
// user left off in the flow. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
// When the step changes we will navigate to update the route params. This is mostly cosmestic as we only use | |
// the route params when the component first mounts to jump to a specific route instead of picking up where the | |
// user left off in the flow. | |
// When the step changes we will navigate to update the route params. This is mostly cosmetic as we only use | |
// the route params when the component first mounts to jump to a specific route instead of picking up where the | |
// user left off in the flow. |
@@ -75,7 +76,30 @@ const defaultProps = { | |||
|
|||
class ReimbursementAccountPage extends React.Component { | |||
componentDidMount() { | |||
fetchFreePlanVerifiedBankAccount(); | |||
// We can specify a specific step to navigate to by using route params when the component mounts. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
// We can specify a specific step to navigate to by using route params when the component mounts. | |
// We can specify a step to navigate to by using route params when the component mounts. |
NAB
Sorry meant to mark this as No QA. Will ask QA to test the VBA flow once it's complete. But will add some test steps. |
Updated with test steps + fixed comments. |
✋ This PR was not deployed to staging yet because QA is ongoing. It will be automatically deployed to staging after the next production release. |
🚀 Deployed to staging in version: 1.0.73-4🚀
|
🚀 Deployed to production in version: 1.0.74-0🚀
|
const currentStep = lodashGet( | ||
this.props, | ||
'reimbursementAccount.achData.currentStep', | ||
CONST.BANK_ACCOUNT.STEP.BANK_ACCOUNT, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@marcaaron I have a question: Why do we need to add the default value here?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's been a while for me - but it would seem to imply that there's no reimbursementAccount
data to pull the currentStep from. The "bank account" step is the first step in this flow so that's why we fall back to it.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @marcaaron
Details
achData
I'll create a follow up issue to address the comment left in the code. Basically, since we are allowing deep links to drop the user into a step - it's also possible for them to see a step that they can't possibly action successfully if they are unintentionally directed there. e.g. if they are not currently setting up a VBA and deep link to the
RequestorStep
it won't be possible for them to advance. This is an edge case since they should (theoretically) always have an account "in setup" if we are handing off a deep link.Fixed Issues
Fixes https://github.com/Expensify/Expensify/issues/167246
Tests
/bank-account
and verify you see this screen and that the url does not have any sub-route2. Next, we will be following instructions here to create a "PENDING" account here - but only complete the "Company Information" step 3. Manually add the account
4. Verify the "Company Information" step has the `/company` sub route
5. Advance to the RequestorStep and verify the url changes to `/requestor`
6. Enter the subroute `/company` and verify you can return the to company step to edit the information there (**note:** some fields will not be available to edit)
QA Steps
Tested On
Screenshots
Web
Mobile Web
Desktop
iOS
Android