From b354ec71456a9a3b0eda8d46c5c3d1bd2ba4b548 Mon Sep 17 00:00:00 2001 From: Noemi Date: Thu, 3 Jul 2025 09:52:45 +0200 Subject: [PATCH 1/4] add flag applicazione multipla --- .../BandoEdit/components/BandoEditFormStep1/index.js | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/src/pages/BandoEdit/components/BandoEditFormStep1/index.js b/src/pages/BandoEdit/components/BandoEditFormStep1/index.js index cae2a6e..685f702 100644 --- a/src/pages/BandoEdit/components/BandoEditFormStep1/index.js +++ b/src/pages/BandoEdit/components/BandoEditFormStep1/index.js @@ -274,7 +274,17 @@ const BandoEditFormStep1 = forwardRef(function ({ initialData, setInitialData, g onLabel={__('Si', 'gepafin')} offLabel={__('No', 'gepafin')} /> - + Date: Thu, 3 Jul 2025 14:36:16 +0200 Subject: [PATCH 2/4] add multiple application in beneficiario --- .../components/AllBandiAccordion/index.js | 2 +- .../components/BandoEditFormStep1/index.js | 2 +- src/pages/BandoViewBeneficiario/index.js | 23 +++++++++++++------ 3 files changed, 18 insertions(+), 9 deletions(-) diff --git a/src/pages/BandiBeneficiario/components/AllBandiAccordion/index.js b/src/pages/BandiBeneficiario/components/AllBandiAccordion/index.js index 7c9d167..cbe5aa9 100644 --- a/src/pages/BandiBeneficiario/components/AllBandiAccordion/index.js +++ b/src/pages/BandiBeneficiario/components/AllBandiAccordion/index.js @@ -216,7 +216,7 @@ const AllBandiAccordion = ({ showOnlyPreferred = false }) => { {isCallExpired || isCallScheduled || (!isEmpty(chosenCompanyId) && chosenCompanyId !== 0 && data.confidi && (data.id !== 6 || (data.id === 6 && REACT_APP_HUB_ID !== 'p4lk3bcx1RStqTaIVVbXs'))) ? : null} ); diff --git a/src/pages/BandoEdit/components/BandoEditFormStep1/index.js b/src/pages/BandoEdit/components/BandoEditFormStep1/index.js index 685f702..e8cbaa8 100644 --- a/src/pages/BandoEdit/components/BandoEditFormStep1/index.js +++ b/src/pages/BandoEdit/components/BandoEditFormStep1/index.js @@ -277,7 +277,7 @@ const BandoEditFormStep1 = forwardRef(function ({ initialData, setInitialData, g { if (REACT_APP_HUB_ID === 't7jh5wfg9QXylNaTZkPoE') { return __('Presenta domanda', 'gepafin'); } else { - if (applicationObj && applicationObj.id) { - return __('Vai alla domanda', 'gepafin'); - } else { + if(data.allowMultipleApplications){ return __('Presenta domanda', 'gepafin'); + } else { + if (applicationObj && applicationObj.id) { + return __('Vai alla domanda', 'gepafin'); + } else { + return __('Presenta domanda', 'gepafin'); + } } + } } @@ -110,11 +115,15 @@ const BandoViewBeneficiario = () => { if (REACT_APP_HUB_ID === 't7jh5wfg9QXylNaTZkPoE') { return 'pi pi-save'; } else { - if (applicationObj && applicationObj.id) { - return 'pi pi-arrow-right'; - } else { + if(data.allowMultipleApplications){ return 'pi pi-save'; - } + } else { + if (applicationObj && applicationObj.id) { + return 'pi pi-arrow-right'; + } else { + return 'pi pi-save'; + } + } } } From f5e7c890e71bf591e42ef1661869c96414b6f237 Mon Sep 17 00:00:00 2001 From: Noemi Date: Thu, 3 Jul 2025 15:06:20 +0200 Subject: [PATCH 3/4] fix bug --- src/pages/BandoViewBeneficiario/index.js | 36 +++++++++++++++++++----- 1 file changed, 29 insertions(+), 7 deletions(-) diff --git a/src/pages/BandoViewBeneficiario/index.js b/src/pages/BandoViewBeneficiario/index.js index 8bf050d..374af1c 100644 --- a/src/pages/BandoViewBeneficiario/index.js +++ b/src/pages/BandoViewBeneficiario/index.js @@ -132,12 +132,29 @@ const BandoViewBeneficiario = () => { if (data.confidi) { if ((data.id === 6 && REACT_APP_HUB_ID === 'p4lk3bcx1RStqTaIVVbXs') || role === 'ROLE_CONFIDI') { - if (applicationObj && applicationObj.id) { - navigate(`/imieibandi/${applicationObj.id}`); - } else { + if(data.allowMultipleApplications){ const bandoId = getBandoId(); ApplicationService.createApplication(bandoId, {}, createApplCallback, errCreateApplCallback, [['companyId', chosenCompanyId]]); + } else { + if (applicationObj && applicationObj.id) { + navigate(`/imieibandi/${applicationObj.id}`); + } else { + const bandoId = getBandoId(); + ApplicationService.createApplication(bandoId, {}, createApplCallback, errCreateApplCallback, [['companyId', chosenCompanyId]]); + } } + if(data.allowMultipleApplications){ + const bandoId = getBandoId(); + ApplicationService.createApplication(bandoId, {}, createApplCallback, errCreateApplCallback, [['companyId', chosenCompanyId]]); + } else { + if (applicationObj && applicationObj.id) { + navigate(`/imieibandi/${applicationObj.id}`); + } else { + const bandoId = getBandoId(); + ApplicationService.createApplication(bandoId, {}, createApplCallback, errCreateApplCallback, [['companyId', chosenCompanyId]]); + } + } + } else { displayConfidiPopup(); } @@ -146,12 +163,17 @@ const BandoViewBeneficiario = () => { const bandoId = getBandoId(); ApplicationService.createApplication(bandoId, {}, createApplCallback, errCreateApplCallback, [['companyId', chosenCompanyId]]); } else { - if (applicationObj && applicationObj.id) { - navigate(`/imieibandi/${applicationObj.id}`); - } else { + if(data.allowMultipleApplications){ const bandoId = getBandoId(); ApplicationService.createApplication(bandoId, {}, createApplCallback, errCreateApplCallback, [['companyId', chosenCompanyId]]); - } + } else { + if (applicationObj && applicationObj.id) { + navigate(`/imieibandi/${applicationObj.id}`); + } else { + const bandoId = getBandoId(); + ApplicationService.createApplication(bandoId, {}, createApplCallback, errCreateApplCallback, [['companyId', chosenCompanyId]]); + } + } } } } From 48dfa073f7ac4ea7b58e258603dc57a5c79d52e5 Mon Sep 17 00:00:00 2001 From: Noemi Date: Thu, 3 Jul 2025 15:38:14 +0200 Subject: [PATCH 4/4] fix style button --- src/assets/scss/components/appPage.scss | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/assets/scss/components/appPage.scss b/src/assets/scss/components/appPage.scss index 1076549..9157170 100644 --- a/src/assets/scss/components/appPage.scss +++ b/src/assets/scss/components/appPage.scss @@ -414,6 +414,10 @@ flex-wrap: wrap; } +.appPageSection__actions > *:first-child{ + margin-bottom: 24px; +} + .appPageSection .appPageSection__actions:last-of-type { padding-bottom: 48px; }