diff --git a/.changes/unreleased/DX-20260324-153805.yaml b/.changes/unreleased/DX-20260324-153805.yaml new file mode 100644 index 000000000..a1b22a054 --- /dev/null +++ b/.changes/unreleased/DX-20260324-153805.yaml @@ -0,0 +1,8 @@ +kind: DX +body: 'Changie: add a field for adding a release note tag when creating an entry in changie.' +time: 2026-03-24T15:38:05.320350835+01:00 +custom: + IRN: "No" + Issue: "" + MR: "" + SchemaChange: No schema change diff --git a/.changes/unreleased/Feature-20260324-164018.yaml b/.changes/unreleased/Feature-20260324-164018.yaml new file mode 100644 index 000000000..6a2b6822c --- /dev/null +++ b/.changes/unreleased/Feature-20260324-164018.yaml @@ -0,0 +1,7 @@ +kind: Feature +body: Add a field "externalId" on center, to ease the synchronisation of centers with external tools +time: 2026-03-24T16:40:18.159561269+01:00 +custom: + Issue: "507" + MR: "977" + SchemaChange: Add columns or tables diff --git a/.changes/v4.13.0.md b/.changes/v4.13.0.md new file mode 100644 index 000000000..cb92860e2 --- /dev/null +++ b/.changes/v4.13.0.md @@ -0,0 +1,15 @@ +## v4.13.0 - 2026-02-23 +### Feature +* ([#500](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/500)) ([!964](https://gitlab.com/Chill-Projet/chill-bundles/-/merge_requests/964)) Limit the number of public download of stored object to 30 downloads +* ([#495](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/495)) ([!967](https://gitlab.com/Chill-Projet/chill-bundles/-/merge_requests/967)) Send email related to notification in both html and txt format, and render quote correctly + +### Fixed +* ([#438](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/438)) Change wrong color of submit button "Désigner comme adresse du parcours" +* ([#498](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/498)) For giving edit permissions on documents, take into account the workflow creator +* Fixed mispelling of address in translations: addresse -> adresse +* ([#499](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/499)) ([!963](https://gitlab.com/Chill-Projet/chill-bundles/-/merge_requests/963)) Fix: some postal code appears in the UI, although they are marked as deleted +* ([#501](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/501)) ([!966](https://gitlab.com/Chill-Projet/chill-bundles/-/merge_requests/966)) Fix deprecation in the markdown rendering +* ([#494](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/494)) ([!965](https://gitlab.com/Chill-Projet/chill-bundles/-/merge_requests/965)) Remove unused all-day slot display + +### DX +* ([!960](https://gitlab.com/Chill-Projet/chill-bundles/-/merge_requests/960)) Configure changie to ask for merge request number for a better tracking of changes diff --git a/.changes/v4.14.0.md b/.changes/v4.14.0.md new file mode 100644 index 000000000..9ad3b65c9 --- /dev/null +++ b/.changes/v4.14.0.md @@ -0,0 +1,6 @@ +## v4.14.0 - 2026-03-09 +### Feature +* ([#486](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/486)) ([!](https://gitlab.com/Chill-Projet/chill-bundles/-/merge_requests/)) Add filter and aggregator based on referrer's main center for exports of accompanying period +### Fixed +* ([#502](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/502)) ([!968](https://gitlab.com/Chill-Projet/chill-bundles/-/merge_requests/968)) Fix import of postal code: mark postal code as deleted if they are not present in the import any more +* ([#503](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/503)) ([!969](https://gitlab.com/Chill-Projet/chill-bundles/-/merge_requests/969)) Add a flash message when reassigning accompanying course (reassign list) diff --git a/.changes/v4.14.1.md b/.changes/v4.14.1.md new file mode 100644 index 000000000..e1d512776 --- /dev/null +++ b/.changes/v4.14.1.md @@ -0,0 +1,5 @@ +## v4.14.1 - 2026-03-16 +### Security +* ([#506](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/506)) ([!972](https://gitlab.com/Chill-Projet/chill-bundles/-/merge_requests/972)) Fix permission in list of activities in person context +### DX +* ([#504](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/504)) ([!970](https://gitlab.com/Chill-Projet/chill-bundles/-/merge_requests/970)) Add seeds in DataFixtures and in some tests to avoid random test failures diff --git a/.changes/v4.14.2.md b/.changes/v4.14.2.md new file mode 100644 index 000000000..5de87f68a --- /dev/null +++ b/.changes/v4.14.2.md @@ -0,0 +1,3 @@ +## v4.14.2 - 2026-03-18 +### Fixed +* Fix link inside notification email diff --git a/.changie.yaml b/.changie.yaml index ec0640e32..cbd628f06 100644 --- a/.changie.yaml +++ b/.changie.yaml @@ -7,7 +7,7 @@ versionFormat: '## {{.Version}} - {{.Time.Format "2006-01-02"}}' kindFormat: '### {{.Kind}}' # Note: it is possible to add a `.custom.Long` text manually into the yaml file produced by `changie new`. This will add a long description. changeFormat: >- - * {{ if not (eq .Custom.Issue "") }}([#{{ .Custom.Issue }}](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/{{ .Custom.Issue }})) {{ end }}{{ .Body }} {{ if and .Custom.SchemaChange (ne .Custom.SchemaChange "No schema change") }} + * {{ if not (eq .Custom.Issue "") }}([#{{ .Custom.Issue }}](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/{{ .Custom.Issue }})) {{ end }}{{ if not (eq .Custom.MR "") }}([!{{ .Custom.MR }}](https://gitlab.com/Chill-Projet/chill-bundles/-/merge_requests/{{ .Custom.MR }})) {{ end }}{{ .Body }} {{ if (eq .Custom.IRN "Yes") }}(RN){{ end }} {{ if and .Custom.SchemaChange (ne .Custom.SchemaChange "No schema change") }} **Schema Change**: {{ .Custom.SchemaChange }} {{- end -}} @@ -30,6 +30,20 @@ custom: type: int minInt: 1 + - key: MR + label: Merge request number (on chill-bundles repository) (optional) + optional: true + type: int + minInt: 1 + + - key: IRN + label: Is this interesting for release notes ? + optional: false + type: enum + enumOptions: + - "No" + - "Yes" + body: # allow multiline messages block: true diff --git a/.junie/guidelines.md b/.junie/guidelines.md index ad355eac7..df0efdfbb 100644 --- a/.junie/guidelines.md +++ b/.junie/guidelines.md @@ -234,17 +234,17 @@ This must be a decision made by a human, not by an AI. Every AI task must abort #### Running Tests -The tests are run from the project's root (not from the bundle's root: so, do not change the directory to any bundle directory before running tests). - -Tests must be run using the `symfony` command: +The tests are run from the project's root (not from the bundle's root). ```bash +# Run all tests +symfony composer exec phpunit # Run a specific test file symfony composer exec phpunit -- path/to/TestFile.php # Run a specific test method -symfony composer exec phpunit -- --filter methodName path/to/TestFile.php +symfony composer exec phpunit --filter methodName path/to/TestFile.php ``` When writing tests, only test specific files. Do not run all tests or the full diff --git a/CHANGELOG.md b/CHANGELOG.md index 1f93dc783..192a21e2a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,39 @@ adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html), and is generated by [Changie](https://github.com/miniscruff/changie). +## v4.14.2 - 2026-03-18 +### Fixed +* Fix link inside notification email + +## v4.14.1 - 2026-03-16 +### Security +* ([#506](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/506)) ([!972](https://gitlab.com/Chill-Projet/chill-bundles/-/merge_requests/972)) Fix permission in list of activities in person context +### DX +* ([#504](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/504)) ([!970](https://gitlab.com/Chill-Projet/chill-bundles/-/merge_requests/970)) Add seeds in DataFixtures and in some tests to avoid random test failures + +## v4.14.0 - 2026-03-09 +### Feature +* ([#486](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/486)) ([!](https://gitlab.com/Chill-Projet/chill-bundles/-/merge_requests/)) Add filter and aggregator based on referrer's main center for exports of accompanying period +### Fixed +* ([#502](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/502)) ([!968](https://gitlab.com/Chill-Projet/chill-bundles/-/merge_requests/968)) Fix import of postal code: mark postal code as deleted if they are not present in the import any more +* ([#503](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/503)) ([!969](https://gitlab.com/Chill-Projet/chill-bundles/-/merge_requests/969)) Add a flash message when reassigning accompanying course (reassign list) + +## v4.13.0 - 2026-02-23 +### Feature +* ([#500](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/500)) ([!964](https://gitlab.com/Chill-Projet/chill-bundles/-/merge_requests/964)) Limit the number of public download of stored object to 30 downloads +* ([#495](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/495)) ([!967](https://gitlab.com/Chill-Projet/chill-bundles/-/merge_requests/967)) Send email related to notification in both html and txt format, and render quote correctly + +### Fixed +* ([#438](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/438)) Change wrong color of submit button "Désigner comme adresse du parcours" +* ([#498](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/498)) For giving edit permissions on documents, take into account the workflow creator +* Fixed mispelling of address in translations: addresse -> adresse +* ([#499](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/499)) ([!963](https://gitlab.com/Chill-Projet/chill-bundles/-/merge_requests/963)) Fix: some postal code appears in the UI, although they are marked as deleted +* ([#501](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/501)) ([!966](https://gitlab.com/Chill-Projet/chill-bundles/-/merge_requests/966)) Fix deprecation in the markdown rendering +* ([#494](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/494)) ([!965](https://gitlab.com/Chill-Projet/chill-bundles/-/merge_requests/965)) Remove unused all-day slot display + +### DX +* ([!960](https://gitlab.com/Chill-Projet/chill-bundles/-/merge_requests/960)) Configure changie to ask for merge request number for a better tracking of changes + ## v4.12.1 - 2026-02-01 ### Fixed * ([#496](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/496)) Add the option to deal with duplicate address in BAN adress importer diff --git a/config/packages/nelmio_alice.yaml b/config/packages/nelmio_alice.yaml index e82c32982..e6e912228 100644 --- a/config/packages/nelmio_alice.yaml +++ b/config/packages/nelmio_alice.yaml @@ -8,5 +8,6 @@ when@dev: &dev - 'file' - 'md5' - 'sha1' + seed: 1234567890 when@test: *dev diff --git a/src/Bundle/ChillActivityBundle/DataFixtures/ORM/LoadActivity.php b/src/Bundle/ChillActivityBundle/DataFixtures/ORM/LoadActivity.php index 80c1e4254..8736e78f5 100644 --- a/src/Bundle/ChillActivityBundle/DataFixtures/ORM/LoadActivity.php +++ b/src/Bundle/ChillActivityBundle/DataFixtures/ORM/LoadActivity.php @@ -33,6 +33,7 @@ class LoadActivity extends AbstractFixture implements OrderedFixtureInterface public function __construct(private readonly EntityManagerInterface $em) { + mt_srand(123456789); $this->faker = FakerFactory::create('fr_FR'); } @@ -48,7 +49,7 @@ class LoadActivity extends AbstractFixture implements OrderedFixtureInterface ->findAll(); foreach ($persons as $person) { - $activityNbr = random_int(0, 3); + $activityNbr = mt_rand(0, 3); for ($i = 0; $i < $activityNbr; ++$i) { $activity = $this->newRandomActivity($person); @@ -73,7 +74,7 @@ class LoadActivity extends AbstractFixture implements OrderedFixtureInterface // ->setAttendee($this->faker->boolean()) - for ($i = 0; random_int(0, 4) > $i; ++$i) { + for ($i = 0; mt_rand(0, 4) > $i; ++$i) { $reason = $this->getRandomActivityReason(); if (null !== $reason) { diff --git a/src/Bundle/ChillActivityBundle/Repository/ActivityACLAwareRepository.php b/src/Bundle/ChillActivityBundle/Repository/ActivityACLAwareRepository.php index 34ddfe432..57935a2d9 100644 --- a/src/Bundle/ChillActivityBundle/Repository/ActivityACLAwareRepository.php +++ b/src/Bundle/ChillActivityBundle/Repository/ActivityACLAwareRepository.php @@ -24,6 +24,7 @@ use Chill\MainBundle\Security\Authorization\AuthorizationHelperForCurrentUserInt use Chill\MainBundle\Security\Resolver\CenterResolverManagerInterface; use Chill\PersonBundle\Entity\AccompanyingPeriod; use Chill\PersonBundle\Entity\Person; +use Chill\PersonBundle\Security\Authorization\AccompanyingPeriodVoter; use Doctrine\DBAL\Types\Types; use Doctrine\ORM\AbstractQuery; use Doctrine\ORM\EntityManagerInterface; @@ -340,7 +341,7 @@ final readonly class ActivityACLAwareRepository implements ActivityACLAwareRepos } foreach ($person->getAccompanyingPeriodParticipations() as $participation) { - if (!$this->security->isGranted(ActivityVoter::SEE, $participation->getAccompanyingPeriod())) { + if (!$this->security->isGranted(AccompanyingPeriodVoter::SEE, $participation->getAccompanyingPeriod())) { continue; } diff --git a/src/Bundle/ChillAsideActivityBundle/src/DataFixtures/ORM/LoadAsideActivity.php b/src/Bundle/ChillAsideActivityBundle/src/DataFixtures/ORM/LoadAsideActivity.php index a60398507..cb778ab1e 100644 --- a/src/Bundle/ChillAsideActivityBundle/src/DataFixtures/ORM/LoadAsideActivity.php +++ b/src/Bundle/ChillAsideActivityBundle/src/DataFixtures/ORM/LoadAsideActivity.php @@ -21,7 +21,10 @@ use Doctrine\Persistence\ObjectManager; class LoadAsideActivity extends Fixture implements DependentFixtureInterface { - public function __construct(private readonly UserRepository $userRepository) {} + public function __construct(private readonly UserRepository $userRepository) + { + mt_srand(123456789); + } public function getDependencies(): array { @@ -47,7 +50,7 @@ class LoadAsideActivity extends Fixture implements DependentFixtureInterface $this->getReference('aside_activity_category_0', AsideActivityCategory::class) ) ->setDate((new \DateTimeImmutable('today')) - ->sub(new \DateInterval('P'.\random_int(1, 100).'D'))); + ->sub(new \DateInterval('P'.\mt_rand(1, 100).'D'))); $manager->persist($activity); } diff --git a/src/Bundle/ChillCalendarBundle/Resources/public/vuejs/MyCalendarRange/App2.vue b/src/Bundle/ChillCalendarBundle/Resources/public/vuejs/MyCalendarRange/App2.vue index 9b24611cf..952ab748f 100644 --- a/src/Bundle/ChillCalendarBundle/Resources/public/vuejs/MyCalendarRange/App2.vue +++ b/src/Bundle/ChillCalendarBundle/Resources/public/vuejs/MyCalendarRange/App2.vue @@ -1,193 +1,231 @@