diff --git a/src/components/shared/DelegationTooltip.tsx b/src/components/shared/DelegationTooltip.tsx new file mode 100644 index 000000000..9a55e44f1 --- /dev/null +++ b/src/components/shared/DelegationTooltip.tsx @@ -0,0 +1,36 @@ +import { type DelegationWithCompactTenants } from '@/api/api.generatedTypes' +import { AuthHooks } from '@/api/auth' +import { AltRoute } from '@mui/icons-material' +import { Tooltip } from '@mui/material' +import React from 'react' +import { useTranslation } from 'react-i18next' + +type DelegationTooltipProps = { + delegation: DelegationWithCompactTenants +} + +export const DelegationTooltip: React.FC = ({ delegation }) => { + const { t } = useTranslation('shared-components', { keyPrefix: 'delegationTooltip' }) + const { jwt } = AuthHooks.useJwt() + + const isDelegator = Boolean(delegation.delegator.id === jwt?.organizationId) + const delegator = delegation.delegator.name + const delegate = delegation.delegate.name + + const label = isDelegator + ? t('label.delegator', { delegate }) + : t('label.delegate', { delegator }) + + return ( + + + + ) +} diff --git a/src/components/shared/UploadDocumentsInterface.tsx b/src/components/shared/UploadDocumentsInterface.tsx index b08bc5a1f..1f4d06054 100644 --- a/src/components/shared/UploadDocumentsInterface.tsx +++ b/src/components/shared/UploadDocumentsInterface.tsx @@ -5,7 +5,7 @@ import { Box, Button, Stack } from '@mui/material' import UploadFileIcon from '@mui/icons-material/UploadFile' import { useTranslation } from 'react-i18next' -type UploadDocumentsInterfaceFormValues = { +export type UploadDocumentsInterfaceFormValues = { interfaceDoc: File | null } diff --git a/src/pages/ProviderEServiceCreatePage/ProviderEServiceCreate.page.tsx b/src/pages/ProviderEServiceCreatePage/ProviderEServiceCreate.page.tsx index 076566f19..e245f2d5a 100644 --- a/src/pages/ProviderEServiceCreatePage/ProviderEServiceCreate.page.tsx +++ b/src/pages/ProviderEServiceCreatePage/ProviderEServiceCreate.page.tsx @@ -22,9 +22,9 @@ import { EServiceQueries } from '@/api/eservice' import { Stepper } from '@/components/shared/Stepper' import { EServiceCreateContextProvider } from './components/EServiceCreateContext' import { - EServiceCreateStepAttributes, - EServiceCreateStepAttributesSkeleton, -} from './components/EServiceCreateStepAttributes' + EServiceCreateStepTechSpec, + EServiceCreateStepTechSpecSkeleton, +} from './components/EServiceCreateStepTechSpec' import { EServiceCreateStepPurpose, EServiceCreateStepPurposeSkeleton, @@ -77,7 +77,7 @@ const ProviderEServiceCreatePage: React.FC = () => { ? [ { label: t('create.stepper.step1Label'), component: EServiceCreateStepGeneral }, { label: t('create.stepper.step2Label'), component: EServiceCreateStepVersion }, - { label: t('create.stepper.step3Label'), component: EServiceCreateStepAttributes }, + { label: t('create.stepper.step3Label'), component: EServiceCreateStepTechSpec }, { label: t('create.stepper.step4Label'), component: CreateStepDocuments }, ] : [ @@ -87,7 +87,7 @@ const ProviderEServiceCreatePage: React.FC = () => { component: CreateStepPurpose, }, { label: t('create.stepper.step2Label'), component: EServiceCreateStepVersion }, - { label: t('create.stepper.step3Label'), component: EServiceCreateStepAttributes }, + { label: t('create.stepper.step3Label'), component: EServiceCreateStepTechSpec }, { label: t('create.stepper.step4Label'), component: CreateStepDocuments }, ] @@ -118,14 +118,14 @@ const ProviderEServiceCreatePage: React.FC = () => { ? [ , , - , + , , ] : [ , , , - , + , , ] diff --git a/src/pages/ProviderEServiceCreatePage/components/EServiceCreateStepAttributes/EServiceCreateStepAttributes.tsx b/src/pages/ProviderEServiceCreatePage/components/EServiceCreateStepAttributes/EServiceCreateStepAttributes.tsx deleted file mode 100644 index 90e0dc682..000000000 --- a/src/pages/ProviderEServiceCreatePage/components/EServiceCreateStepAttributes/EServiceCreateStepAttributes.tsx +++ /dev/null @@ -1,140 +0,0 @@ -import { SectionContainer, SectionContainerSkeleton } from '@/components/layout/containers' -import { Box, Divider } from '@mui/material' -import React from 'react' -import { FormProvider, useForm } from 'react-hook-form' -import { AddAttributesToForm } from '../../../../components/shared/AddAttributesToForm' -import { useEServiceCreateContext } from '../EServiceCreateContext' -import { EServiceMutations } from '@/api/eservice' -import { useTranslation } from 'react-i18next' -import { StepActions } from '@/components/shared/StepActions' -import type { - DescriptorAttribute, - DescriptorAttributes, - UpdateEServiceDescriptorSeed, -} from '@/api/api.generatedTypes' -import type { AttributeKey } from '@/types/attribute.types' -import { compareObjects } from '@/utils/common.utils' -import SaveIcon from '@mui/icons-material/Save' -import ArrowBackIcon from '@mui/icons-material/ArrowBack' -import { CreateAttributeDrawer } from '../../../../components/shared/CreateAttributeDrawer' -import { remapDescriptorAttributesToDescriptorAttributesSeed } from '@/utils/attribute.utils' - -export type CreateStepAttributesFormValues = { - attributes: DescriptorAttributes -} - -export const EServiceCreateStepAttributes: React.FC = () => { - const { t } = useTranslation('eservice', { keyPrefix: 'create' }) - const { descriptor, forward, back } = useEServiceCreateContext() - - const { mutate: updateVersionDraft } = EServiceMutations.useUpdateVersionDraft({ - suppressSuccessToast: true, - }) - - const isReadOnly = Boolean(descriptor?.templateRef?.templateVersionId) - - const [createAttributeCreateDrawerState, setCreateAttributeCreateDrawerState] = React.useState<{ - attributeKey: Exclude - isOpen: boolean - }>({ - attributeKey: 'verified', - isOpen: false, - }) - - const handleCloseAttributeCreateDrawer = () => { - setCreateAttributeCreateDrawerState((prevState) => ({ ...prevState, isOpen: false })) - } - - const handleOpenAttributeCreateDrawerFactory = - (attributeKey: Exclude) => () => { - setCreateAttributeCreateDrawerState({ attributeKey, isOpen: true }) - } - - const defaultValues: CreateStepAttributesFormValues = { - attributes: descriptor?.attributes ?? { certified: [], verified: [], declared: [] }, - } - - const formMethods = useForm({ defaultValues }) - - const onSubmit = (values: CreateStepAttributesFormValues) => { - if (!descriptor) return - - const removeEmptyAttributeGroups = (attributes: Array>) => { - return attributes.filter((group) => group.length > 0) - } - - const attributes = { - certified: removeEmptyAttributeGroups(values.attributes.certified), - verified: removeEmptyAttributeGroups(values.attributes.verified), - declared: removeEmptyAttributeGroups(values.attributes.declared), - } - - const areAttributesEquals = compareObjects(attributes, descriptor.attributes) - - if (areAttributesEquals) { - forward() - return - } - - const payload: UpdateEServiceDescriptorSeed & { - eserviceId: string - descriptorId: string - } = { - audience: descriptor.audience, - voucherLifespan: descriptor.voucherLifespan, - dailyCallsPerConsumer: descriptor.dailyCallsPerConsumer, - dailyCallsTotal: descriptor.dailyCallsTotal, - agreementApprovalPolicy: descriptor.agreementApprovalPolicy, - description: descriptor.description, - attributes: remapDescriptorAttributesToDescriptorAttributesSeed(attributes), - eserviceId: descriptor.eservice.id, - descriptorId: descriptor.id, - } - - updateVersionDraft(payload, { onSuccess: forward }) - } - - return ( - <> - - - - - - - - - - , - }} - forward={{ label: t('forwardWithSaveBtn'), type: 'submit', startIcon: }} - /> - - - - - ) -} - -export const EServiceCreateStepAttributesSkeleton: React.FC = () => { - return -} diff --git a/src/pages/ProviderEServiceCreatePage/components/EServiceCreateStepAttributes/index.ts b/src/pages/ProviderEServiceCreatePage/components/EServiceCreateStepAttributes/index.ts deleted file mode 100644 index 835058d26..000000000 --- a/src/pages/ProviderEServiceCreatePage/components/EServiceCreateStepAttributes/index.ts +++ /dev/null @@ -1 +0,0 @@ -export * from './EServiceCreateStepAttributes' diff --git a/src/pages/ProviderEServiceCreatePage/components/EServiceCreateStepDocuments/EServiceCreateStepDocumentsInterface.tsx b/src/pages/ProviderEServiceCreatePage/components/EServiceCreateStepDocuments/EServiceCreateStepDocumentsInterface.tsx index 8baad10f7..13b7fad6b 100644 --- a/src/pages/ProviderEServiceCreatePage/components/EServiceCreateStepDocuments/EServiceCreateStepDocumentsInterface.tsx +++ b/src/pages/ProviderEServiceCreatePage/components/EServiceCreateStepDocuments/EServiceCreateStepDocumentsInterface.tsx @@ -6,11 +6,10 @@ import { EServiceDownloads, EServiceMutations } from '@/api/eservice' import { getDownloadDocumentName } from '@/utils/eservice.utils' import type { EServiceDoc } from '@/api/api.generatedTypes' import { AuthHooks } from '@/api/auth' -import { UploadDocumentsInterface } from '@/components/shared/UploadDocumentsInterface' - -type EServiceCreateStepDocumentsInterfaceFormValues = { - interfaceDoc: File | null -} +import { + UploadDocumentsInterface, + type UploadDocumentsInterfaceFormValues, +} from '@/components/shared/UploadDocumentsInterface' export function EServiceCreateStepDocumentsInterface() { const { t } = useTranslation('eservice') @@ -21,7 +20,7 @@ export function EServiceCreateStepDocumentsInterface() { const { jwt } = AuthHooks.useJwt() const actualInterface: EServiceDoc | null = descriptor?.interface ?? null - const onSubmit = ({ interfaceDoc }: EServiceCreateStepDocumentsInterfaceFormValues) => { + const onSubmit = ({ interfaceDoc }: UploadDocumentsInterfaceFormValues) => { if (!interfaceDoc || !descriptor) return const prettyName = t('create.step4.interface.prettyName') diff --git a/src/pages/ProviderEServiceCreatePage/components/EServiceCreateStepTechSpec/EServiceCreateStepTechSpec.tsx b/src/pages/ProviderEServiceCreatePage/components/EServiceCreateStepTechSpec/EServiceCreateStepTechSpec.tsx new file mode 100644 index 000000000..19e9dd71f --- /dev/null +++ b/src/pages/ProviderEServiceCreatePage/components/EServiceCreateStepTechSpec/EServiceCreateStepTechSpec.tsx @@ -0,0 +1,185 @@ +import { SectionContainer, SectionContainerSkeleton } from '@/components/layout/containers' +import { Box, Link /* Divider */, Stack } from '@mui/material' +import React from 'react' +import { FormProvider, useForm } from 'react-hook-form' +// import { AddAttributesToForm } from '../../../../components/shared/AddAttributesToForm' +import { useEServiceCreateContext } from '../EServiceCreateContext' +import { EServiceMutations } from '@/api/eservice' +import { Trans, useTranslation } from 'react-i18next' +import { StepActions } from '@/components/shared/StepActions' +import type { + // DescriptorAttribute, + // DescriptorAttributes, + UpdateEServiceDescriptorSeed, + UpdateEServiceDescriptorTemplateInstanceSeed, +} from '@/api/api.generatedTypes' +// import type { AttributeKey } from '@/types/attribute.types' +// import { compareObjects } from '@/utils/common.utils' +import SaveIcon from '@mui/icons-material/Save' +import ArrowBackIcon from '@mui/icons-material/ArrowBack' +// import { CreateAttributeDrawer } from '../../../../components/shared/CreateAttributeDrawer' +// import { remapDescriptorAttributesToDescriptorAttributesSeed } from '@/utils/attribute.utils' +import { EServiceCreateStepDocumentsInterface } from '../EServiceCreateStepDocuments/EServiceCreateStepDocumentsInterface' +import { IconLink } from '@/components/shared/IconLink' +import LaunchIcon from '@mui/icons-material/Launch' +import { openApiCheckerLink, payloadVerificationGuideLink } from '@/config/constants' +import { trackEvent } from '@/config/tracking' +import { minutesToSeconds, secondsToMinutes } from '@/utils/format.utils' +import { RHFTextField } from '@/components/shared/react-hook-form-inputs' +import { compareObjects } from '@/utils/common.utils' +import { remapDescriptorAttributesToDescriptorAttributesSeed } from '@/utils/attribute.utils' + +export type CreateStepTechSpecFormValues = { + audience: string + voucherLifespan: number +} + +export const EServiceCreateStepTechSpec: React.FC = () => { + const { t } = useTranslation('eservice', { keyPrefix: 'create' }) + const { descriptor, forward, back } = useEServiceCreateContext() + + const { mutate: updateVersionDraft } = EServiceMutations.useUpdateVersionDraft({ + suppressSuccessToast: true, + }) + const { mutate: updateInstanceVersionDraft } = EServiceMutations.useUpdateInstanceVersionDraft({ + suppressSuccessToast: true, + }) + + const isEServiceCreatedFromTemplate = Boolean(descriptor?.templateRef?.templateVersionId) + + const defaultValues: CreateStepTechSpecFormValues = { + voucherLifespan: descriptor ? secondsToMinutes(descriptor.voucherLifespan) : 1, + audience: descriptor?.audience?.[0] ?? '', + } + + const formMethods = useForm({ defaultValues }) + + const onSubmit = (values: CreateStepTechSpecFormValues) => { + if (!descriptor) return + + const newDescriptorData = { + ...descriptor, + voucherLifespan: minutesToSeconds(values.voucherLifespan), + audience: [values.audience], + } + + // If nothing has changed skip the update call + const areDescriptorsEquals = compareObjects(newDescriptorData, descriptor) + if (areDescriptorsEquals) { + forward() + return + } + + if (isEServiceCreatedFromTemplate) { + const payload: UpdateEServiceDescriptorTemplateInstanceSeed = { + agreementApprovalPolicy: newDescriptorData.agreementApprovalPolicy, + audience: newDescriptorData.audience, + dailyCallsPerConsumer: newDescriptorData.dailyCallsPerConsumer, + dailyCallsTotal: newDescriptorData.dailyCallsTotal, + } + + updateInstanceVersionDraft( + { + ...payload, + eserviceId: descriptor.eservice.id, + descriptorId: descriptor.id, + }, + { onSuccess: forward } + ) + } else { + const payload: UpdateEServiceDescriptorSeed = { + audience: newDescriptorData.audience, + voucherLifespan: newDescriptorData.voucherLifespan, + dailyCallsPerConsumer: newDescriptorData.dailyCallsPerConsumer, + dailyCallsTotal: newDescriptorData.dailyCallsTotal, + agreementApprovalPolicy: newDescriptorData.agreementApprovalPolicy, + attributes: remapDescriptorAttributesToDescriptorAttributesSeed( + newDescriptorData.attributes + ), + } + + updateVersionDraft( + { + ...payload, + eserviceId: descriptor.eservice.id, + descriptorId: descriptor.id, + }, + { onSuccess: forward } + ) + } + } + + const sectionDescription = + descriptor?.eservice.technology === 'SOAP' ? ( + t(`step3.interface.description.soap`) + ) : ( + <> + {t(`step3.interface.description.rest`)}{' '} + } + onClick={() => trackEvent('INTEROP_EXT_LINK_DTD_API_CHECKER', { src: 'CREATE_ESERVICE' })} + > + {t('step3.interface.description.restLinkLabel')} + + + ) + + return ( + <> + + + + + + + + + + }} + > + {t('step3.voucherSection.audienceField.infoLabel')} + + } + inputProps={{ maxLength: 250 }} + rules={{ required: true, minLength: 1 }} + sx={{ flex: 1, my: 0 }} + /> + + + , + }} + forward={{ label: t('forwardWithSaveBtn'), type: 'submit', startIcon: }} + /> + + + + ) +} + +// TODO fix height of the skeleton +export const EServiceCreateStepTechSpecSkeleton: React.FC = () => { + return +} diff --git a/src/pages/ProviderEServiceCreatePage/components/EServiceCreateStepTechSpec/index.ts b/src/pages/ProviderEServiceCreatePage/components/EServiceCreateStepTechSpec/index.ts new file mode 100644 index 000000000..04584acd2 --- /dev/null +++ b/src/pages/ProviderEServiceCreatePage/components/EServiceCreateStepTechSpec/index.ts @@ -0,0 +1 @@ +export * from './EServiceCreateStepTechSpec' diff --git a/src/pages/ProviderEServiceListPage/ProviderEServiceList.page.tsx b/src/pages/ProviderEServiceListPage/ProviderEServiceList.page.tsx index b8aefcff7..8c03282e3 100644 --- a/src/pages/ProviderEServiceListPage/ProviderEServiceList.page.tsx +++ b/src/pages/ProviderEServiceListPage/ProviderEServiceList.page.tsx @@ -13,12 +13,12 @@ import { } from '@pagopa/interop-fe-commons' import type { GetProducerEServicesParams } from '@/api/api.generatedTypes' import { AuthHooks } from '@/api/auth' -import PlusOneIcon from '@mui/icons-material/PlusOne' import UploadFileIcon from '@mui/icons-material/UploadFile' import type { ActionItemButton } from '@/types/common.types' import { useDrawerState } from '@/hooks/useDrawerState' import { ProviderEServiceImportVersionDrawer } from './components/ProviderEServiceImportVersionDrawer' import { keepPreviousData, useQuery } from '@tanstack/react-query' +import FiberNew from '@mui/icons-material/FiberNew' const ProviderEServiceListPage: React.FC = () => { const { t } = useTranslation('pages', { keyPrefix: 'providerEServiceList' }) @@ -69,7 +69,7 @@ const ProviderEServiceListPage: React.FC = () => { action: () => navigate('PROVIDE_ESERVICE_CREATE'), label: tCommon('createNewBtn'), variant: 'contained', - icon: PlusOneIcon, + icon: FiberNew, }, ] diff --git a/src/pages/ProviderEServiceListPage/components/EServiceTableRow.tsx b/src/pages/ProviderEServiceListPage/components/EServiceTableRow.tsx index 57e32eb8e..3ac698faa 100644 --- a/src/pages/ProviderEServiceListPage/components/EServiceTableRow.tsx +++ b/src/pages/ProviderEServiceListPage/components/EServiceTableRow.tsx @@ -11,8 +11,8 @@ import { TableRow } from '@pagopa/interop-fe-commons' import type { EServiceDescriptorState, ProducerEService } from '@/api/api.generatedTypes' import { AuthHooks } from '@/api/auth' import { useQuery, useQueryClient } from '@tanstack/react-query' -import { ByDelegationChip } from '@/components/shared/ByDelegationChip' import { NotificationBadgeDot } from '@/components/shared/NotificationBadgeDot/NotificationBadgeDot' +import { DelegationTooltip } from '@/components/shared/DelegationTooltip' type EServiceTableRow = { eservice: ProducerEService @@ -69,10 +69,10 @@ export const EServiceTableRow: React.FC = ({ eservice }) => { + {eservice.hasUnreadNotifications && } {eservice.name} - + {eservice.delegation && } ) : ( diff --git a/src/static/locales/en/eservice.json b/src/static/locales/en/eservice.json index 2a014c5a7..313cdda52 100644 --- a/src/static/locales/en/eservice.json +++ b/src/static/locales/en/eservice.json @@ -7,7 +7,7 @@ "step1Label": "General", "step2Label": "Version", "step2ReceiveLabel": "Purpose", - "step3Label": "Attributes", + "step3Label": "Technical specifications", "step4Label": "Documentation" }, "backWithoutSaveBtn": "Back", @@ -123,17 +123,6 @@ "descriptionField": { "label": "What changed in this version?" }, - "voucherSection": { - "title": "Voucher", - "voucherLifespanField": { - "label": "Validity duration (minutes)", - "infoLabel": "Max value: 1440 minutes (24 hours)" - }, - "audienceField": { - "label": "Audience", - "infoLabel": "Represents the recipient of the voucher, i.e. your target resource. Doubts? <1>Read the guide" - } - }, "thresholdSection": { "title": "Threshold of calls expected for consumers", "dailyCallsPerConsumerField": { @@ -152,25 +141,25 @@ } }, "step3": { - "attributesTitle": "Access requirements for version {{versionNumber}}", - "attributesDescription": "Please indicate all the certified, verified, and declared attributes that the consumer must have in order to create an agreement for the e-service", - "attributesAddBtn": "Add attribute", - "attributesCreateBtn": "Create new attribute", - "createAttributeDrawer": { - "title": { - "verified": "Create new verified attribute", - "declared": "Create new declared attribute" - }, - "subtitle": "Once created, the attribute will be available in the list to be added to an e-service", - "nameField": { - "label": "Attribute name", - "infoLabel": "Min 5 characters, max 160 characters" + "interface": { + "title": "Interface (required)", + "description": { + "rest": "Upload the OpenAPI file that describes the API. You must ensure that your specification meets the requirements set in the ModI framework. To check, use", + "restLinkLabel": "the OpenAPI Checker", + "soap": "Upload the WSDL file that describes the API" }, - "descriptionField": { - "label": "Attribute description", - "infoLabel": "Min 10 characters, max 250 characters" + "prettyName": "API specification" + }, + "voucherSection": { + "title": "Voucher", + "voucherLifespanField": { + "label": "Validity duration (minutes)", + "infoLabel": "Max value: 1440 minutes (24 hours)" }, - "submitBtnLabel": "Create attribute" + "audienceField": { + "label": "Audience", + "infoLabel": "Represents the recipient of the voucher, i.e. your target resource. Doubts? <1>Read the guide" + } } }, "step4": { @@ -205,15 +194,6 @@ } } }, - "interface": { - "title": "Interface (required)", - "description": { - "rest": "Upload the OpenAPI file that describes the API. You must ensure that your specification meets the requirements set in the ModI framework. To check, use", - "restLinkLabel": "the OpenAPI Checker", - "soap": "Upload the WSDL file that describes the API" - }, - "prettyName": "API specification" - }, "documentation": { "title": "Documentation", "description": "Upload the technical documents that can help implement the use of this e-service" diff --git a/src/static/locales/en/shared-components.json b/src/static/locales/en/shared-components.json index 2f86027cd..9412df3a0 100644 --- a/src/static/locales/en/shared-components.json +++ b/src/static/locales/en/shared-components.json @@ -371,6 +371,13 @@ "delegate": "Received by Delegation" } }, + "delegationTooltip": { + "label": { + "default": "By Delegation", + "delegator": "Delegated to {{delegate}}", + "delegate": "Received by Delegation by {{delegator}}" + } + }, "riskAnalysis": { "formComponents": { "emptyLabel": "No values available", diff --git a/src/static/locales/it/eservice.json b/src/static/locales/it/eservice.json index b0a68b903..4a6f58ffe 100644 --- a/src/static/locales/it/eservice.json +++ b/src/static/locales/it/eservice.json @@ -7,7 +7,7 @@ "step1Label": "Generale", "step2Label": "Versione", "step2ReceiveLabel": "Finalità", - "step3Label": "Attributi", + "step3Label": "Specifiche tecniche", "step4Label": "Documentazione" }, "backWithoutSaveBtn": "Indietro", @@ -123,17 +123,6 @@ "descriptionField": { "label": "Cosa è cambiato in questa versione?" }, - "voucherSection": { - "title": "Voucher", - "voucherLifespanField": { - "label": "Durata validità (in minuti)", - "infoLabel": "Valore massimo: 1440 minuti (24 ore)" - }, - "audienceField": { - "label": "Audience", - "infoLabel": "Rappresenta il destinatario del voucher, ossia la tua risorsa di destinazione. Dubbi? <1>Consulta la guida" - } - }, "thresholdSection": { "title": "Soglia di chiamate previste per i fruitori", "dailyCallsPerConsumerField": { @@ -152,25 +141,25 @@ } }, "step3": { - "attributesTitle": "Requisiti di accesso per la versione {{versionNumber}}", - "attributesDescription": "Di seguito indica tutti quegli attributi, certificati, verificati o dichiarati che il fruitore dovrà possedere per richiedere la fruizione dell’e-service", - "attributesAddBtn": "Aggiungi attributo", - "attributesCreateBtn": "Crea nuovo attributo", - "createAttributeDrawer": { - "title": { - "verified": "Crea nuovo attributo verificato", - "declared": "Crea nuovo attributo dichiarato" - }, - "subtitle": "Una volta creato, troverai l’attributo nella lista tra quelli disponibili per essere aggiunti ad un e-service", - "nameField": { - "label": "Nome dell'attributo", - "infoLabel": "Min 5 caratteri, max 160 caratteri" + "interfaceSection": { + "title": "Interfaccia (richiesto)", + "description": { + "rest": "Carica il file OpenAPI che descrive l'API. Devi assicurarti che la tua specifica rispetti quanto previsto dal ModI. Per verificare usa", + "restLinkLabel": "l'OpenAPI Checker", + "soap": "Carica il file WSDL che descrive l'API" }, - "descriptionField": { - "label": "Descrizione dell'attributo", - "infoLabel": "Min 10 caratteri, max 250 caratteri" + "prettyName": "Specifica API" + }, + "voucherSection": { + "title": "Voucher", + "voucherLifespanField": { + "label": "Durata validità (in minuti)", + "infoLabel": "Valore massimo: 1440 minuti (24 ore)" }, - "submitBtnLabel": "Crea attributo" + "audienceField": { + "label": "Audience", + "infoLabel": "Rappresenta il destinatario del voucher, ossia la tua risorsa di destinazione. Dubbi? <1>Consulta la guida" + } } }, "step4": { @@ -205,15 +194,6 @@ } } }, - "interface": { - "title": "Interfaccia (richiesto)", - "description": { - "rest": "Carica il file OpenAPI che descrive l'API. Devi assicurarti che la tua specifica rispetti quanto previsto dal ModI. Per verificare usa", - "restLinkLabel": "l'OpenAPI Checker", - "soap": "Carica il file WSDL che descrive l'API" - }, - "prettyName": "Specifica API" - }, "documentation": { "title": "Documentazione", "description": "Inserisci la documentazione tecnica utile all’utilizzo di questo e-service" diff --git a/src/static/locales/it/shared-components.json b/src/static/locales/it/shared-components.json index e11605455..e99d09c1e 100644 --- a/src/static/locales/it/shared-components.json +++ b/src/static/locales/it/shared-components.json @@ -371,6 +371,13 @@ "delegate": "Ricevuto in delega" } }, + "delegationTooltip": { + "label": { + "default": "In delega", + "delegator": "Delegato a {{delegate}}", + "delegate": "Ricevuto in delega da {{delegator}}" + } + }, "riskAnalysis": { "formComponents": { "emptyLabel": "Nessun valore disponibile",