Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PN-14000 / PN-14001 - Debt position detail #1481

Draft
wants to merge 25 commits into
base: feat/test-payments
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
c451507
feat: create debt position step
alessandrogelmi Feb 19, 2025
1378333
feat: loop on recipients instead of create a map
alessandrogelmi Feb 19, 2025
88e4ee3
feat: utility to handle debt position change
alessandrogelmi Feb 20, 2025
c9dde70
fix: skip payment methods step if debt position is set to nothing
alessandrogelmi Feb 20, 2025
7cdb3d7
Merge branch 'feat/test-payments' into fix/PN-13999
alessandrogelmi Feb 20, 2025
ef3aa50
fix: handle steps
alessandrogelmi Feb 20, 2025
a0dd1d9
feat(PN-14000): create new component
SarahDonvito Feb 20, 2025
bed7f88
feat(PN-14000): add new section in debt position detail
SarahDonvito Feb 21, 2025
5f1924f
Merge branch 'feat/test-payments' of github.com:pagopa/pn-frontend in…
SarahDonvito Feb 21, 2025
2f385fd
feat(PN-14000): restore newNotification page
SarahDonvito Feb 21, 2025
35a4d82
feat(PN-14000): update debtposition detail
SarahDonvito Feb 21, 2025
0039e57
feat(PN-14000): wip
SarahDonvito Feb 21, 2025
82b8953
feat(PN-14000): update initialValues and validationSchema
alessandrogelmi Feb 21, 2025
6d704b5
feat: rework initial values structure and add payment box for pagopa …
alessandrogelmi Feb 24, 2025
664cccf
feat(PN-14000): add pafee and vat to debtdetailposition
SarahDonvito Feb 25, 2025
f2031e4
feat(PN-14000): add validation and fix translations
SarahDonvito Feb 25, 2025
220ecee
feat(PN-14000): update redux
SarahDonvito Feb 25, 2025
8150217
feat(PN-14000): update title for payment methods and remove useless p…
SarahDonvito Feb 25, 2025
6ed5e77
feat: error handling on payment
alessandrogelmi Feb 25, 2025
95882a9
feat(PN-14000): update config file and set forwardRef
SarahDonvito Feb 25, 2025
87636e5
feat(PN-14001): add error handling on payment boxes
alessandrogelmi Feb 26, 2025
48c6375
feat(PN-14000): update validation Schema for pagopaintmode, vat and n…
SarahDonvito Feb 26, 2025
f1b7e49
feat(PN-14000): update validation schema
SarahDonvito Feb 26, 2025
60c9bff
feat(PN-14000): set to empty vat and pafee when NotificationFeePolicy…
SarahDonvito Feb 26, 2025
7f2ef49
feat(PN-14001): add validations on payments
alessandrogelmi Feb 26, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion packages/pn-commons/src/components/FileUpload.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ type Props = {
calcSha256?: boolean;
fileUploaded?: { file: { data?: File; sha256?: { hashBase64: string; hashHex: string } } };
fileSizeLimit?: number;
showHashCode?: boolean;
};

