diff --git a/src/main/java/fr/titionfire/ffsaf/domain/service/AffiliationService.java b/src/main/java/fr/titionfire/ffsaf/domain/service/AffiliationService.java index 3604881..70ba494 100644 --- a/src/main/java/fr/titionfire/ffsaf/domain/service/AffiliationService.java +++ b/src/main/java/fr/titionfire/ffsaf/domain/service/AffiliationService.java @@ -261,7 +261,8 @@ public class AffiliationService { }) .call(m -> ((m.getUserId() == null) ? keycloakService.initCompte(m.getId()) : keycloakService.setClubGroupMembre(m, club).map(__ -> m.getUserId())) - .call(userId -> keycloakService.setAutoRoleMembre(userId, m.getRole(), m.getGrade_arbitrage()))) + .call(userId -> keycloakService.setAutoRoleMembre(userId, m.getRole(), m.getGrade_arbitrage())) + .call(userId -> keycloakService.setEmail(userId, m.getEmail()))) .call(m -> Mutiny.fetch(m.getLicences()) .call(l1 -> l1 != null && l1.stream().anyMatch(l -> l.getSaison() == saison) ? Uni.createFrom().nullItem() : diff --git a/src/main/webapp/src/pages/DemandeAff.jsx b/src/main/webapp/src/pages/DemandeAff.jsx index 151d238..ccfa4fd 100644 --- a/src/main/webapp/src/pages/DemandeAff.jsx +++ b/src/main/webapp/src/pages/DemandeAff.jsx @@ -17,14 +17,23 @@ function formatAdresse(data) { } function reconstruireAdresse(infos) { + console.log(infos); let adresseReconstruite = ""; - adresseReconstruite += infos.numero_voie + ' ' + formatAdresse(infos.type_voie) + ' '; + if(infos.numero_voie === null){ + if (infos.complement_adresse) { + adresseReconstruite += formatAdresse(infos.complement_adresse) + ', '; + } + }else{ + adresseReconstruite += infos.numero_voie + ' '; + } + + adresseReconstruite += formatAdresse(infos.type_voie) + ' '; adresseReconstruite += formatAdresse(infos.libelle_voie) + ', '; adresseReconstruite += infos.code_postal + ' ' + infos.libelle_commune + ', '; - if (infos.complement_adresse) { - adresseReconstruite += infos.complement_adresse.toLowerCase() + ', '; + if (infos.complement_adresse && infos.numero_voie !== null) { + adresseReconstruite += formatAdresse(infos.complement_adresse) + ', '; } if (infos.code_cedex && infos.libelle_cedex) { adresseReconstruite += 'Cedex ' + infos.code_cedex + ' - ' + infos.libelle_cedex; @@ -400,4 +409,4 @@ export function DemandeAffOk() { espace FFSAF

); -} \ No newline at end of file +} diff --git a/src/main/webapp/src/pages/admin/affiliation/AffiliationReqPage.jsx b/src/main/webapp/src/pages/admin/affiliation/AffiliationReqPage.jsx index 80424b4..9c8a98e 100644 --- a/src/main/webapp/src/pages/admin/affiliation/AffiliationReqPage.jsx +++ b/src/main/webapp/src/pages/admin/affiliation/AffiliationReqPage.jsx @@ -70,6 +70,7 @@ function Content({data, refresh}) { formData.append('siret', event.target.siret.value); formData.append('rna', event.target.rna.value); formData.append('address', event.target.address.value); + formData.append('contact', event.target.contact.value); if (event.target.logo.files[0]) formData.append('logo', event.target.logo.files[0]); @@ -267,15 +268,9 @@ function MemberPart({index, member}) { setCurrent(-1) if (mode === 2) { setEmail("") - setEmailChoice("0") } }, [mode]); - useEffect(() => { - if (mode !== 2 && email !== "") { - setEmailChoice("1") - } - }, [email]); return