From 9e0fdd7e972da2f434f598145733999140efca4b Mon Sep 17 00:00:00 2001 From: Manojava Koushik Date: Wed, 18 Dec 2024 13:20:26 +0530 Subject: [PATCH 1/2] fix(technical integration): add new check box to get user agreement to share tech user details with subscribers --- src/assets/locales/de/main.json | 5 +++- src/assets/locales/en/main.json | 5 +++- .../TechnicalIntegration/index.tsx | 25 +++++++++++++++++++ 3 files changed, 33 insertions(+), 2 deletions(-) diff --git a/src/assets/locales/de/main.json b/src/assets/locales/de/main.json index 12ff430a4..ff9abe59a 100644 --- a/src/assets/locales/de/main.json +++ b/src/assets/locales/de/main.json @@ -1363,7 +1363,10 @@ "roleUpdateError": "Error while updating roles", "encoding": "Encoding(select supported encoding)", "encodingPlaceholder": "Select supported encoding", - "noneOption": "Nicht notwendig (für die Integration ist kein technischer User notwendig)" + "noneOption": "Nicht notwendig (für die Integration ist kein technischer User notwendig)", + "userVisibilityHeader": "3. Technical User Visibility", + "userVisibilityDescription": "Diese Option deaktiviert die Möglichkeit des Abonnenten, Sicherheitsinformationen der für ihn erstellten technischen Benutzer anzuzeigen. Bei dieser Option müssen Abonnenten diese Situation akzeptieren, wenn sie ein Abonnement abschließen möchten", + "userVisibilityTerms": "Deaktivieren Sie die Sichtbarkeit technischer Benutzerdaten für Abonnenten" }, "betaTest": { "headerTitle": "CX Test Runs", diff --git a/src/assets/locales/en/main.json b/src/assets/locales/en/main.json index 7af38098c..a95735467 100644 --- a/src/assets/locales/en/main.json +++ b/src/assets/locales/en/main.json @@ -1332,7 +1332,10 @@ "roleUpdateError": "Error while updating roles", "encoding": "Encoding(select supported encoding)", "encodingPlaceholder": "Select supported encoding", - "noneOption": "none (no technical user needed to run the app/service)" + "noneOption": "none (no technical user needed to run the app/service)", + "userVisibilityHeader": "3. Technical User Visibility", + "userVisibilityDescription": "this option will disable the subscriber's ability to view security information of the technical users created for them. This option requires subscribers to accept this situation if they wish to subscribe", + "userVisibilityTerms": "Disable the visibility of technical user data for subscribers" }, "betaTest": { "headerTitle": "CX Test Runs", diff --git a/src/components/shared/basic/ReleaseProcess/TechnicalIntegration/index.tsx b/src/components/shared/basic/ReleaseProcess/TechnicalIntegration/index.tsx index 4c806d3ed..574e65298 100644 --- a/src/components/shared/basic/ReleaseProcess/TechnicalIntegration/index.tsx +++ b/src/components/shared/basic/ReleaseProcess/TechnicalIntegration/index.tsx @@ -130,6 +130,8 @@ export default function TechnicalIntegration() { }, ] + const [userVisibility, setUserVisibility] = useState(false) + useEffect(() => { csvPreview(uploadFileInfo) }, [selectedEncoding]) @@ -698,6 +700,29 @@ export default function TechnicalIntegration() { )} )} + + + <> + {t('content.apprelease.technicalIntegration.userVisibilityHeader')} + * + + + + {t( + 'content.apprelease.technicalIntegration.userVisibilityDescription' + )} + + + { + setUserVisibility(e.target.checked) + }} + /> + Date: Thu, 16 Jan 2025 14:23:40 +0530 Subject: [PATCH 2/2] fix(marketplace): display tech user terms info on subscribe request overlay --- src/assets/locales/de/main.json | 3 ++- src/assets/locales/en/main.json | 3 ++- src/components/overlays/AppMarketplaceRequest/index.tsx | 7 +++++++ src/components/overlays/ServiceRequest/index.tsx | 7 +++++++ src/features/apps/types.ts | 1 + .../serviceSubscription/serviceSubscriptionApiSlice.ts | 1 + 6 files changed, 20 insertions(+), 2 deletions(-) diff --git a/src/assets/locales/de/main.json b/src/assets/locales/de/main.json index 7ea092d4e..d4b54bd6e 100644 --- a/src/assets/locales/de/main.json +++ b/src/assets/locales/de/main.json @@ -1467,7 +1467,8 @@ "statusHeading": "Für eine bessere Transparenz wird die Abonnementstatusleiste auf der App-Detailseite verfügbar sein. Sie können den Abonnementstatus überprüfen, wenn Sie die App-Detailseite über den App-Marktplatz öffnen.", "desc8": "Der gesamte Vorgang wird voraussichtlich innerhalb von 5 Werktagen abgeschlossen sein.", "desc9": "Vielen Dank, dass Sie sich für den Service entschieden haben.", - "errorMessage": "Das Abonnement war nicht erfolgreich; Bitte wenden Sie sich an Ihren Administrator." + "errorMessage": "Das Abonnement war nicht erfolgreich; Bitte wenden Sie sich an Ihren Administrator.", + "techUserTerms": "Durch die Bestätigung der Bedingungen akzeptieren Sie, dass der technische Benutzer im Eigentum des Dienstanbieters für Sie erstellt wird" }, "techUser": { "details": { diff --git a/src/assets/locales/en/main.json b/src/assets/locales/en/main.json index b46a3e9e1..8fd7a212d 100644 --- a/src/assets/locales/en/main.json +++ b/src/assets/locales/en/main.json @@ -1467,7 +1467,8 @@ "statusHeading": "For a better transparency, the subscription status bar will be available in the app detail page - you can check the subscription status when opening the app detail page from the app marketplace.", "desc8": "The entire process is expected to complete within 5 business days.", "desc9": "Thank you for choosing the service.", - "errorMessage": "The subscription was unsuccessful; please contact your administrator." + "errorMessage": "The subscription was unsuccessful; please contact your administrator.", + "techUserTerms": "By confirming the terms, you accept the technical user will be created for you under the ownership of the service provider" }, "techUser": { "details": { diff --git a/src/components/overlays/AppMarketplaceRequest/index.tsx b/src/components/overlays/AppMarketplaceRequest/index.tsx index 7268e8149..2c1aeb81b 100644 --- a/src/components/overlays/AppMarketplaceRequest/index.tsx +++ b/src/components/overlays/AppMarketplaceRequest/index.tsx @@ -33,6 +33,7 @@ import { useState } from 'react' import { useAddSubscribeAppMutation, useFetchAgreementsQuery, + useFetchAppDetailsQuery, } from 'features/apps/apiSlice' import { closeOverlay } from 'features/control/overlay' import './style.scss' @@ -45,6 +46,7 @@ export default function AppMarketplaceRequest({ id }: { id: string }) { const { t } = useTranslation() const dispatch = useDispatch() const { data: agreements } = useFetchAgreementsQuery(id ?? '') + const { data: item } = useFetchAppDetailsQuery(id) const [addSubscribeApp] = useAddSubscribeAppMutation() const [checkedAgreementsIds, setCheckedAgreementsIds] = useState([]) @@ -142,6 +144,11 @@ export default function AppMarketplaceRequest({ id }: { id: string }) { {t('content.appMarketplace.termsHeading')} + {item?.displayTechnicalUser && ( + + {t('content.appMarketplace.techUserTerms')} + + )} {agreements && agreements.length > 0 ? (
    {agreements?.map((agreement, index) => ( diff --git a/src/components/overlays/ServiceRequest/index.tsx b/src/components/overlays/ServiceRequest/index.tsx index 7eb2e51a7..cc0a83861 100644 --- a/src/components/overlays/ServiceRequest/index.tsx +++ b/src/components/overlays/ServiceRequest/index.tsx @@ -37,6 +37,7 @@ import { closeOverlay } from 'features/control/overlay' import './style.scss' import { error } from 'services/NotifyService' import { AgreementStatus } from '../UpdateCompanyRole' +import { useFetchServiceDetailsQuery } from 'features/serviceSubscription/serviceSubscriptionApiSlice' export default function ServiceRequest({ id }: { id: string }) { const { t } = useTranslation() @@ -46,6 +47,7 @@ export default function ServiceRequest({ id }: { id: string }) { [] ) const { data: serviceAgreements } = useFetchAgreementsQuery(id ?? '') + const { data: item } = useFetchServiceDetailsQuery(id) const [addSubscribeService] = useAddSubscribeServiceMutation() const [serviceSubscriptionOverlay, setServiceSubscriptionOverlay] = useState(true) @@ -121,6 +123,11 @@ export default function ServiceRequest({ id }: { id: string }) { {t('content.serviceMarketplace.termsHeading')} + {item?.displayTechnicalUser && ( + + {t('content.appMarketplace.techUserTerms')} + + )} {serviceAgreements && serviceAgreements.length > 0 ? (
      {serviceAgreements?.map((agreement, index) => ( diff --git a/src/features/apps/types.ts b/src/features/apps/types.ts index 33d58abae..0bf26abce 100644 --- a/src/features/apps/types.ts +++ b/src/features/apps/types.ts @@ -155,6 +155,7 @@ export type AppDetails = AppMarketplaceApp & { [key: string]: string[] | null } offerSubscriptionDetailData?: OfferSubscriptionDataType[] + displayTechnicalUser: boolean } export type Documents = { diff --git a/src/features/serviceSubscription/serviceSubscriptionApiSlice.ts b/src/features/serviceSubscription/serviceSubscriptionApiSlice.ts index 56d42e215..e88bbee97 100644 --- a/src/features/serviceSubscription/serviceSubscriptionApiSlice.ts +++ b/src/features/serviceSubscription/serviceSubscriptionApiSlice.ts @@ -144,6 +144,7 @@ export interface ServiceDetailsResponse { images: string[] privacyPolicies: PrivacyPolicyType[] documents: Documents + displayTechnicalUser: boolean } export interface SubscriptionServiceRequestType {