enum UploadStatus {
Expand Down Expand Up @@ -165,6 +166,7 @@ const FileUpload = ({
calcSha256 = false,
fileUploaded,
fileSizeLimit = 209715200,
showHashCode = true,
}: Props) => {
const [fileData, dispatch] = useReducer(reducer, {
status: UploadStatus.TO_UPLOAD,
Expand Down Expand Up @@ -369,7 +371,7 @@ const FileUpload = ({
</Box>
)}
</Box>
{fileData.sha256 && (
{fileData.sha256 && showHashCode && (
<Box sx={{ marginTop: '20px' }}>
<Typography variant="body2" fontWeight={600} fontSize={'16px'} color="text.secondary">
{getLocalizedOrDefaultLabel('common', 'upload-file.hash-code', 'Codice hash')}
Expand Down
1 change: 1 addition & 0 deletions packages/pn-commons/src/utility/string.utility.ts
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,7 @@ export const dataRegex = {
// Cfr. the comment in src/utility/user.utility.ts
// ------------------------------------
// Carlos Lombardi, 2023.01.24
currency: /^\d+(?:[.,]\d+)*$/,
};

/**
Expand Down
5 changes: 3 additions & 2 deletions packages/pn-pa-webapp/public/conf/config-dev.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,5 +17,6 @@
"API_B2B_LINK": "https://developer.pagopa.it/send/api#/",
"IS_STATISTICS_ENABLED": true,
"TAXONOMY_SEND_URL": "https://docs.pagopa.it/f.a.q.-per-integratori/tassonomia-send",
"DOWNTIME_EXAMPLE_LINK": "https://www.dev.notifichedigitali.it/static/documents/LegalFactMalfunction.pdf"
}
"DOWNTIME_EXAMPLE_LINK": "https://www.dev.notifichedigitali.it/static/documents/LegalFactMalfunction.pdf",
"PAYMENT_INFO": "https://developer.pagopa.it/send/guides/knowledge-base/readme/pagamenti-e-spese-di-notifica/pagamenti-pagopa"
}
3 changes: 2 additions & 1 deletion packages/pn-pa-webapp/public/locales/it/common.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@
"send": "Invia",
"go-to-home": "Torna alla home page",
"go-to-login": "Accedi",
"close": "Chiudi"
"close": "Chiudi",
"delete": "Elimina"
},
"menu": {
"notifications": "Notifiche",
Expand Down
55 changes: 44 additions & 11 deletions packages/pn-pa-webapp/public/locales/it/notifiche.json
Original file line number Diff line number Diff line change
Expand Up @@ -482,7 +482,7 @@
"add-another-doc": "Aggiungi un altro documento",
"back-to-recipient": "Torna a Destinatario",
"back-to-debt-position": "Torna a Posizione debitoria",
"back-to-payment-methods": "Torna a Dettaglio posizione debitoria",
"back-to-debt-position-detail": "Torna a Dettaglio posizione debitoria",
"remove-document": "Rimuovi documento",
"banner-additional-languages": "Hai scelto di inviare la notifica in più lingue. Ricorda di allegare i documenti in entrambe le lingue selezionate.",
"file-upload-helper": "Il documento deve essere in formato {{format}} e non deve superare le dimensioni di {{size}}"
Expand All @@ -492,23 +492,56 @@
"debt-position": "Posizione debitoria",
"debt-position-of": "Posizione debitoria di {{fullName}}",
"which-type-of-payments": "Quale tipo di pagamento prevedi?",
"back-to-recipient": "Torna a destinatario",
"back-to-recipient": "Torna a Destinatari",
"radios": {
"pago-pa": "Avviso pagoPA",
"f24": "Modello F24",
"pago-pa-f24": "Avviso pagoPA + Modello F24",
"nothing": "Nessun pagamento"
}
},
"payment-methods": {
"title": "Modelli di pagamento",
"pagopa-notice": "Avviso pagoPA",
"f24": "F24",
"payment-models": "Modelli di pagamento per",
"attach-pagopa-notice": "Allega Avviso pagoPA",
"attach-f24": "Allega Modello F24",
"nothing": "<0>Se questa notifica prevede un pagamento, torna a </0><1>Informazioni preliminari</1><2> e seleziona un modello. Poi, torna qui per caricarlo.</2>",
"back-to-attachments": "Torna a Allegati"
"debt-position-detail": {
"title": "Dettaglio posizione debitoria",
"debt-position-of": "Posizione debitoria di {{fullName}}",
"notification-fee": {
"title": "Costo di notifica",
"description": "Scegli il tipo di costo di notifica: puoi scegliere fra quello già incluso nell’atto oppure inserire un costo di notifica personalizzato a carico del destinatario.",
"disclaimer": "L’IVA verrà applicata solo alle notifiche recapitate in modalità cartacea.",
"pa-fee": "Costo di notifica",
"vat": "IVA"
},
"pagopa-int-mode": {
"title": "Tecnologia del pagamento",
"description": "Nella modalità sincrona la posizione debitoria è presso il sistema dell'Ente Creditore (EC), mentre nella modalità asincrona è caricata sul sistema Gestione Posizioni Debitorie (GPD) di pagoPA. <0>Scopri di più</0>"
},
"alert": "Se non hai informazioni certe sull’integrazione pagoPA verifica con il tuo provider tecnologico: in caso di scelta non corretta l’addebito della notifica potrebbe essere errato.",
"back-to-debt-position": "Torna a Posizione debitoria",
"radios": {
"flat-rate": "Incluso nell’atto (forfettario)",
"delivery-mode": "A carico del destinatario (puntuale)",
"sync": "Sincrona",
"async": "Asincrona"
},
"payment-methods": {
"title": "Modelli di pagamento",
"pagopa-notice": "Avviso pagoPA",
"payment-models": "Posizione debitoria di",
"nothing": "<0>Se questa notifica prevede un pagamento, torna a </0><1>Informazioni preliminari</1><2> e seleziona un modello. Poi, torna qui per caricarlo.</2>",
"back-to-attachments": "Torna a Allegati",
"pagopa": {
"attach-pagopa-notice": "Specifiche Avviso pagoPA",
"notice-code": "Codice avviso",
"creditor-taxid": "Codice fiscale ente creditore",
"apply-cost": "Applica costo di notifica",
"add-new-pagopa-notice": "Aggiungi codice di avviso pagoPA"
},
"f24": {
"attach-f24": "Specifiche Modello F24",
"document-name": "Titolo documento",
"apply-cost": "Applica costo di notifica",
"add-new-f24": "Aggiungi un altro Modello F24"
}
}
},
"sync-feedback": {
"title": "La notifica è stata creata",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -319,7 +319,7 @@ const Attachments: React.FC<Props> = ({
return t('back-to-recipient');
}

return hasDebtPosition ? t('back-to-payment-methods') : t('back-to-debt-position');
return hasDebtPosition ? t('back-to-debt-position-detail') : t('back-to-debt-position');
};

useImperativeHandle(forwardedRef, () => ({
Expand Down
Loading