From 3977d9f2ca593a6c800cb35fc5ccc5854936a153 Mon Sep 17 00:00:00 2001 From: Aurelien Poscia Date: Thu, 8 Dec 2022 16:07:42 +0100 Subject: [PATCH] SONAR-17645 Add field in SonarQube UI to enable SCIM feature --- .../settings/components/authentication/SamlAuthentication.tsx | 1 + .../apps/settings/components/authentication/SamlFormField.tsx | 4 +--- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/server/sonar-web/src/main/js/apps/settings/components/authentication/SamlAuthentication.tsx b/server/sonar-web/src/main/js/apps/settings/components/authentication/SamlAuthentication.tsx index 520b4dc2a53..1b8a1ad6973 100644 --- a/server/sonar-web/src/main/js/apps/settings/components/authentication/SamlAuthentication.tsx +++ b/server/sonar-web/src/main/js/apps/settings/components/authentication/SamlAuthentication.tsx @@ -59,6 +59,7 @@ const OPTIONAL_FIELDS = [ 'sonar.auth.saml.signature.enabled', 'sonar.auth.saml.user.email', 'sonar.auth.saml.group.name', + 'sonar.scim.enabled', ]; class SamlAuthentication extends React.PureComponent< diff --git a/server/sonar-web/src/main/js/apps/settings/components/authentication/SamlFormField.tsx b/server/sonar-web/src/main/js/apps/settings/components/authentication/SamlFormField.tsx index f54d5db9e1c..40296a908c5 100644 --- a/server/sonar-web/src/main/js/apps/settings/components/authentication/SamlFormField.tsx +++ b/server/sonar-web/src/main/js/apps/settings/components/authentication/SamlFormField.tsx @@ -35,8 +35,6 @@ interface SamlToggleFieldProps { error: { [key: string]: string }; } -const SAML_SIGNATURE_FIELD = 'sonar.auth.saml.signature.enabled'; - export default function SamlFormField(props: SamlToggleFieldProps) { const { mandatory = false, definition, settingValue, showSecuredTextArea = true, error } = props; @@ -65,7 +63,7 @@ export default function SamlFormField(props: SamlToggleFieldProps) { definition={definition} settingValue={settingValue} toggleDisabled={false} - onChange={(val) => props.onFieldChange(SAML_SIGNATURE_FIELD, val)} + onChange={(value) => props.onFieldChange(definition.key, value)} /> )} {definition.type === undefined && ( -- 2.39.5