diff --git a/features/api/adherent_messages.feature b/features/api/adherent_messages.feature index 02121fc8b01..bf5b3731809 100644 --- a/features/api/adherent_messages.feature +++ b/features/api/adherent_messages.feature @@ -351,11 +351,10 @@ Feature: "adherent:a_jour_2025": "Adhérent - À jour 2025", "adherent:a_jour_2025:primo": "Adhérent - À jour 2025 - Primo-adhérent", "adherent:a_jour_2025:recotisation": "Adhérent - À jour 2025 - Recotisation", - "adherent:a_jour_2025:elu_a_jour": "Adhérent - À jour 2025 - Élu à jour", - "adherent:plus_a_jour": "Adhérent - Plus à jour", - "adherent:plus_a_jour:annee_2024": "Adhérent - Plus à jour - À jour 2024", - "adherent:plus_a_jour:annee_2023": "Adhérent - Plus à jour - À jour 2023", - "adherent:plus_a_jour:annee_2022": "Adhérent - Plus à jour - À jour 2022", + "adherent:a_jour_2025:elu_a_jour": "Adhérent - À jour 2025 - Car à jour de cotisation élu", + "adherent:a_jour_2024": "Adhérent - À jour 2024", + "adherent:a_jour_2023": "Adhérent - À jour 2023", + "adherent:a_jour_2022": "Adhérent - À jour 2022", "sympathisant": "Sympathisant", "sympathisant:adhesion_incomplete": "Sympathisant - Adhésion incomplète", "sympathisant:compte_em": "Sympathisant - Ancien compte En Marche", diff --git a/features/api/adherents.feature b/features/api/adherents.feature index 2e44a73eafa..ab7dc2f628e 100644 --- a/features/api/adherents.feature +++ b/features/api/adherents.feature @@ -285,10 +285,15 @@ Feature: "nationality": "FR", "tags": [ { - "code": "adherent:a_jour_2025:recotisation", - "label": "Adhérent à jour 2025", + "code": "adherent:a_jour_2025", + "label": "À jour 2025", "type": "adherent" }, + { + "code": "elu:cotisation_ok:exempte", + "label": "Exempté de cotisation", + "type": "elu" + }, { "type": "role", "label": "Délégué de circonscription", @@ -466,10 +471,15 @@ Feature: "nationality": "FR", "tags": [ { - "code": "adherent:a_jour_2025:recotisation", - "label": "Adhérent à jour 2025", + "code": "adherent:a_jour_2025", + "label": "À jour 2025", "type": "adherent" }, + { + "code": "elu:cotisation_ok:exempte", + "label": "Exempté de cotisation", + "type": "elu" + }, { "type": "role", "label": "Délégué de circonscription", @@ -649,10 +659,15 @@ Feature: "nationality": "FR", "tags": [ { - "code": "adherent:a_jour_2025:recotisation", - "label": "Adhérent à jour 2025", + "code": "adherent:a_jour_2025", + "label": "À jour 2025", "type": "adherent" }, + { + "code": "elu:cotisation_ok:exempte", + "label": "Exempté de cotisation", + "type": "elu" + }, { "type": "role", "label": "Délégué de circonscription", @@ -916,11 +931,10 @@ Feature: "adherent:a_jour_2025": "Adhérent - À jour 2025", "adherent:a_jour_2025:primo": "Adhérent - À jour 2025 - Primo-adhérent", "adherent:a_jour_2025:recotisation": "Adhérent - À jour 2025 - Recotisation", - "adherent:a_jour_2025:elu_a_jour": "Adhérent - À jour 2025 - Élu à jour", - "adherent:plus_a_jour": "Adhérent - Plus à jour", - "adherent:plus_a_jour:annee_2024": "Adhérent - Plus à jour - À jour 2024", - "adherent:plus_a_jour:annee_2023": "Adhérent - Plus à jour - À jour 2023", - "adherent:plus_a_jour:annee_2022": "Adhérent - Plus à jour - À jour 2022", + "adherent:a_jour_2025:elu_a_jour": "Adhérent - À jour 2025 - Car à jour de cotisation élu", + "adherent:a_jour_2024": "Adhérent - À jour 2024", + "adherent:a_jour_2023": "Adhérent - À jour 2023", + "adherent:a_jour_2022": "Adhérent - À jour 2022", "sympathisant": "Sympathisant", "sympathisant:adhesion_incomplete": "Sympathisant - Adhésion incomplète", "sympathisant:compte_em": "Sympathisant - Ancien compte En Marche", @@ -1160,11 +1174,6 @@ Feature: "phone": "+33 1 87 26 42 36", "nationality": "FR", "tags": [ - { - "code": "adherent:a_jour_2025:recotisation", - "label": "Adhérent à jour 2025", - "type": "adherent" - }, { "type": "role", "label": "Président assemblée départementale", @@ -1235,11 +1244,6 @@ Feature: "phone": "+33 1 87 26 42 36", "nationality": "FR", "tags": [ - { - "code": "adherent:a_jour_2025:recotisation", - "label": "Adhérent à jour 2025", - "type": "adherent" - }, { "type": "role", "label": "Président assemblée départementale", @@ -1303,7 +1307,7 @@ Feature: """ { "adherent": 6, - "sympathizer": 3 + "sympathizer": 2 } """ When I send a "GET" request to "/api/v3/adherents/count?scope=president_departmental_assembly&since=2022" @@ -1313,7 +1317,7 @@ Feature: { "adherent": 6, "adherent_since": 5, - "sympathizer": 3 + "sympathizer": 2 } """ When I send a "POST" request to "/api/v3/adherents/count?scope=president_departmental_assembly" with body: @@ -1324,7 +1328,7 @@ Feature: And the JSON should be equal to: """ { - "adherent": 3, + "adherent": 2, "sympathizer": 1 } """ diff --git a/features/api/committees.feature b/features/api/committees.feature index 2fd023a7ac9..2313d5e6541 100644 --- a/features/api/committees.feature +++ b/features/api/committees.feature @@ -48,7 +48,7 @@ Feature: "created_at": "@string@.isDateTime()", "updated_at": "@string@.isDateTime()", "name": "Second Comité des 3 communes", - "members_count": 3, + "members_count": 2, "members_em_count": 0, "sympathizers_count": 0 } @@ -61,7 +61,7 @@ Feature: And the JSON should be equal to: """ { - "members_count": 3, + "members_count": 2, "members_em_count": 0, "sympathizers_count": 0, "description": "Un petit comité avec seulement 3 communes", @@ -115,7 +115,7 @@ Feature: And the JSON should be equal to: """ { - "members_count": 3, + "members_count": 2, "members_em_count": 0, "sympathizers_count": 0, "description": "Un petit comité avec seulement 3 communes", @@ -172,7 +172,7 @@ Feature: And the JSON should be equal to: """ { - "members_count": 3, + "members_count": 2, "members_em_count": 0, "sympathizers_count": 0, "description": "my desc", @@ -228,7 +228,7 @@ Feature: And the JSON should be equal to: """ { - "members_count": 3, + "members_count": 2, "members_em_count": 0, "sympathizers_count": 0, "description": "my desc", diff --git a/features/api/elected_representatives.feature b/features/api/elected_representatives.feature index 12f52b718eb..9f6817c8e4c 100644 --- a/features/api/elected_representatives.feature +++ b/features/api/elected_representatives.feature @@ -362,11 +362,10 @@ Feature: "adherent:a_jour_2025": "Adhérent - À jour 2025", "adherent:a_jour_2025:primo": "Adhérent - À jour 2025 - Primo-adhérent", "adherent:a_jour_2025:recotisation": "Adhérent - À jour 2025 - Recotisation", - "adherent:a_jour_2025:elu_a_jour": "Adhérent - À jour 2025 - Élu à jour", - "adherent:plus_a_jour": "Adhérent - Plus à jour", - "adherent:plus_a_jour:annee_2024": "Adhérent - Plus à jour - À jour 2024", - "adherent:plus_a_jour:annee_2023": "Adhérent - Plus à jour - À jour 2023", - "adherent:plus_a_jour:annee_2022": "Adhérent - Plus à jour - À jour 2022", + "adherent:a_jour_2025:elu_a_jour": "Adhérent - À jour 2025 - Car à jour de cotisation élu", + "adherent:a_jour_2024": "Adhérent - À jour 2024", + "adherent:a_jour_2023": "Adhérent - À jour 2023", + "adherent:a_jour_2022": "Adhérent - À jour 2022", "sympathisant": "Sympathisant", "sympathisant:adhesion_incomplete": "Sympathisant - Adhésion incomplète", "sympathisant:compte_em": "Sympathisant - Ancien compte En Marche", diff --git a/features/api/events.feature b/features/api/events.feature index 73f1475becc..2b954f5fbd0 100644 --- a/features/api/events.feature +++ b/features/api/events.feature @@ -2172,7 +2172,7 @@ Feature: | gisele-berthoux@caramail.com | delegated_b24fea43-ecd8-4bf4-b500-6f97886ab77c | DELETE | /0e5f9f02-fa33-4c2c-a700-4235d752315b/image | Scenario: As connected user I can subscribe to an event - Given I am logged with "benjyd@aol.com" via OAuth client "JeMengage Mobile" with scope "jemarche_app" + Given I am logged with "jacques.picard@en-marche.fr" via OAuth client "JeMengage Mobile" with scope "jemarche_app" When I send a "POST" request to "/api/v3/events/2b7238f9-10ca-4a39-b8a4-ad7f438aa95f/subscribe" Then the response status code should be 400 And the JSON should be equal to: diff --git a/features/api/profile.feature b/features/api/profile.feature index 368c559478e..8a4b2ccd03e 100644 --- a/features/api/profile.feature +++ b/features/api/profile.feature @@ -1362,7 +1362,7 @@ Feature: "name": "Comité des 3 communes" }, { - "members_count": 3, + "members_count": 2, "sympathizers_count": 0, "members_em_count": 0, "description": "Un petit comité avec seulement 3 communes", @@ -1655,7 +1655,7 @@ Feature: """ Scenario: As a logged-in user I can unregister - Given I am logged with "benjyd@aol.com" via OAuth client "JeMengage Mobile" + Given I am logged with "michelle.dufour@example.ch" via OAuth client "JeMengage Mobile" When I send a "POST" request to "/api/v3/profile/unregister" with body: """ { @@ -1728,7 +1728,7 @@ Feature: "type": "committee", "uuid": "@uuid@", "name": "Second Comité des 3 communes", - "members_count": 3, + "members_count": 2, "assembly_committees_count": 2, "can_change_committee": true, "message": null diff --git a/features/api/statutory_message.feature b/features/api/statutory_message.feature index 8f404e5ab8c..f8a030bbab5 100644 --- a/features/api/statutory_message.feature +++ b/features/api/statutory_message.feature @@ -131,7 +131,7 @@ Feature: "label": "Message statutaire de test", "subject": "Voici un message statutaire", "status": "draft", - "recipient_count": 3, + "recipient_count": 2, "preview_link": null, "source": "api", "author": { diff --git a/features/api/user.feature b/features/api/user.feature index 1e14d652f88..35bf37eff9e 100644 --- a/features/api/user.feature +++ b/features/api/user.feature @@ -83,13 +83,7 @@ Feature: "total": 7, "last_month": 7 }, - "tags": [ - { - "code": "adherent:a_jour_2025:recotisation", - "label": "Adhérent à jour 2025", - "type": "adherent" - } - ], + "tags": [], "cadre_access": true, "cadre_auth_path": "/oauth/v2/auth?scope=jemengage_admin&response_type=code&client_id=4498e44f-f214-110d-8b76-98a83f9d2b0c&redirect_uri=http%3A%2F%2Flocalhost%3A3000%2Fauth", "instances": { diff --git a/src/Adherent/Tag/TagEnum.php b/src/Adherent/Tag/TagEnum.php index c7971844acc..5a26a2b1b29 100644 --- a/src/Adherent/Tag/TagEnum.php +++ b/src/Adherent/Tag/TagEnum.php @@ -13,9 +13,6 @@ class TagEnum extends Enum public const ADHERENT_YEAR_RECOTISATION_TAG_PATTERN = self::ADHERENT_YEAR_TAG_PATTERN.':recotisation'; public const ADHERENT_YEAR_ELU_TAG_PATTERN = self::ADHERENT_YEAR_TAG_PATTERN.':elu_a_jour'; - public const ADHERENT_NOT_UP_TO_DATE = self::ADHERENT.':plus_a_jour'; - public const ADHERENT_NOT_UP_TO_DATE_TAG_PATTERN = self::ADHERENT_NOT_UP_TO_DATE.':annee_%s'; - public const SYMPATHISANT = 'sympathisant'; public const SYMPATHISANT_COMPTE_EM = 'sympathisant:compte_em'; public const SYMPATHISANT_COMPTE_AVECVOUS_JEMENGAGE = 'sympathisant:compte_avecvous_jemengage'; @@ -53,7 +50,6 @@ public static function getAdherentTags(bool $adherentOnly = false): array \sprintf(self::ADHERENT_YEAR_PRIMO_TAG_PATTERN, $currentYear), \sprintf(self::ADHERENT_YEAR_RECOTISATION_TAG_PATTERN, $currentYear), \sprintf(self::ADHERENT_YEAR_ELU_TAG_PATTERN, $currentYear), - self::ADHERENT_NOT_UP_TO_DATE, ], array_map( fn (int $year) => self::getAdherentYearTag($year), @@ -94,19 +90,9 @@ public static function getStaticTags(): array ]; } - public static function getAdherentYearTag(?int $year = null, ?string $tag = null): string + public static function getAdherentYearTag(?int $year = null, string $tag = self::ADHERENT_YEAR_TAG_PATTERN): string { - $currentYear = date('Y'); - - if (!$tag) { - if (!$year || $currentYear == $year) { - $tag = self::ADHERENT_YEAR_TAG_PATTERN; - } else { - $tag = self::ADHERENT_NOT_UP_TO_DATE_TAG_PATTERN; - } - } - - return \sprintf($tag, $year ?? $currentYear); + return \sprintf($tag, $year ?? date('Y')); } public static function includesTag(string $searchTag, array $previousTags): bool diff --git a/src/Adherent/Tag/TagGenerator/AdherentStatusTagGenerator.php b/src/Adherent/Tag/TagGenerator/AdherentStatusTagGenerator.php index 19e8667c5e0..b5c3600b002 100644 --- a/src/Adherent/Tag/TagGenerator/AdherentStatusTagGenerator.php +++ b/src/Adherent/Tag/TagGenerator/AdherentStatusTagGenerator.php @@ -42,7 +42,10 @@ public function generate(Adherent $adherent, array $previousTags): array return [\sprintf(TagEnum::ADHERENT_YEAR_RECOTISATION_TAG_PATTERN, $currentYear)]; } - if (\count($adherent->getConfirmedPayments()) || $adherent->hasRecentContribution()) { + if ( + \count($adherent->getConfirmedPayments()) + || $adherent->hasRecentContribution() + ) { return [\sprintf(TagEnum::ADHERENT_YEAR_ELU_TAG_PATTERN, $currentYear)]; } @@ -54,8 +57,10 @@ public function generate(Adherent $adherent, array $previousTags): array && $totalContributionPaymentsByYear[$currentYear] >= 30 && ( !$adherent->findElectedRepresentativeMandates(true) - || $adherent->exemptFromCotisation - || ContributionStatusEnum::NOT_ELIGIBLE === $adherent->getContributionStatus() + || ( + $adherent->exemptFromCotisation + || ContributionStatusEnum::NOT_ELIGIBLE === $adherent->getContributionStatus() + ) ) ) { return [\sprintf(TagEnum::ADHERENT_YEAR_ELU_TAG_PATTERN, $currentYear)]; @@ -66,13 +71,13 @@ public function generate(Adherent $adherent, array $previousTags): array array_keys($countCotisationByYear), array_keys($totalContributionPaymentsByYear) )); - unset($allYears[$currentYear]); - rsort($allYears); + sort($allYears); + $allYears = array_reverse($allYears); foreach ($allYears as $year) { if (\array_key_exists($year, $countCotisationByYear)) { - return [TagEnum::getAdherentYearTag($year)]; + return [\sprintf(TagEnum::ADHERENT_YEAR_TAG_PATTERN, $year)]; } if ( @@ -80,11 +85,13 @@ public function generate(Adherent $adherent, array $previousTags): array && $totalContributionPaymentsByYear[$year] >= 30 && ( !$adherent->findElectedRepresentativeMandates(true) - || $adherent->exemptFromCotisation - || ContributionStatusEnum::NOT_ELIGIBLE === $adherent->getContributionStatus() + || ( + $adherent->exemptFromCotisation + || ContributionStatusEnum::NOT_ELIGIBLE === $adherent->getContributionStatus() + ) ) ) { - return [TagEnum::getAdherentYearTag($year)]; + return [\sprintf(TagEnum::ADHERENT_YEAR_TAG_PATTERN, $year)]; } } } diff --git a/src/Adherent/Tag/TagTranslator.php b/src/Adherent/Tag/TagTranslator.php index caa20b34fb5..f32a5e0e729 100644 --- a/src/Adherent/Tag/TagTranslator.php +++ b/src/Adherent/Tag/TagTranslator.php @@ -20,7 +20,7 @@ public function __construct( ) { } - public function trans(string $tag, bool $fullTag = true, string $domain = '_label_'): string + public function trans(string $tag, bool $fullTag = true): string { if (substr_count($tag, ':')) { $this->loadStaticLabels(); @@ -39,41 +39,40 @@ public function trans(string $tag, bool $fullTag = true, string $domain = '_labe } foreach ($parts as $index => $part) { + if ($negation = str_ends_with($part, '--')) { + $part = substr($part, 0, -2); + } + $matches = []; // Matches a year in the format _YYYY or _YYYY: if (preg_match('/_(\d{4}):?/', $part, $matches)) { $year = $matches[1]; - $parts[$index] = $this->translate(str_replace('_'.$year, '_%s', $part), $domain, $part, ['year' => $year]); + $parts[$index] = $this->translator->trans('adherent.tag.'.str_replace('_'.$year, '_%s', $part), ['year' => $year]); } // Matches a national_event tag in the format national_event:slug elseif (TagEnum::NATIONAL_EVENT === TagEnum::getMainLevel($tag) && $index > 0) { $parts[$index] = $this->tagBuilder->buildLabelFromSlug($part); } else { - $parts[$index] = $this->translate($part, $domain); + $parts[$index] = $this->translate('adherent.tag.'.$part, $part); + } + + if ($negation) { + $parts[$index] = $this->translator->trans('adherent.tag.--negation--.'.TagEnum::getMainLevel($tag)).' '.$parts[$index]; } } return $fullTag ? implode(' - ', $parts) : end($parts); } - return $this->translate($tag, $domain); + return $this->translate('adherent.tag.'.$tag, $tag); } - private function translate(string $key, string $domain, ?string $part = null, array $parameters = []): string + private function translate(string $fullKey, string $part): string { - $pattern = 'adherent.tag%s.%s'; - - $fullKey = \sprintf($pattern, '.'.$domain, $key); - $fullKeyFallback = \sprintf($pattern, '', $key); - - $trans = $this->translator->trans($fullKey, $parameters = array_merge(['current_year' => date('Y')], $parameters)); + $trans = $this->translator->trans($fullKey); if ($trans === $fullKey) { - $trans = $this->translator->trans($fullKeyFallback, $parameters); - - if ($trans === $fullKeyFallback) { - return ucfirst($part ?? $key); - } + return ucfirst($part); } return $trans; diff --git a/src/Admin/Filter/AdherentTagFilter.php b/src/Admin/Filter/AdherentTagFilter.php index cb9f3dfb2a0..3b2141c49e1 100644 --- a/src/Admin/Filter/AdherentTagFilter.php +++ b/src/Admin/Filter/AdherentTagFilter.php @@ -53,10 +53,14 @@ protected function getInitialFilterOptions(): array 'field_options' => [ 'multiple' => true, 'choice_label' => function (string $tag) { - $label = $this->tagTranslator->trans($tag, false, '_filter_'); + $label = $this->tagTranslator->trans($tag, false); if ($count = substr_count($tag, ':')) { - return \sprintf('•%s%s', str_repeat("\u{a0}", $count * 4), $label); + return \sprintf( + '•%s%s', + str_repeat("\u{a0}", $count * 4), + $label + ); } return $label; diff --git a/src/DataFixtures/ORM/LoadDonationData.php b/src/DataFixtures/ORM/LoadDonationData.php index 6d6446e756c..d27bb5c385f 100644 --- a/src/DataFixtures/ORM/LoadDonationData.php +++ b/src/DataFixtures/ORM/LoadDonationData.php @@ -3,7 +3,6 @@ namespace App\DataFixtures\ORM; use App\Address\AddressInterface; -use App\Adherent\Tag\Command\RefreshAdherentTagCommand; use App\Donation\Paybox\PayboxPaymentSubscription; use App\Entity\Adherent; use App\Entity\Donation; @@ -15,14 +14,14 @@ use Doctrine\Common\DataFixtures\DependentFixtureInterface; use Doctrine\Persistence\ObjectManager; use Ramsey\Uuid\Uuid; -use Symfony\Component\Messenger\MessageBusInterface; class LoadDonationData extends Fixture implements DependentFixtureInterface { - public function __construct( - private readonly SlugifyInterface $slugify, - private readonly MessageBusInterface $bus, - ) { + private $slugify; + + public function __construct(SlugifyInterface $slugify) + { + $this->slugify = $slugify; } public function load(ObjectManager $manager): void @@ -169,22 +168,21 @@ public function load(ObjectManager $manager): void ); $this->createTransaction($donation); - foreach ([ - $donator0, - $donator1, - $donator2, - $donator3, - $donator4, - $donator5, - ] as $donator) { - $donator->computeLastSuccessfulDonation(); - $manager->persist($donator); - $manager->flush(); - - if ($donator->isAdherent()) { - $this->bus->dispatch(new RefreshAdherentTagCommand($donator->getAdherent()->getUuid())); - } - } + $donator0->computeLastSuccessfulDonation(); + $donator1->computeLastSuccessfulDonation(); + $donator2->computeLastSuccessfulDonation(); + $donator3->computeLastSuccessfulDonation(); + $donator4->computeLastSuccessfulDonation(); + $donator5->computeLastSuccessfulDonation(); + + $manager->persist($donator0); + $manager->persist($donator1); + $manager->persist($donator2); + $manager->persist($donator3); + $manager->persist($donator4); + $manager->persist($donator5); + + $manager->flush(); } public function createDonator(string $accountId, Adherent $adherent): Donator diff --git a/src/JMEFilter/FilterBuilder/AbstractTagsFilterBuilder.php b/src/JMEFilter/FilterBuilder/AbstractTagsFilterBuilder.php index 1d25a788891..53dc2b3b82a 100644 --- a/src/JMEFilter/FilterBuilder/AbstractTagsFilterBuilder.php +++ b/src/JMEFilter/FilterBuilder/AbstractTagsFilterBuilder.php @@ -45,7 +45,7 @@ public function getTranslatedChoices(): array { $choices = []; foreach ($this->tags as $tag) { - $choices[$tag] = $this->translator->trans($tag, $this->fullTag, '_filter_'); + $choices[$tag] = $this->translator->trans($tag, $this->fullTag); } return $choices; diff --git a/src/Repository/AdherentRepository.php b/src/Repository/AdherentRepository.php index ab20e020bb7..7445a979abd 100644 --- a/src/Repository/AdherentRepository.php +++ b/src/Repository/AdherentRepository.php @@ -1219,7 +1219,7 @@ public function findAllForCongressCNElection(bool $votersOnly = true, ?int $offs if ($votersOnly) { $qb ->andWhere('adherent.tags LIKE :adherent_tag') - ->setParameter('adherent_tag', TagEnum::getAdherentYearTag().'%') + ->setParameter('adherent_tag', TagEnum::getAdherentYearTag(2024).'%') ; } diff --git a/src/Repository/CommitteeRepository.php b/src/Repository/CommitteeRepository.php index 4e921192a14..315356a9acd 100644 --- a/src/Repository/CommitteeRepository.php +++ b/src/Repository/CommitteeRepository.php @@ -162,7 +162,7 @@ public function updateMembershipsCounters(): void c.members_em_count = t.members_em_count, c.sympathizers_count = t.sympathizers_count', [ - TagEnum::ADHERENT.'%', + TagEnum::getAdherentYearTag().'%', TagEnum::SYMPATHISANT.'%', TagEnum::SYMPATHISANT_COMPTE_EM.'%', ] diff --git a/tests/Committee/CommitteeManagerTest.php b/tests/Committee/CommitteeManagerTest.php index 4963e8f3194..7156a7e7821 100644 --- a/tests/Committee/CommitteeManagerTest.php +++ b/tests/Committee/CommitteeManagerTest.php @@ -46,7 +46,7 @@ public function testGetCommitteeHosts() public function testGetOptinCommitteeFollowers() { - $this->assertCount(2, $this->committeeManager->getOptinCommitteeFollowers($this->getCommittee(LoadCommitteeV1Data::COMMITTEE_1_UUID))); + $this->assertCount(0, $this->committeeManager->getOptinCommitteeFollowers($this->getCommittee(LoadCommitteeV1Data::COMMITTEE_1_UUID))); $this->assertCount(2, $this->committeeManager->getOptinCommitteeFollowers($this->getCommittee(LoadCommitteeV1Data::COMMITTEE_3_UUID))); $this->assertCount(10, $this->committeeManager->getOptinCommitteeFollowers($this->getCommittee(LoadCommitteeData::COMMITTEE_1_UUID))); $this->assertCount(3, $this->committeeManager->getOptinCommitteeFollowers($this->getCommittee(LoadCommitteeData::COMMITTEE_2_UUID))); diff --git a/tests/Controller/Renaissance/Formation/ListControllerTest.php b/tests/Controller/Renaissance/Formation/ListControllerTest.php index ccf2e2750bf..574658af1e5 100644 --- a/tests/Controller/Renaissance/Formation/ListControllerTest.php +++ b/tests/Controller/Renaissance/Formation/ListControllerTest.php @@ -28,7 +28,7 @@ public function testREAdherentCanSeeFormations(): void public function testNonREAdherentCanNotSeeFormations(): void { - $this->authenticateAsAdherent($this->client, 'benjyd@aol.com'); + $this->authenticateAsAdherent($this->client, 'jacques.picard@en-marche.fr'); $this->client->request(Request::METHOD_GET, '/espace-adherent/formations'); $this->assertStatusCode(Response::HTTP_FORBIDDEN, $this->client); diff --git a/translations/messages+intl-icu.fr.yml b/translations/messages+intl-icu.fr.yml index c5eedc56293..5906547e684 100644 --- a/translations/messages+intl-icu.fr.yml +++ b/translations/messages+intl-icu.fr.yml @@ -1213,17 +1213,10 @@ admin.new.renaissance_adherent.create.label: Créer un adhérent admin.new.renaissance_adherent.success: Le compte adhérent Renaissance (%s %s) a bien été créé. adherent.tag.adherent: Adhérent -adherent.tag._label_.a_jour_%s: Adhérent {year} -adherent.tag._filter_.a_jour_%s: À jour {year} -adherent.tag._label_.annee_%s: Adhérent {year} -adherent.tag._filter_.annee_%s: À jour {year} -adherent.tag._label_.primo: Primo-adhérent {current_year} -adherent.tag._filter_.primo: Primo-adhérent -adherent.tag._label_.recotisation: Adhérent à jour {current_year} -adherent.tag._filter_.recotisation: Recotisation -adherent.tag._label_.elu_a_jour: Adhérent élu à jour -adherent.tag._filter_.elu_a_jour: Élu à jour -adherent.tag.plus_a_jour: Plus à jour +adherent.tag.a_jour_%s: À jour {year} +adherent.tag.primo: Primo-adhérent +adherent.tag.recotisation: Recotisation +adherent.tag.elu_a_jour: Car à jour de cotisation élu adherent.tag.sympathisant: Sympathisant adherent.tag.compte_em: Ancien compte En Marche adherent.tag.compte_avecvous_jemengage: Anciens comptes Je m'engage et Avec vous @@ -1243,6 +1236,8 @@ adherent.tag.national_event: Événement national adherent.tag.procuration: Procuration adherent.tag.mandant: Mandant adherent.tag.mandataire: Mandataire +adherent.tag.--negation--.procuration: Non +adherent.tag.--negation--.national_event: Non inscrit à adhesion.physical_person.label: Je certifie sur l’honneur être une personne physique d’au moins 16 ans et que le règlement de ma cotisation ne provient pas du compte d’une personne morale (entreprise, association, collectivité...) mais bien de mon compte bancaire personnel.

Je certifie être de nationalité française ou résident fiscal Français.

J’adhère aux Statuts et au Corpus des valeurs de Renaissance.

J’accepte les CGU du site Renaissance et déclare avoir lu la Politique de protection des données personnelles et les mentions d’information relatives au traitement de mes données ci-dessous.