feat(AppConfig): iterate how apps are managed

- auth clients are always shared, cannot be disabled
- custom connections are enabled by default, can be disabled
- any existing connections can be reconnected regardless of its AppConfig or AppAuthClient states
This commit is contained in:
Ali BARIN
2024-12-09 17:46:51 +00:00
parent 00e80f1fba
commit a57134a89c
48 changed files with 192 additions and 563 deletions

View File

@@ -46,9 +46,8 @@ function AdminApplicationSettings(props) {
const defaultValues = useMemo(
() => ({
customConnectionAllowed:
appConfig?.data?.customConnectionAllowed || false,
shared: appConfig?.data?.shared || false,
useOnlyPredefinedAuthClients:
appConfig?.data?.useOnlyPredefinedAuthClients || false,
disabled: appConfig?.data?.disabled || false,
}),
[appConfig?.data],
@@ -62,21 +61,17 @@ function AdminApplicationSettings(props) {
<Paper sx={{ p: 2, mt: 4 }}>
<Stack spacing={2} direction="column">
<Switch
name="customConnectionAllowed"
label={formatMessage('adminAppsSettings.customConnectionAllowed')}
FormControlLabelProps={{
labelPlacement: 'start',
}}
/>
<Divider />
<Switch
name="shared"
label={formatMessage('adminAppsSettings.shared')}
name="useOnlyPredefinedAuthClients"
label={formatMessage(
'adminAppsSettings.useOnlyPredefinedAuthClients',
)}
FormControlLabelProps={{
labelPlacement: 'start',
}}
/>
<Divider />
<Switch
name="disabled"
label={formatMessage('adminAppsSettings.disabled')}
@@ -86,6 +81,7 @@ function AdminApplicationSettings(props) {
/>
<Divider />
</Stack>
<Stack>
<LoadingButton
data-test="submit-button"