Commit 6cdfd4b Chris Kosuke Tseng
authored
File tree 1 file changed +8
-2
lines changed
1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -90,12 +90,19 @@ const WorkspaceCardPage = ({
90
90
const isNotAutoProvisioned = ! user . isUsingExpensifyCard
91
91
&& lodashGet ( reimbursementAccount , 'achData.state' , '' ) === BankAccount . STATE . OPEN ;
92
92
let buttonText ;
93
+
94
+ const openBankSetupModal = ( ) => {
95
+ setWorkspaceIDForReimbursementAccount ( route . params . policyID ) ;
96
+ Navigation . navigate ( ROUTES . getBankAccountRoute ( ) ) ;
97
+ } ;
98
+
93
99
if ( user . isFromPublicDomain ) {
94
100
buttonText = translate ( 'workspace.card.addEmail' ) ;
95
101
} else if ( user . isUsingExpensifyCard ) {
96
102
buttonText = translate ( 'workspace.card.manageCards' ) ;
97
103
} else if ( isVerifying || isPending || isNotAutoProvisioned ) {
98
104
buttonText = translate ( 'workspace.card.finishSetup' ) ;
105
+ openBankSetupModal ( ) ;
99
106
} else {
100
107
buttonText = translate ( 'workspace.card.getStarted' ) ;
101
108
}
@@ -106,8 +113,7 @@ const WorkspaceCardPage = ({
106
113
} else if ( user . isUsingExpensifyCard ) {
107
114
openSignedInLink ( CONST . MANAGE_CARDS_URL ) ;
108
115
} else {
109
- setWorkspaceIDForReimbursementAccount ( route . params . policyID ) ;
110
- Navigation . navigate ( ROUTES . getBankAccountRoute ( ) ) ;
116
+ openBankSetupModal ( ) ;
111
117
}
112
118
} ;
113
119
You can’t perform that action at this time.
0 commit comments