You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
feat(OUT-3617): hide bank-deposit settings UI when the AB gate is off
Read bankDepositEnabled from the settings GET, thread it through the
accordion into InvoiceDetail to hide the checkbox + bank-account
dropdown, and skip the bank-account fetch entirely for gated-off portals.
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Copy file name to clipboardExpand all lines: src/components/dashboard/settings/sections/invoice/InvoiceDetail.tsx
+44-37Lines changed: 44 additions & 37 deletions
Original file line number
Diff line number
Diff line change
@@ -11,6 +11,7 @@ type InvoiceDetailProps = {
11
11
value: InvoiceSettingType[K],
12
12
)=>void
13
13
isLoading: boolean
14
+
bankDepositEnabled: boolean
14
15
bankAccountOptions: AccountOption[]|undefined
15
16
bankAccountsError: unknown
16
17
}
@@ -19,6 +20,7 @@ export default function InvoiceDetail({
19
20
settingState,
20
21
changeSettings,
21
22
isLoading,
23
+
bankDepositEnabled,
22
24
bankAccountOptions,
23
25
bankAccountsError,
24
26
}: InvoiceDetailProps){
@@ -41,44 +43,49 @@ export default function InvoiceDetail({
41
43
}
42
44
/>
43
45
</div>
44
-
<divclassName="mb-5">
45
-
<Checkbox
46
-
label="Create bank deposits for automatic bank reconciliation"
47
-
description="When Stripe pays out, create a QuickBooks bank deposit that matches the net amount deposited to your bank (after fees), so the bank transaction matches automatically."
48
-
checked={settingState.bankDepositFeeFlag}
49
-
onChange={()=>
50
-
changeSettings(
51
-
'bankDepositFeeFlag',
52
-
!settingState.bankDepositFeeFlag,
53
-
)
54
-
}
55
-
/>
56
-
</div>
57
-
{settingState.bankDepositFeeFlag&&(
58
-
<divclassName="mb-5 ml-6">
59
-
{bankAccountsError ? (
60
-
<pclassName="text-xs text-red-600">
61
-
Could not load bank accounts. Reload to retry.
62
-
</p>
63
-
) : (
64
-
<>
65
-
<AccountSelect
66
-
label="Deposit bank account"
67
-
description="The bank account Stripe payouts are deposited into. Used to create the matching QuickBooks bank deposit."
Select a deposit bank account to enable bank deposits.
77
-
</p>
78
-
)}
79
-
</>
46
+
{/* Bank deposit UI is gated behind the AB rollout allowlist. */}
47
+
{bankDepositEnabled&&(
48
+
<>
49
+
<divclassName="mb-5">
50
+
<Checkbox
51
+
label="Create bank deposits for automatic bank reconciliation"
52
+
description="When Stripe pays out, create a QuickBooks bank deposit that matches the net amount deposited to your bank (after fees), so the bank transaction matches automatically."
53
+
checked={settingState.bankDepositFeeFlag}
54
+
onChange={()=>
55
+
changeSettings(
56
+
'bankDepositFeeFlag',
57
+
!settingState.bankDepositFeeFlag,
58
+
)
59
+
}
60
+
/>
61
+
</div>
62
+
{settingState.bankDepositFeeFlag&&(
63
+
<divclassName="mb-5 ml-6">
64
+
{bankAccountsError ? (
65
+
<pclassName="text-xs text-red-600">
66
+
Could not load bank accounts. Reload to retry.
67
+
</p>
68
+
) : (
69
+
<>
70
+
<AccountSelect
71
+
label="Deposit bank account"
72
+
description="The bank account Stripe payouts are deposited into. Used to create the matching QuickBooks bank deposit."
0 commit comments