From 64ab1b5a0941724992defe83f9dc6767422ef65e Mon Sep 17 00:00:00 2001 From: Sumedhe Dissanayake Date: Fri, 30 Jul 2021 16:35:29 +0530 Subject: [PATCH] Remove skip logout consent configuration for SAML apps --- .../components/edit-application.tsx | 1 + .../forms/advanced-configurations-form.tsx | 42 ++++++++++++------- .../components/settings/advanced-settings.tsx | 8 +++- 3 files changed, 35 insertions(+), 16 deletions(-) diff --git a/apps/console/src/features/applications/components/edit-application.tsx b/apps/console/src/features/applications/components/edit-application.tsx index baeaaed2675..502fb366f92 100755 --- a/apps/console/src/features/applications/components/edit-application.tsx +++ b/apps/console/src/features/applications/components/edit-application.tsx @@ -664,6 +664,7 @@ export const EditApplication: FunctionComponent = onUpdate={ handleApplicationUpdate } featureConfig={ featureConfig } readOnly={ readOnly } + template={ template } data-testid={ `${ testId }-advanced-settings` } /> diff --git a/apps/console/src/features/applications/components/forms/advanced-configurations-form.tsx b/apps/console/src/features/applications/components/forms/advanced-configurations-form.tsx index 4d3f8a1a836..0e8ff007cbb 100644 --- a/apps/console/src/features/applications/components/forms/advanced-configurations-form.tsx +++ b/apps/console/src/features/applications/components/forms/advanced-configurations-form.tsx @@ -21,7 +21,9 @@ import { Field, Form } from "@wso2is/form"; import React, { FunctionComponent, ReactElement } from "react"; import { useTranslation } from "react-i18next"; import { applicationConfig } from "../../../../extensions"; -import { AdvancedConfigurationsInterface } from "../../models"; +import {AdvancedConfigurationsInterface, ApplicationTemplateListItemInterface} from "../../models"; +import SAMLWebApplicationTemplate + from "../../data/application-templates/templates/saml-web-application/saml-web-application.json"; /** * Advanced Configurations for the Application. @@ -33,6 +35,10 @@ interface AdvancedConfigurationsFormPropsInterface extends TestableComponentInte * Make the form read only. */ readOnly?: boolean; + /** + * Application template. + */ + template?: ApplicationTemplateListItemInterface; } /** @@ -50,6 +56,7 @@ export const AdvancedConfigurationsForm: FunctionComponent - + { + SAMLWebApplicationTemplate?.id !== template?.id && + ( + + ) + } featureConfig, onUpdate, readOnly, + template, [ "data-testid" ]: testId } = props; @@ -126,6 +131,7 @@ export const AdvancedSettings: FunctionComponent featureConfig?.applications?.scopes?.update, allowedScopes) } + template={ template } data-testid={ `${ testId }-form` } />