Skip to content

fix(data-consent): Fix non touch customers seeing msa prompt #87133

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

Merged
merged 2 commits into from
Mar 14, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 9 additions & 9 deletions static/gsApp/views/legalAndCompliance/dataConsent.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -29,18 +29,18 @@ const formGroups: JsonFormObject[] = [
),
}
),
disabled: ({hasMsaUpdated, hasBillingAccess, isSuperuser}) =>
(!hasMsaUpdated || !hasBillingAccess) && !isSuperuser,
disabledReason: ({hasMsaUpdated, hasBillingAccess}) =>
hasMsaUpdated
? hasBillingAccess
disabled: ({isTouchCustomerAndNeedsMsaUpdate, hasBillingAccess, isSuperuser}) =>
(isTouchCustomerAndNeedsMsaUpdate || !hasBillingAccess) && !isSuperuser,
disabledReason: ({isTouchCustomerAndNeedsMsaUpdate, hasBillingAccess}) =>
isTouchCustomerAndNeedsMsaUpdate
? t(
'These changes require updates to your account. Please contact your customer success manager to learn more.'
)
: hasBillingAccess
? null
: t(
"You don't have access to manage these billing and subscription details."
)
: t(
'These changes require updates to your account. Please contact your customer success manager to learn more.'
),
),
},
{
name: 'genAIConsent',
Expand Down
4 changes: 2 additions & 2 deletions static/gsApp/views/legalAndCompliance/dataConsentForm.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ function DataConsentForm({subscription}: {subscription: Subscription}) {
isUsRegion,
hasBillingAccess,
isSuperuser,
hasMsaUpdated,
isTouchCustomerAndNeedsMsaUpdate,
} = useGenAiConsentButtonAccess({
subscription,
});
Expand Down Expand Up @@ -67,7 +67,7 @@ function DataConsentForm({subscription}: {subscription: Subscription}) {
isUsRegion,
hasBillingAccess,
isSuperuser,
hasMsaUpdated,
isTouchCustomerAndNeedsMsaUpdate,
}}
forms={DataConsentFields}
/>
Expand Down
Loading