Merge branch 'refs/heads/master' into ticket-app-master

# Conflicts:
#	composer.json
#	config/bundles.php
#	config/packages/doctrine_migrations_chill.yaml
#	package.json
#	src/Bundle/ChillMainBundle/DataFixtures/ORM/LoadUserGroup.php
#	src/Bundle/ChillMainBundle/DependencyInjection/ChillMainExtension.php
#	src/Bundle/ChillMainBundle/Entity/UserGroup.php
#	src/Bundle/ChillMainBundle/Resources/public/chill/js/date.ts
#	src/Bundle/ChillMainBundle/Resources/public/lib/download-report/download-report.js
#	src/Bundle/ChillMainBundle/Resources/public/module/ckeditor5/editor_config.ts
#	src/Bundle/ChillMainBundle/Resources/public/module/ckeditor5/index.ts
#	src/Bundle/ChillMainBundle/Resources/public/page/export/download-export.js
#	src/Bundle/ChillMainBundle/Resources/public/types.ts
#	src/Bundle/ChillMainBundle/Resources/views/Dev/dev.assets.html.twig
#	src/Bundle/ChillMainBundle/Templating/Entity/UserGroupRender.php
#	src/Bundle/ChillMainBundle/chill.api.specs.yaml
#	src/Bundle/ChillMainBundle/chill.webpack.config.js
#	src/Bundle/ChillPersonBundle/Resources/public/vuejs/AccompanyingCourse/components/Comment.vue
#	src/Bundle/ChillPersonBundle/Resources/public/vuejs/AccompanyingCourse/components/PersonsAssociated.vue
#	src/Bundle/ChillPersonBundle/Resources/public/vuejs/AccompanyingCourse/components/Resources.vue
#	src/Bundle/ChillPersonBundle/Resources/public/vuejs/AccompanyingCourse/components/Resources/WriteComment.vue
#	src/Bundle/ChillPersonBundle/Resources/public/vuejs/AccompanyingCourseWorkEdit/App.vue
#	src/Bundle/ChillPersonBundle/Resources/public/vuejs/AccompanyingCourseWorkEdit/components/FormEvaluation.vue
#	src/Bundle/ChillPersonBundle/Resources/public/vuejs/HouseholdMembersEditor/components/Household.vue
#	src/Bundle/ChillPersonBundle/Resources/public/vuejs/HouseholdMembersEditor/components/MemberDetails.vue
#	src/Bundle/ChillPersonBundle/Resources/public/vuejs/HouseholdMembersEditor/components/PersonComment.vue
#	src/Bundle/ChillPersonBundle/Resources/public/vuejs/_components/AddPersons.vue
#	src/Bundle/ChillPersonBundle/Resources/public/vuejs/_components/Entity/PersonRenderBox.vue
#	src/Bundle/ChillPersonBundle/Resources/public/vuejs/_components/Entity/PersonText.vue
#	src/Bundle/ChillPersonBundle/Resources/public/vuejs/_js/i18n.ts
#	tests/app/config/bootstrap.php
This commit is contained in:
Julien Fastré 2025-05-27 09:37:04 +02:00
commit 5f2711023e
Signed by: julienfastre
GPG Key ID: BDE2190974723FCB
1735 changed files with 82701 additions and 27873 deletions

View File

@ -0,0 +1,6 @@
kind: DX
body: Remove dead code for wopi-link module
time: 2025-04-30T14:45:50.406111606+02:00
custom:
Issue: "352"
SchemaChange: No schema change

View File

@ -1,5 +0,0 @@
kind: Feature
body: '[DX] move async-upload-bundle features into chill-bundles'
time: 2023-12-12T15:48:41.954970271+01:00
custom:
Issue: "221"

View File

@ -0,0 +1,7 @@
kind: Feature
body: Add the document file name to the document title when a user upload a document,
unless there is already a document title.
time: 2025-04-24T14:22:11.800975422+02:00
custom:
Issue: "377"
SchemaChange: No schema change

View File

@ -0,0 +1,6 @@
kind: Feature
body: Add desactivation date for social action and issue csv export
time: 2025-05-20T09:56:28.108941934+02:00
custom:
Issue: ""
SchemaChange: No schema change

View File

@ -1,6 +0,0 @@
kind: Fixed
body: Fix resolving of centers for an household, which will fix in turn the access
control
time: 2024-04-10T10:37:36.462484988+02:00
custom:
Issue: ""

View File

@ -0,0 +1,7 @@
kind: Fixed
body: trying to prevent bug of typeerror in doc-history + improved display of document
history
time: 2025-04-24T13:39:43.878468232+02:00
custom:
Issue: "376"
SchemaChange: No schema change

View File

@ -0,0 +1,7 @@
kind: Fixed
body: Display previous participation in acc course work even if the person has left
the acc course
time: 2025-04-24T16:37:46.970203594+02:00
custom:
Issue: "381"
SchemaChange: No schema change

View File

@ -0,0 +1,6 @@
kind: Fixed
body: Fix display of text in calendar events
time: 2025-05-05T10:27:15.461493066+02:00
custom:
Issue: "372"
SchemaChange: No schema change

View File

@ -0,0 +1,6 @@
kind: Fixed
body: Add missing translation for user_group.no_user_groups
time: 2025-05-14T14:53:39.53927329+02:00
custom:
Issue: ""
SchemaChange: No schema change

View File

@ -0,0 +1,6 @@
kind: UX
body: Remove default filter in_progress for the page 'my tasks'; Allows for new tasks to be displayed upon opening of the page
time: 2025-04-23T17:26:24.45777387+02:00
custom:
Issue: "374"
SchemaChange: No schema change

21
.changes/v2.20.0.md Normal file
View File

@ -0,0 +1,21 @@
## v2.20.0 - 2024-06-05
### Fixed
* ([#170](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/170)) Display agents traitants instead of accompanying period referrer in export list social actions.
* Added translations for choices of durations (> 5 hours)
### Feature
* ([#145](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/145)) Allow to open documents in LibreOffice locally (need configuration within security);
This endpoint should be added to make the endpoint works properly:
```yaml
security:
firewalls:
dav:
pattern: ^/dav
provider: chain_provider
stateless: true
guard:
authenticators:
- Chill\DocStoreBundle\Security\Guard\JWTOnDavUrlAuthenticator
```

3
.changes/v2.20.1.md Normal file
View File

@ -0,0 +1,3 @@
## v2.20.1 - 2024-06-05
### Fixed
* Do not allow StoredObjectCreated for edit and convert buttons

31
.changes/v2.21.0.md Normal file
View File

@ -0,0 +1,31 @@
## v2.21.0 - 2024-06-18
### Feature
* Add flash menu buttons in search results, to open directly a new calendar, or a new activity in an accompanying period
* ([#122](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/122)) Improve the list of calendar in the search results: make all calendar clicable, and display a list of calendars
* ([#282](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/282)) [export] add start date and end date on filters "filter course by referrer job" and "filter course by referrer scope"
* ([#282](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/282)) [export] the aggregator "Group by referrer" now accept a date range.
* ([#282](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/282)) [export] add date range on "group course by referrer's scope"
* ([#282](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/282)) [export] add date range on "group course by referrer's jobs"
* ([#168](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/168) In the UX, display user job and service at the time when he performs an action:
now, the job and service is shown:
* at the activity's date,
* at the appointment's date,
* when the user is marked as referrer for an accompanying period work,
* when the user apply a transition in a workflow,
* when the user updates or creates "something" ("created/updated by ... at ..."),
* or when he wrote a comment,
* …
### Traduction francophone
* Ajout d'un menu "flash" dans les résultats de recherche, pour créer un rendez-vous ou un échange dans un parcours depuis les résultats de recherche;
* Améliore la liste des rendez-vous dans les résultats de recherche: les rendez-vous sont cliquables;
* [exports] Ajout d'intervalles de dates pour des filtres et regroupements des parcours par référent, métier du référent, service du référent;
* Affiche le métier et le service des utilisateurs à la date à laquelle il a exécuté une action. Le métier et le service est affiché:
* à la date d'un échange,
* au jour d'un rendez-vous,
* quand l'utilisateur est devenu référent d'un parcours d'accompagnement,
* quand il a appliqué une transition sur un workflow,
* quand il a mise à jour ou créé une fiche, dans les mentions "créé / mise à jour par ..., le ...",
* quand il a mis à jour un commentaire,
* …

6
.changes/v2.22.0.md Normal file
View File

@ -0,0 +1,6 @@
## v2.22.0 - 2024-06-25
### Feature
* ([#216](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/216)) [event bundle] exports added for the event module
### Traduction francophone
* Exports sont ajoutés pour la module événement.

5
.changes/v2.22.1.md Normal file
View File

@ -0,0 +1,5 @@
## v2.22.1 - 2024-07-01
### Fixed
* Remove debug word
### DX
* Add a command for reading official address DB from Luxembourg and update chill addresses

3
.changes/v2.22.2.md Normal file
View File

@ -0,0 +1,3 @@
## v2.22.2 - 2024-07-03
### Fixed
* Remove scope required for event participation stats

30
.changes/v2.23.0.md Normal file
View File

@ -0,0 +1,30 @@
## v2.23.0 - 2024-07-23 & 2024-07-19
### Feature
* ([#221](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/221)) [DX] move async-upload-bundle features into chill-bundles
* Add job bundle (module emploi)
* Upgrade import of address list to the last version of compiled addresses of belgian-best-address
* Upgrade CKEditor and refactor configuration with use of typescript
* ([#123](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/123)) Add a button to duplicate calendar ranges from a week to another one
* [admin] filter users by active / inactive in the admin user's list
* ([#273](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/273)) Add the possibility to mark all notifications as read
* Handle duplicate reference id in the import of reference addresses
* Do not update the "createdAt" column when importing postal code which does not change
* Display filename on file upload within the UI interface
### Fixed
* Fix resolving of centers for an household, which will fix in turn the access control
* Resolved type hinting error in activity list export
* ([#271](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/271)) Take into account the acp closing date in the acp works date filter
### Traduction française des principaux changements
- Ajout d'un bouton pour dupliquer les périodes de disponibilités d'une semaine à une autre;
- dans l'interface d'administration, filtre sur les utilisateurs actifs. Par défaut, seul les utilisateurs
actifs sont affichés;
- Nouveau bouton pour indiquer toutes les notifications comme lues;
- Améliorations sur l'import des adresses et des codes postaux;
- Affiche le nom du fichier déposé quand on téléverse un fichier depuis le poste de travail local;
- Agrandit l'icône du type de fichier dans l'interface de dépôt de fichier;
- correction: tient compte de la date de fermeture du parcours dans les filtres sur les actions d'accompagnement.

3
.changes/v2.24.0.md Normal file
View File

@ -0,0 +1,3 @@
## v2.24.0 - 2024-09-11
### Feature
* ([#306](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/306)) When a document is converted or downloaded in the browser, this document is removed from the browser memory after 45s. Future click on the button re-download the document.

5
.changes/v3.0.0.md Normal file
View File

@ -0,0 +1,5 @@
## v3.0.0 - 2024-08-26
### Fixed
* Fix delete action for accompanying periods in draft state
* Fix connection to azure when making an calendar event in chill
* CollectionType js fixes for remove button and adding multiple entries

3
.changes/v3.1.0.md Normal file
View File

@ -0,0 +1,3 @@
## v3.1.0 - 2024-08-30
### Feature
* Add export aggregator to aggregate activities by household + filter persons that are not part of an accompanyingperiod during a certain timeframe.

6
.changes/v3.1.1.md Normal file
View File

@ -0,0 +1,6 @@
## v3.1.1 - 2024-10-01
### Fixed
* ([#308](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/308)) Show only the current referrer in the page "show" for an accompanying period workf
* ([#309](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/309)) Correctly compute the grouping by referrer aggregator
* Fixed typing of custom field long choice and custom field group

6
.changes/v3.10.0.md Normal file
View File

@ -0,0 +1,6 @@
## v3.10.0 - 2025-03-17
### Feature
* ([#363](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/363)) Display social actions grouped per social issue within activity form
### Fixed
* ([#362](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/362)) Fix Dependency Injection, which prevented to save the CalendarRange
* ([#368](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/368)) fix search query for user groups

3
.changes/v3.10.1.md Normal file
View File

@ -0,0 +1,3 @@
## v3.10.1 - 2025-03-17
### DX
* Remove yarn dependency to symfony/ux-translator, to ease the build process

3
.changes/v3.10.2.md Normal file
View File

@ -0,0 +1,3 @@
## v3.10.2 - 2025-03-17
### Fixed
* Replace a ts-expect-error with a ts-ignore

3
.changes/v3.10.3.md Normal file
View File

@ -0,0 +1,3 @@
## v3.10.3 - 2025-03-18
### DX
* Eslint fixes

19
.changes/v3.11.0.md Normal file
View File

@ -0,0 +1,19 @@
## v3.11.0 - 2025-04-17
### Feature
* ([#365](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/365)) Add counters of actions and activities, with 2 boxes to (1) show the number of active actions on total actions and (2) show the number of activities in a accompanying period, and pills in menus for showing the number of active actions and the number of activities.
* ([#364](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/364)) Added a second phone number "telephone2" to the thirdParty entity. Adapted twig templates and vuejs apps to handle this phone number
**Schema Change**: Add columns or tables
* Signature: add a button to go directly to the signature zone, even if there is only one
### Fixed
* Fixed wrong translations in the on-the-fly for creation of thirdParty
* Fixed update of phone number in on-the-fly edition of thirdParty
* Fixed closing of modal when editing thirdParty in accompanying course works
* Shorten the delay between two execution of AccompanyingPeriodStepChangeCronjob, to ensure at least one execution in a day
* ([#102](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/102)) Fix display of title in document list
* When cleaning the old stored object versions, do not throw an error if the stored object is not found on disk
* Add consistent log prefix and key to logs when stale workflows are automatically canceled
* ([#380](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/380)) Remove the "not null" validation constraint on recently added properties on HouseholdComposition
### DX
* Add new chill-col style for displaying title and aside in a flex table

3
.changes/v3.2.0.md Normal file
View File

@ -0,0 +1,3 @@
## v3.2.0 - 2024-10-30
### Feature
* Introduce a gender entity

4
.changes/v3.2.1.md Normal file
View File

@ -0,0 +1,4 @@
## v3.2.1 - 2024-10-31
### Fixed
* Add the possibility of unknown to the gender entity
* Fix the fusion of person doubles by excluding accompanyingPeriod work entities to be deleted. They are moved instead.

3
.changes/v3.2.2.md Normal file
View File

@ -0,0 +1,3 @@
## v3.2.2 - 2024-10-31
### Fixed
* Fix gender translation for unknown

4
.changes/v3.2.3.md Normal file
View File

@ -0,0 +1,4 @@
## v3.2.3 - 2024-11-05
### Fixed
* ([#315](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/315)) Fix display of accompanying period work referrers. Only current referrers should be displayed.
Fix color of Chill footer

3
.changes/v3.2.4.md Normal file
View File

@ -0,0 +1,3 @@
## v3.2.4 - 2024-11-06
### Fixed
* Fix compilation of chill assets

13
.changes/v3.3.0.md Normal file
View File

@ -0,0 +1,13 @@
## v3.3.0 - 2024-11-20
### Feature
* Electronic signature
Implementation of the electronic signature for documents within chill.
* ([#286](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/286)) The behavoir of the voters for stored objects is adjusted so as to limit edit and delete possibilities to users related to the activity, social action or workflow entity.
* ([#288](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/288)) Metadata form added for person signatures
* Add a signature step in workflow, which allow to apply an electronic signature on documents
* Keep an history of each version of a stored object.
* Add a "send external" step in workflow, which allow to send stored objects and other elements to remote people, by sending them a public url
### Fixed
* Adjust household list export to include households even if their address is NULL
* Remove validation of date string on deathDate

4
.changes/v3.4.0.md Normal file
View File

@ -0,0 +1,4 @@
## v3.4.0 - 2024-11-20
### Feature
* ([#314](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/314)) Admin: improve document type admin form with a select field for related class.
Admin: Allow administrator to assign multiple group centers in one go to a user.

3
.changes/v3.4.1.md Normal file
View File

@ -0,0 +1,3 @@
## v3.4.1 - 2024-11-22
### Fixed
* Set the workflow's title to notification content and subject

6
.changes/v3.4.2.md Normal file
View File

@ -0,0 +1,6 @@
## v3.4.2 - 2024-12-05
### Fixed
* ([#329](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/329)) Fix the serialization of gender for the generation of documents
* ([#337](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/337)) Enforce unique contraint on activity storedobject
### DX
* ([#310](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/310)) Clean migrations, to reduce the number of bloated migration when running diff on schema

4
.changes/v3.4.3.md Normal file
View File

@ -0,0 +1,4 @@
## v3.4.3 - 2024-12-05
### Fixed
* Remove the "not null" constraint on person supplementary phones
* Remove doctrine annotation that prevent from adding documents to activities

6
.changes/v3.5.0.md Normal file
View File

@ -0,0 +1,6 @@
## v3.5.0 - 2024-12-09
### Feature
* ([#318](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/318)) Show all the pages of the documents in the signature app
### Fixed
* Wrap the signature's change state into a transaction, to avoid race conditions
* Fix display of gender label

4
.changes/v3.5.1.md Normal file
View File

@ -0,0 +1,4 @@
## v3.5.1 - 2024-12-16
### Fixed
* Filiation: fix the display of the gender label in the graph
* Wrap handling of PdfSignedMessage into transactions

3
.changes/v3.5.2.md Normal file
View File

@ -0,0 +1,3 @@
## v3.5.2 - 2024-12-19
### Fixed
* ([#345](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/345)) Export: activity filtering of users that were associated to an activity between certain dates. Results contained activities that were not within the specified date range"

3
.changes/v3.5.3.md Normal file
View File

@ -0,0 +1,3 @@
## v3.5.3 - 2025-01-07
### Fixed
* Fix the EntityToJsonTransformer to return an empty array if the value is ""

9
.changes/v3.6.0.md Normal file
View File

@ -0,0 +1,9 @@
## v3.6.0 - 2025-01-16
### Feature
* Importer for addresses does not fails when the postal code is not found with some addresses, and compute a recap list of all addresses that could not be imported. This recap list can be send by email.
* ([#346](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/346)) Create a driver for storing documents on disk (instead of openstack object store)
* Add address importer from french Base d'Adresse Nationale (BAN)
* ([#343](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/343)) Add csv export for social issues and social actions
### Fixed
* Export: fix missing alias in activity between certain dates filter. Condition added for alias.

62
.changes/v3.7.0.md Normal file
View File

@ -0,0 +1,62 @@
## v3.7.0 - 2025-01-21
### Feature
* Use the Notifier component from Symfony to sens short messages (SMS). This allow to use more provider.
### Fixed
* ([#348](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/348)) [export] Fix aggregation of referrer's scope and job: fix the date range comparison
### Warning on configuration of Notifier component
If installed in an symfony app where the recipes are activated, this configuration should be added automatically:
```yaml
framework:
notifier:
chatter_transports:
texter_transports:
ovhcloud: '%env(OVHCLOUD_DSN)%'
channel_policy:
# use chat/slack, chat/telegram, sms/twilio or sms/nexmo
urgent: ['email']
high: ['email']
medium: ['email']
low: ['email']
admin_recipients:
- { email: admin@example.com }
```
Actually, you should either:
- remove the configuration of ovhcloud added by the recipe
- or remove the previous configuration of chill, to avoid keeping legacy configuration
#### Remove the added configuration and keep the legacy configuration
To remove the configuration:
```diff
framework:
notifier:
chatter_transports:
texter_transports:
- ovhcloud: '%env(OVHCLOUD_DSN)%'
```
In that case, the previous configuration, which was stored under the `chill_main.short_messages.dsn` will be reconfigured into the Notifier component's configuration.
#### Properly configure SMS
You can also properly configure it, as [described in the OVH cloud provider repository](https://github.com/symfony/ovh-cloud-notifier/tree/5.4?tab=readme-ov-file#dsn-example) (where the scheme is `ovhcloud`):
**NOTE**: You have access to all notifier available with the [Notifier component](https://symfony.com/doc/current/notifier.html#notifier-sms-channel). You are not restricted to use OVH as a provider.
```diff
framework:
notifier:
chatter_transports:
texter_transports:
+ ovhcloud: '%env(OVHCLOUD_DSN)%' # this value should be located in a variable, and have `ovhcloud://` as a scheme
chill_main:
- short_messages:
- dsn: '%env(string:SHORT_MESSAGE_DSN)%'
```

3
.changes/v3.7.1.md Normal file
View File

@ -0,0 +1,3 @@
## v3.7.1 - 2025-01-21
### Fixed
* Fix legacy configuration processor for notifier component

11
.changes/v3.8.0.md Normal file
View File

@ -0,0 +1,11 @@
## v3.8.0 - 2025-02-03
### Feature
* Improve the UX of the news item admin form to prevent wrong usage
* ([#319](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/319)) Notification list: display the concerned person's badges in the list
* ([#320](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/320)) Show the first 3 persons directly in the accompanying period's banner
* ([#334](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/334)) Suggest current user when creating an activity
* ([#331](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/331)) Add attachments to workflows
### Fixed
* ([#350](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/350)) Add validation error to manual selection of person in PersonDuplicateController
* ([#354](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/354)) Fix document category creation
* ([#351](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/351)) Add definitive whitespace between span elements in vue PersonText component

3
.changes/v3.8.1.md Normal file
View File

@ -0,0 +1,3 @@
## v3.8.1 - 2025-02-05
### Fixed
* Fix household link in the parcours banner

3
.changes/v3.8.2.md Normal file
View File

@ -0,0 +1,3 @@
## v3.8.2 - 2025-02-10
### Fixed
* ([#358](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/358)) Remove "filter" button on list of documents in the workflow's "add attachement" modal

10
.changes/v3.9.0.md Normal file
View File

@ -0,0 +1,10 @@
## v3.9.0 - 2025-02-27
### Feature
* ([#349](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/349)) Suggest all referrers within actions of the accompanying period when creating an activity
* ([#343](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/343)) Add possibility to export a csv with all social issues and social actions
* ([#360](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/360)) Restore document to previous kept version when a workflow is canceled
* ([#341](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/341)) Add a list of third parties from within the admin (csv download)
### Fixed
* fix generation of document with accompanying period context, and list of activities and works
### DX
* ([#333](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/333)) Create an unique source of trust for translations

3
.changes/v3.9.1.md Normal file
View File

@ -0,0 +1,3 @@
## v3.9.1 - 2025-02-27
### Fixed
* Fix post/patch request with missing 'type' property for gender

3
.changes/v3.9.2.md Normal file
View File

@ -0,0 +1,3 @@
## v3.9.2 - 2025-02-27
### Fixed
* Use fetchResults method to fetch all social issues instead of only the first page

View File

@ -7,15 +7,29 @@ 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.Long) (not (eq .Custom.Long "")) }}
* {{ 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") }}
**Schema Change**: {{ .Custom.SchemaChange }}
{{- end -}}
{{ if and (.Custom.Long) (not (eq .Custom.Long "")) }}{{ .Custom.Long }}{{ end }}
{{ .Custom.Long }}{{ end }}
custom:
- key: SchemaChange
label: Is a schema change required?
optional: false
type: enum
enumOptions:
- "No schema change"
- "Add columns or tables"
- "Drop or rename table or columns, or enforce new constraint that must be manually fixed"
- key: Issue
label: Issue number (on chill-bundles repository) (optional)
optional: true
type: int
minInt: 1
body:
# allow multiline messages
block: true

98
.env
View File

@ -11,19 +11,13 @@
# Run "composer dump-env prod" to compile .env files for production use (requires symfony/flex >=1.2).
# https://symfony.com/doc/current/best_practices.html#use-environment-variables-for-infrastructure-configuration
## Locale
LOCALE=fr
###> symfony/framework-bundle ###
# this should be set in docker-compose.yml file
APP_ENV=prod
APP_SECRET=ChangeItf2b58287ef7f9976409d3f6c72529e99ChangeIt
TRUSTED_PROXIES=127.0.0.0/8,10.0.0.0/8,172.16.0.0/12,192.168.0.0/16
TRUSTED_HOSTS='^(localhost|example\.com|nginx)$'
APP_SECRET=!ChangeMeInAppEnv!
###< symfony/framework-bundle ###
## Wopi server for editing documents online
WOPI_SERVER=http://collabora:9980
EDITOR_SERVER=http://collabora:9980
# must be manually set in .env.local
# ADMIN_PASSWORD=
@ -32,52 +26,14 @@ WOPI_SERVER=http://collabora:9980
# MAILER_DSN=null://null
###< symfony/mailer ###
## Notifications
NOTIFICATION_HOST=localhost:8001
NOTIFICATION_FROM_EMAIL=admin@chill.social
NOTIFICATION_FROM_NAME="Chill <admin@chill.social>"
## Pgadmin credential
PGADMIN_DEFAULT_EMAIL=
PGADMIN_DEFAULT_PASSWORD=
## OVH OpenStack Storage Container
ASYNC_UPLOAD_TEMP_URL_KEY=
ASYNC_UPLOAD_TEMP_URL_BASE_PATH=
ASYNC_UPLOAD_TEMP_URL_CONTAINER=
## Redis Cache
REDIS_HOST=redis
REDIS_PORT=6379
REDIS_URL=redis://${REDIS_HOST}:${REDIS_PORT}
## Twilio
TWILIO_SID=~
TWILIO_SECRET=~
DEFAULT_CARRIER_CODE=BE
ADD_ADDRESS_DEFAULT_COUNTRY=BE
ADD_ADDRESS_MAP_CENTER_X=50.8443
ADD_ADDRESS_MAP_CENTER_Y=4.3523
ADD_ADDRESS_MAP_CENTER_Z=15
SHORT_MESSAGE_DSN=null://null
## DOCKER IMAGES REGISTRY
#IMAGE_PHP=
#IMAGE_NGINX=
## DOCKER IMAGES TAG
#VERSION=test
#VERSION=prod
###> symfony/messenger ###
# Choose one of the transports below
# MESSENGER_TRANSPORT_DSN=amqp://guest:guest@localhost:5672/%2f/messages
# MESSENGER_TRANSPORT_DSN=redis://localhost:6379/messages
MESSENGER_TRANSPORT_DSN=sync://
MESSENGER_TRANSPORT_DSN=doctrine://default?auto_setup=0
# MESSENGER_TRANSPORT_DSN=sync://
# MESSENGER_TRANSPORT_DSN=doctrine://default?auto_setup=0
MESSENGER_TRANSPORT_DSN=${RABBITMQ_URL}/%2f
###< symfony/messenger ###
###> doctrine/doctrine-bundle ###
@ -92,3 +48,47 @@ JWT_SECRET_KEY=%kernel.project_dir%/config/jwt/private.pem
JWT_PUBLIC_KEY=%kernel.project_dir%/config/jwt/public.pem
JWT_PASSPHRASE=2a30f6ba26521a2613821da35f28386e
###< lexik/jwt-authentication-bundle ###
###> chill-project/chill-bundles ###
# Generate a password using `symfony console security:hash-password --empty-salt <password> 'Symfony\Component\Security\Core\User\User'` and paste it into .env.local file
# ADMIN_PASSWORD=
# Add a configuration for sending SMS (before calendar appointments, aka "Rendez-vous"). See https://symfony.com/doc/current/notifier.html#sms-channel
# Configuration for using ovh custom notifier
# SHORT_MESSAGE_DSN="ovh://user:password@ovh-eu?consumer_key=123456&sender=%2B32475123456&service_name=sms-xx123456-1"
SHORT_MESSAGE_DSN=null://null
# Default locale for the project
LOCALE=fr
# Those keys are required to configure the access to store documents
ASYNC_UPLOAD_TEMP_URL_KEY=
ASYNC_UPLOAD_TEMP_URL_BASE_PATH=
ASYNC_UPLOAD_TEMP_URL_CONTAINER=
# Twilio configuration, to check for the existence of phonenumber in a directory (may be deprecated in a near future)
TWILIO_SID=
TWILIO_SECRET=
# Default carrier code will replace all leading zero by an international code. Set here the country as two letters
DEFAULT_CARRIER_CODE=FR
# Configuration for the notification emails
NOTIFICATION_FROM_EMAIL=chill@instance.com
NOTIFICATION_FROM_NAME=Chill
# Will set the default host when sending email from command or services (see https://symfony.com/doc/5.x/routing.html#generating-urls-in-commands)
NOTIFICATION_HOST=my.chill.social
# Variables for relatorio host, which generates documents
RELATORIO_HOST=
RELATORIO_PORT=
# Address for your collabora server
#EDITOR_SERVER=https://code.example.com
EDITOR_SERVER=https://collabora.champs-libres.be
# center address widget when empty
ADD_ADDRESS_DEFAULT_COUNTRY=BE
ADD_ADDRESS_MAP_CENTER_X=50.8443
ADD_ADDRESS_MAP_CENTER_Y=4.3523
ADD_ADDRESS_MAP_CENTER_Z=15
## Redis Cache & redis database
REDIS_HOST=redis
REDIS_PORT=6379
REDIS_URL=redis://${REDIS_HOST}:${REDIS_PORT}
###< chill-project/chill-bundles ###
###> symfony/ovh-cloud-notifier ###
# OVHCLOUD_DSN=ovhcloud://APPLICATION_KEY:APPLICATION_SECRET@default?consumer_key=CONSUMER_KEY&service_name=SERVICE_NAME
###< symfony/ovh-cloud-notifier ###

View File

@ -4,15 +4,8 @@
KERNEL_CLASS='App\Kernel'
APP_SECRET='$ecretf0rt3st'
TRUSTED_HOSTS=
ADMIN_PASSWORD=password
LOCALE=fr
REDIS_URL=redis
REDIS_PORT=6379
REDIS_URL=redis://${REDIS_HOST}:${REDIS_PORT}
JWT_SECRET_KEY=%kernel.project_dir%/config/jwt/private.pem
JWT_PUBLIC_KEY=%kernel.project_dir%/config/jwt/public.pem
JWT_PASSPHRASE=2a30f6ba26521a2613821da35f28386e
@ -22,22 +15,25 @@ TWILIO_SECRET=~
DEFAULT_CARRIER_CODE=BE
ADD_ADDRESS_DEFAULT_COUNTRY=BE
ADD_ADDRESS_MAP_CENTER_X=50.8443
ADD_ADDRESS_MAP_CENTER_Y=4.3523
ADD_ADDRESS_MAP_CENTER_Z=15
SHORT_MESSAGE_DSN=null://null
MESSENGER_TRANSPORT_DSN=sync://
###< symfony/messenger ###
###> doctrine/doctrine-bundle ###
# Format described at https://www.doctrine-project.org/projects/doctrine-dbal/en/latest/reference/configuration.html#connecting-using-a-url
# IMPORTANT: You MUST configure your server version, either here or in config/packages/doctrine.yaml
#
DATABASE_URL="postgresql://postgres:postgres@db:5432/test?serverVersion=14&charset=utf8"
DATABASE_URL="postgresql://app:!ChangeMe!@127.0.0.1:5454/test?serverVersion=14&charset=utf8"
###< doctrine/doctrine-bundle ###
ASYNC_UPLOAD_TEMP_URL_KEY=
ASYNC_UPLOAD_TEMP_URL_BASE_PATH=
ASYNC_UPLOAD_TEMP_URL_CONTAINER=
MAILER_DSN=null://null
REDIS_HOST=127.0.0.1
REDIS_PORT=6363

2386
.eslint-baseline.json Normal file

File diff suppressed because it is too large Load Diff

37
.gitignore vendored
View File

@ -3,9 +3,20 @@ composer
composer.phar
composer.lock
docs/build/
node_modules/*
.php_cs.cache
.cache/*
yarn.lock
docker/db/data
docker/rabbitmq/data
# in this development bundle, we want to ignore directories related to a real app
assets/*
!assets/translator.ts
!assets/ux-translator
migrations/*
templates/*
translations/*
###> symfony/framework-bundle ###
/.env.local
@ -15,7 +26,6 @@ node_modules/*
/public/bundles/
/var/
/vendor/
/bin/
###< symfony/framework-bundle ###
###> phpunit/phpunit ###
@ -27,4 +37,25 @@ node_modules/*
/.idea/
/.psalm/
node_modules/*
###> phpstan/phpstan ###
phpstan.neon
###< phpstan/phpstan ###
###> lexik/jwt-authentication-bundle ###
/config/jwt/*.pem
###< lexik/jwt-authentication-bundle ###
###> symfony/phpunit-bridge ###
###< symfony/phpunit-bridge ###
###> symfony/webpack-encore-bundle ###
/node_modules/
/public/build/
npm-debug.log
yarn-error.log
###< symfony/webpack-encore-bundle ###
###> friendsofphp/php-cs-fixer ###
/.php-cs-fixer.php
/.php-cs-fixer.cache
###< friendsofphp/php-cs-fixer ###

View File

@ -5,11 +5,12 @@ cache:
paths:
- /vendor/
- .cache
- node_modules/
# Bring in any services we need http://docs.gitlab.com/ee/ci/docker/using_docker_images.html#what-is-a-service
# See http://docs.gitlab.com/ee/ci/services/README.html for examples.
services:
- name: postgis/postgis:14-3.3-alpine
- name: postgis/postgis:17-3.5-alpine
alias: db
command:
- postgres
@ -26,7 +27,7 @@ variables:
POSTGRES_USER: postgres
POSTGRES_PASSWORD: postgres
# configure database access
DATABASE_URL: postgresql://postgres:postgres@db:5432/postgres?serverVersion=14&charset=utf8
DATABASE_URL: postgresql://postgres:postgres@db:5432/postgres?serverVersion=17&charset=utf8
# fetch the chill-app using git submodules
# GIT_SUBMODULE_STRATEGY: recursive
REDIS_HOST: redis
@ -56,7 +57,6 @@ build:
artifacts:
expire_in: 1 day
paths:
- bin
- vendor/
code_style:
@ -70,38 +70,54 @@ code_style:
artifacts:
expire_in: 1 day
paths:
- bin
- vendor/
phpstan_tests:
stage: Tests
image: gitea.champs-libres.be/chill-project/chill-skeleton-basic/base-image:php82
variables:
COMPOSER_MEMORY_LIMIT: 3G
before_script:
- bin/console cache:clear --env=dev
script:
- bin/phpstan analyze --memory-limit=2G
- composer exec phpstan -- analyze --memory-limit=3G
cache:
paths:
- .cache/
artifacts:
expire_in: 1 day
paths:
- bin
- vendor/
rector_tests:
stage: Tests
image: gitea.champs-libres.be/chill-project/chill-skeleton-basic/base-image:php82
before_script:
- bin/console cache:clear --env=dev
script:
- tests/console cache:clear
- bin/rector process --dry-run
- composer exec rector -- process --dry-run
cache:
paths:
- .cache/
artifacts:
expire_in: 1 day
paths:
- bin
- vendor/
lint:
stage: Tests
image: node:20-alpine
before_script:
- apk add --no-cache python3 make g++ py3-setuptools
- export PYTHON="$(which python3)"
- export PATH="./node_modules/.bin:$PATH"
script:
- yarn install --ignore-optional
- npx eslint-baseline "src/**/*.{js,ts,vue}"
cache:
paths:
- node_modules/
# psalm_tests:
# stage: Tests
# image: gitea.champs-libres.be/chill-project/chill-skeleton-basic/base-image:php82
@ -117,16 +133,19 @@ rector_tests:
unit_tests:
stage: Tests
image: gitea.champs-libres.be/chill-project/chill-skeleton-basic/base-image:php82
variables:
COMPOSER_MEMORY_LIMIT: 3G
before_script:
- php bin/console doctrine:database:create -n --env=test
- php bin/console doctrine:migrations:migrate -n --env=test
- php bin/console chill:db:sync-views --env=test
- php bin/console cache:clear --env=test
- php bin/console doctrine:fixtures:load -n --env=test
script:
- php tests/console doctrine:migrations:migrate -n --env=test
- php tests/console chill:db:sync-views --env=test
- php -d memory_limit=2G tests/console cache:clear --env=test
- php -d memory_limit=3G tests/console doctrine:fixtures:load -n --env=test
- php -d memory_limit=4G bin/phpunit --colors=never --exclude-group dbIntensive
- composer exec phpunit -- --colors=never --exclude-group dbIntensive,openstack-integration
artifacts:
expire_in: 1 day
paths:
- bin
- vendor/
release:
@ -138,4 +157,4 @@ release:
- echo "running release_job"
release:
tag_name: '$CI_COMMIT_TAG'
description: "./.changes/v$CI_COMMIT_TAG.md"
description: "./.changes/$CI_COMMIT_TAG.md"

1
.nvmrc Normal file
View File

@ -0,0 +1 @@
20

View File

@ -25,7 +25,7 @@ $config = new PhpCsFixer\Config();
$config
->setFinder($finder)
->setRiskyAllowed(true)
->setCacheFile('.cache/php-cs-fixer.cache')
->setCacheFile('var/php-cs-fixer.cache')
->setUsingCache(true)
->setParallelConfig(PhpCsFixer\Runner\Parallel\ParallelConfigFactory::detect())
;
@ -120,6 +120,6 @@ $rules = array_merge(
$untilFullSwitchToPhp8,
);
$rules['header_comment']['header'] = trim(file_get_contents(__DIR__.'/resource/header.txt'));
$rules['header_comment']['header'] = trim(file_get_contents(__DIR__.'/resources/header.txt'));
return $config->setRules($rules);

2
.symfony.local.yaml Normal file
View File

@ -0,0 +1,2 @@
workers:
docker_compose: ~

View File

@ -6,6 +6,345 @@ adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html),
and is generated by [Changie](https://github.com/miniscruff/changie).
## v3.10.3 - 2025-03-18
### DX
* Eslint fixes
## v3.10.2 - 2025-03-17
### Fixed
* Replace a ts-expect-error with a ts-ignore
## v3.10.1 - 2025-03-17
### DX
* Remove yarn dependency to symfony/ux-translator, to ease the build process
## v3.10.0 - 2025-03-17
### Feature
* ([#363](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/363)) Display social actions grouped per social issue within activity form
### Fixed
* ([#362](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/362)) Fix Dependency Injection, which prevented to save the CalendarRange
* ([#368](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/368)) fix search query for user groups
## v3.9.2 - 2025-02-27
### Fixed
* Use fetchResults method to fetch all social issues instead of only the first page
## v3.9.1 - 2025-02-27
### Fixed
* Fix post/patch request with missing 'type' property for gender
## v3.9.0 - 2025-02-27
### Feature
* ([#349](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/349)) Suggest all referrers within actions of the accompanying period when creating an activity
* ([#343](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/343)) Add possibility to export a csv with all social issues and social actions
* ([#360](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/360)) Restore document to previous kept version when a workflow is canceled
* ([#341](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/341)) Add a list of third parties from within the admin (csv download)
### Fixed
* fix generation of document with accompanying period context, and list of activities and works
### DX
* ([#333](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/333)) Create an unique source of trust for translations
## v3.8.2 - 2025-02-10
### Fixed
* ([#358](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/358)) Remove "filter" button on list of documents in the workflow's "add attachement" modal
## v3.8.1 - 2025-02-05
### Fixed
* Fix household link in the parcours banner
## v3.8.0 - 2025-02-03
### Feature
* Improve the UX of the news item admin form to prevent wrong usage
* ([#319](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/319)) Notification list: display the concerned person's badges in the list
* ([#320](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/320)) Show the first 3 persons directly in the accompanying period's banner
* ([#334](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/334)) Suggest current user when creating an activity
* ([#331](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/331)) Add attachments to workflows
### Fixed
* ([#350](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/350)) Add validation error to manual selection of person in PersonDuplicateController
* ([#354](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/354)) Fix document category creation
* ([#351](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/351)) Add definitive whitespace between span elements in vue PersonText component
## v3.7.1 - 2025-01-21
### Fixed
* Fix legacy configuration processor for notifier component
## v3.7.0 - 2025-01-21
### Feature
* Use the Notifier component from Symfony to sens short messages (SMS). This allow to use more provider.
### Fixed
* ([#348](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/348)) [export] Fix aggregation of referrer's scope and job: fix the date range comparison
### Warning on configuration of Notifier component
If installed in an symfony app where the recipes are activated, this configuration should be added automatically:
```yaml
framework:
notifier:
chatter_transports:
texter_transports:
ovhcloud: '%env(OVHCLOUD_DSN)%'
channel_policy:
# use chat/slack, chat/telegram, sms/twilio or sms/nexmo
urgent: ['email']
high: ['email']
medium: ['email']
low: ['email']
admin_recipients:
- { email: admin@example.com }
```
Actually, you should either:
- remove the configuration of ovhcloud added by the recipe
- or remove the previous configuration of chill, to avoid keeping legacy configuration
#### Remove the added configuration and keep the legacy configuration
To remove the configuration:
```diff
framework:
notifier:
chatter_transports:
texter_transports:
- ovhcloud: '%env(OVHCLOUD_DSN)%'
```
In that case, the previous configuration, which was stored under the `chill_main.short_messages.dsn` will be reconfigured into the Notifier component's configuration.
#### Properly configure SMS
You can also properly configure it, as [described in the OVH cloud provider repository](https://github.com/symfony/ovh-cloud-notifier/tree/5.4?tab=readme-ov-file#dsn-example) (where the scheme is `ovhcloud`):
**NOTE**: You have access to all notifier available with the [Notifier component](https://symfony.com/doc/current/notifier.html#notifier-sms-channel). You are not restricted to use OVH as a provider.
```diff
framework:
notifier:
chatter_transports:
texter_transports:
+ ovhcloud: '%env(OVHCLOUD_DSN)%' # this value should be located in a variable, and have `ovhcloud://` as a scheme
chill_main:
- short_messages:
- dsn: '%env(string:SHORT_MESSAGE_DSN)%'
```
## v3.6.0 - 2025-01-16
### Feature
* Importer for addresses does not fails when the postal code is not found with some addresses, and compute a recap list of all addresses that could not be imported. This recap list can be send by email.
* ([#346](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/346)) Create a driver for storing documents on disk (instead of openstack object store)
* Add address importer from french Base d'Adresse Nationale (BAN)
* ([#343](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/343)) Add csv export for social issues and social actions
### Fixed
* Export: fix missing alias in activity between certain dates filter. Condition added for alias.
## v3.5.3 - 2025-01-07
### Fixed
* Fix the EntityToJsonTransformer to return an empty array if the value is ""
## v3.5.2 - 2024-12-19
### Fixed
* ([#345](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/345)) Export: activity filtering of users that were associated to an activity between certain dates. Results contained activities that were not within the specified date range"
## v3.5.1 - 2024-12-16
### Fixed
* Filiation: fix the display of the gender label in the graph
* Wrap handling of PdfSignedMessage into transactions
## v3.5.0 - 2024-12-09
### Feature
* ([#318](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/318)) Show all the pages of the documents in the signature app
### Fixed
* Wrap the signature's change state into a transaction, to avoid race conditions
* Fix display of gender label
## v3.4.3 - 2024-12-05
### Fixed
* Remove the "not null" constraint on person supplementary phones
* Remove doctrine annotation that prevent from adding documents to activities
## v3.4.2 - 2024-12-05
### Fixed
* ([#329](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/329)) Fix the serialization of gender for the generation of documents
* ([#337](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/337)) Enforce unique contraint on activity storedobject
### DX
* ([#310](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/310)) Clean migrations, to reduce the number of bloated migration when running diff on schema
## v3.4.1 - 2024-11-22
### Fixed
* Set the workflow's title to notification content and subject
## v3.4.0 - 2024-11-20
### Feature
* ([#314](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/314)) Admin: improve document type admin form with a select field for related class.
Admin: Allow administrator to assign multiple group centers in one go to a user.
## v3.3.0 - 2024-11-20
### Feature
* Electronic signature
Implementation of the electronic signature for documents within chill.
* ([#286](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/286)) The behavoir of the voters for stored objects is adjusted so as to limit edit and delete possibilities to users related to the activity, social action or workflow entity.
* ([#288](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/288)) Metadata form added for person signatures
* Add a signature step in workflow, which allow to apply an electronic signature on documents
* Keep an history of each version of a stored object.
* Add a "send external" step in workflow, which allow to send stored objects and other elements to remote people, by sending them a public url
### Fixed
* Adjust household list export to include households even if their address is NULL
* Remove validation of date string on deathDate
## v3.2.4 - 2024-11-06
### Fixed
* Fix compilation of chill assets
## v3.2.3 - 2024-11-05
### Fixed
* ([#315](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/315)) Fix display of accompanying period work referrers. Only current referrers should be displayed.
Fix color of Chill footer
## v3.2.2 - 2024-10-31
### Fixed
* Fix gender translation for unknown
## v3.2.1 - 2024-10-31
### Fixed
* Add the possibility of unknown to the gender entity
* Fix the fusion of person doubles by excluding accompanyingPeriod work entities to be deleted. They are moved instead.
## v3.2.0 - 2024-10-30
### Feature
* Introduce a gender entity
## v3.1.1 - 2024-10-01
### Fixed
* ([#308](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/308)) Show only the current referrer in the page "show" for an accompanying period workf
* ([#309](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/309)) Correctly compute the grouping by referrer aggregator
* Fixed typing of custom field long choice and custom field group
## v3.1.0 - 2024-08-30
### Feature
* Add export aggregator to aggregate activities by household + filter persons that are not part of an accompanyingperiod during a certain timeframe.
## v3.0.0 - 2024-08-26
### Fixed
* Fix delete action for accompanying periods in draft state
* Fix connection to azure when making an calendar event in chill
* CollectionType js fixes for remove button and adding multiple entries
## v2.24.0 - 2024-09-11
### Feature
* ([#306](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/306)) When a document is converted or downloaded in the browser, this document is removed from the browser memory after 45s. Future click on the button re-download the document.
## v2.23.0 - 2024-07-23 & 2024-07-19
### Feature
* ([#221](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/221)) [DX] move async-upload-bundle features into chill-bundles
* Add job bundle (module emploi)
* Upgrade import of address list to the last version of compiled addresses of belgian-best-address
* Upgrade CKEditor and refactor configuration with use of typescript
* ([#123](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/123)) Add a button to duplicate calendar ranges from a week to another one
* [admin] filter users by active / inactive in the admin user's list
* ([#273](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/273)) Add the possibility to mark all notifications as read
* Handle duplicate reference id in the import of reference addresses
* Do not update the "createdAt" column when importing postal code which does not change
* Display filename on file upload within the UI interface
### Fixed
* Fix resolving of centers for an household, which will fix in turn the access control
* Resolved type hinting error in activity list export
* ([#271](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/271)) Take into account the acp closing date in the acp works date filter
### Traduction française des principaux changements
- Ajout d'un bouton pour dupliquer les périodes de disponibilités d'une semaine à une autre;
- dans l'interface d'administration, filtre sur les utilisateurs actifs. Par défaut, seul les utilisateurs
actifs sont affichés;
- Nouveau bouton pour indiquer toutes les notifications comme lues;
- Améliorations sur l'import des adresses et des codes postaux;
- Affiche le nom du fichier déposé quand on téléverse un fichier depuis le poste de travail local;
- Agrandit l'icône du type de fichier dans l'interface de dépôt de fichier;
- correction: tient compte de la date de fermeture du parcours dans les filtres sur les actions d'accompagnement.
## v2.22.2 - 2024-07-03
### Fixed
* Remove scope required for event participation stats
## v2.22.1 - 2024-07-01
### Fixed
* Remove debug word
### DX
* Add a command for reading official address DB from Luxembourg and update chill addresses
## v2.22.0 - 2024-06-25
### Feature
* ([#216](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/216)) [event bundle] exports added for the event module
### Traduction francophone
* Exports sont ajoutés pour la module événement.
## v2.21.0 - 2024-06-18
### Feature
* Add flash menu buttons in search results, to open directly a new calendar, or a new activity in an accompanying period
* ([#122](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/122)) Improve the list of calendar in the search results: make all calendar clicable, and display a list of calendars
* ([#282](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/282)) [export] add start date and end date on filters "filter course by referrer job" and "filter course by referrer scope"
* ([#282](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/282)) [export] the aggregator "Group by referrer" now accept a date range.
* ([#282](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/282)) [export] add date range on "group course by referrer's scope"
* ([#282](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/282)) [export] add date range on "group course by referrer's jobs"
* ([#168](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/168) In the UX, display user job and service at the time when he performs an action:
now, the job and service is shown:
* at the activity's date,
* at the appointment's date,
* when the user is marked as referrer for an accompanying period work,
* when the user apply a transition in a workflow,
* when the user updates or creates "something" ("created/updated by ... at ..."),
* or when he wrote a comment,
* …
### Traduction francophone
* Ajout d'un menu "flash" dans les résultats de recherche, pour créer un rendez-vous ou un échange dans un parcours depuis les résultats de recherche;
* Améliore la liste des rendez-vous dans les résultats de recherche: les rendez-vous sont cliquables;
* [exports] Ajout d'intervalles de dates pour des filtres et regroupements des parcours par référent, métier du référent, service du référent;
* Affiche le métier et le service des utilisateurs à la date à laquelle il a exécuté une action. Le métier et le service est affiché:
* à la date d'un échange,
* au jour d'un rendez-vous,
* quand l'utilisateur est devenu référent d'un parcours d'accompagnement,
* quand il a appliqué une transition sur un workflow,
* quand il a mise à jour ou créé une fiche, dans les mentions "créé / mise à jour par ..., le ...",
* quand il a mis à jour un commentaire,
* …
## v2.20.1 - 2024-06-05
### Fixed
* Do not allow StoredObjectCreated for edit and convert buttons
## v2.20.0 - 2024-06-05
### Fixed
* ([#170](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/170)) Display agents traitants instead of accompanying period referrer in export list social actions.
* Added translations for choices of durations (> 5 hours)
### Feature
* ([#145](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/145)) Allow to open documents in LibreOffice locally (need configuration within security);
This endpoint should be added to make the endpoint works properly:
```yaml
security:
firewalls:
dav:
pattern: ^/dav
provider: chain_provider
stateless: true
guard:
authenticators:
- Chill\DocStoreBundle\Security\Guard\JWTOnDavUrlAuthenticator
```
## v2.19.0 - 2024-05-14
### Feature
* ([#197](https://gitlab.com/Chill-Projet/chill-bundles/-/issues/197)) Make the script which subscribe to microsoft calendars changes more tolerant to errors or missing configuration on the microsoft side

386
CONVENTIONS-en.md Normal file
View File

@ -0,0 +1,386 @@
# Chill Conventions
In Progress
## Translations
Per bundle, all translations for Twig pages are located in a single file: translations/messages.fr.yaml.
## File Locations
Controllers, form types, and Twig templates are placed in the root folders Controller, Form, and Resources/views, respectively.
Admin pages are no longer placed in subfolders under Admin.
## Assets: Entrypoint Naming
There are three types of entry points:
* Vue application-specific (often for a single page): Prefixed with vue_.
* Reusable JavaScript/CSS code:
Examples include:
* ckeditor
* async_upload (used for forms)
* bootstrap
* chill.js
* ...
=> We prefix with `mod_`
* Page-specific CSS/JS:
* Often reuses functionalities like ShowHide.
=> We prefix with `page_`.
## Folder Structure
````
# Under Resources/public:
- chill/ => Contains the theme (Chill).
- chillmain.scss: Compiled into the chill entrypoint.
- lib/ => Libraries never used as entrypoints but reused elsewhere.
- Examples: ShowHide, Collection, Select2.
- module/: Ends up in reusable entrypoints (mod_).
- bootstrap
- custom.scss
- custom/
- variable.scss
- ...
- AsyncUpload.
- vue/ => Vue applications only (vue_).
- Examples: _components, app.
- page/ => Page-specific assets (page_).
- login
- person
- personvendee
- household_edit_metadata
- index.js
````
# Stylesheet Organization
1. The mod_bootstrap (module bootstrap) entry point is the first level. All parts (modules) of bootstrap are included in the bootstrap.js file located in ChillMainBundle/Resources/public/module/bootstrap.
* At the beginning, this file imports the variables.scss file, which determines most of the bootstrap settings as customized. This file overrides the original, and many variables are adjusted for Chill.
* Care must be taken to ensure this file can always be compared to the original bootstrap file. In the event of a bootstrap update, a diff must be generated and this diff applied to the variable file of the new version.
* At the end, it imports the custom.scss file, which includes bootstrap adaptations to prepare it for our Chill theme.
* This `custom.scss` file can be split into smaller files using `@import 'custom/...'`.
* The idea is that this first bootstrap layer sets an important part of the applications styles, particularly those related to layout positioning, responsive breakpoints, and the default margins and spacing applied to elements being manipulated.
2. The chill entry point is the second level. It contains the Chill theme, which is recognizable in the application.
* Each bundle has a `Resources/public/chill` folder containing a main sass file, which can optionally be split using `@imports`. All these files are compiled into a single Chill entry point, which serves as the applications theme and overrides bootstrap.
* The chillmain.scss file should contain the most general style cascades, those applied to many areas of the application.
* The chillperson.scss file also includes styles specific to different contexts related to people: person, household, and accompanying course.
* Some smaller bundles contain only styles specific to their functionality.
3. The vue_ entry points are used for Vue components. Vue files can contain an scss style block. These styles are specific to the component and its inheritance, with the scoped tag precisely defining their scope (see the documentation).
4. The page_ entry points are used to add assets specific to certain pages, most often scripts and styles.
## HTML Tagging and Style Cascades
The following example shows how to tag a code element without overdoing it. Note that:
* It is not necessary to tag all inner classes.
* The parent class should not be repeated in all child classes. Sass cascading allows for flexible HTML structuring without overloading the tag hierarchy.
* Often, the first class will have variations created with additional classes that start in the same way: bloc-dark simply adds the dark version of bloc. We do not use bloc dark because we dont want the dark class of bloc to interact with the same dark class of table. As a result, we will have an element bloc bloc-dark and another element table table-dark.
```html
<div class="bloc bloc-dark my-bloc">
<h3>My Title</h3>
<ul class="record_actions">
<li>
<a class="btn btn-edit"></a>
</li>
</ul>
</div>
```
Finally, it is important to define what a block, an action zone, and a button are. These three elements exist independently and are the only ones we tag.
For example, to style the title, we simply specify h3 within the block cascade.
```scss
div.bloc {
// un bloc générique, utilisé à plusieurs endroits
&.bloc-dark {
// la version sombre du bloc
}
h3 {}
ul {
// une liste standard dans bloc
li {
// des items de liste standard dans bloc
}
}
}
div.mon-bloc {
// des exceptions spécifiques à mon-bloc,
// qui sont des adaptations de bloc
}
ul.record_actions {
// va uniformiser tous les record_actions de l'application
li {
//...
}
}
.btn {
// les boutons de bootstrap
.btn-edit {
// chill étends les boutons bootstrap pour ses propres besoins
}
}
</style>
```
## Render box
## URL
## Route Naming Conventions
:::warning
These rules have not always been followed in the past. They are desired for the future.
:::
Routes follow this structure:
`chill_(api|crud)_bundle_(api)_entity_action`
1. First, chill_ (for all Chill modules).
2. Then, crud or api, optional, automatically added if the route is generated by the configuration.
3. Then, a string indicating the bundle (`main`, `person`, `activity`, ...).
4. Then, api, if the route is an API route.
5. Then, a string indicating the entity the route targets, and possibly the sub-entities.
6. Then, an action (`list`, `view`, `edit`, `new`, ...).
Indicating `api` in the fourth position allows distinguishing API routes generated by the configuration (which are all prefixed with `chill_api`) from those generated manually. (For example: `chill_api_household__index` and `chill_person_api_household_members_move`).
If points 4 and 5 are missing, they are replaced by other elements to ensure the uniqueness of the route and its clear understanding.
#### HTML pages
:::warning
These rules have not always been followed in the past. They are desired for the future.
:::
Syntaxe:
```
/{_locale}/bundle/entity/{id}/action
/{_locale}/bundle/entity/sub-entity/{id}/action
```
The following elements should be included in the list:
1. The locale;
2. An identifier for the bundle;
3. The entity it relates to;
4. Any sub-entities that the URL refers to;
5. The action.
```
# list of activities for a person
/fr/activity/person/25/activity/list
# new activity
/fr/activity/activity/new?person_id=25
```
#### Pour les API
:::info
Automatically generated routes are prefixed with `chill_api`
:::
Syntaxe:
```
/api/1.0/bundle/entity/{id}/action
/api/1.0/bundle/entity/sub-entity/{id}/action
```
The following elements should be included in the list:
1. The string `/api/` followed by the version (e.g., 1.0);
2. An identifier for the bundle;
3. The entity it relates to;
4. Any sub-entities that the URL refers to;
5. The action.
These elements may be interspersed with the entity identifier. In this case, the identifier should be placed immediately after the entity it relates to.
#### URLS for admin pages
Same conventions as for other html pages, **but `admin` is added in second position**. Soit:
`/{_locale}/admin/bundle/entity/{id}/action`
## Database table naming convention
When creating a new entity and the corresponding database table, we follow the following naming convention for the database table:
`chill_{bundle_identifier}_{entity_name}`.
Eg. chill_person_spoken_languages
## UI Rules
### Page Titles
#### Every page must have a title (in the head tag and page header).
Each page contains a title in the <head> tag. This title is typically the same as the header title on the page.
Tip: It is possible to use the block function in Twig for this.
Example:
```htmlmixed=
{% block title "Titre de la page" %}
{% block content %}
<h1>
{{ block('title')}}
</h1>
{% endblock %}
```
### entity_render usage
#### in Twig
Always use chill_entity_render_box for rendering entities like:
* User
* Person
* SocialAction
* SocialIssue
* Address
* Thirdparty
* ...
Example:
```
address|chill_entity_render_box
```
Justification:
1. Customization by installation: Some elements are sometimes customized during installation (for example, the name of each user will be followed by the name of the service).
2. To streamline and make displays consistent: Ensures uniformity in the way information is displayed across different pages or sections.
3. To simplify Twig code: By using blocks and centralizing title logic, it reduces repetition and makes the Twig code easier to maintain.
* Three rendering modes:
* inline
* block
* item.
#### In Vue
There is always a renderbox equivalent in vue.
#### HTML Links to Sections
Always include links/icons for accessing records, such as person or household details, if the user has access.
### Form Guidelines
#### Vocabulary:
* `Create` in a `bt bt-create` for links to the form to create an entity (to access the form).
* `Save` in a `bt bt-save` for "Save" buttons (in either an edit or create form).
* `Save and new`
* `Save and view`
* `Edit` in a `bt bt-edit` for links to the edit form.
* `Duplicate` (specify where it can be seen).
* `Cancel` for leaving an edit page with a link to the list, or the `returnPath`.
#### After Saving:
Redirect to the returnPath if available; otherwise, redirect to the view page.
### Sticky Form Buttons:
Buttons like "Cancel" and "Save" must be within a "sticky-form" bar at the bottom of the form.
If relevant:
* The banner contains a "Cancel" button that returns to the previous page. It is mandatory for forms, but optional for lists or "summary" pages.
* This "Cancel" button is always on the left.
```
<ul class="record_actions sticky-form-buttons">
<li class="cancel">
<a href="{{ chill_entity_return_path('route_name' { 'route': 'option' } )}}">{{ return_path_label }}</a>
</li>
<li>
<!-- action 1 -->
</li>
</ul>
```
### Flash Messages
#### Display a flash message upon entity creation:
Everytime an entity has been created
> "The entity has been created."
The name of the element can be replaced with something more relevant:
> * The activity has been created
> * The appointment has been created
> * ...
#### On Saving an Entity
Each time an entity is saved, a flash message should appear:
> The data has been modified
#### Form Error (Validation Error)
At the top of the form, a flash message should indicate that validations have failed:
> This form contains errors
Errors should appear attached to the field they concern. However, it is acceptable to display errors at the root of the form if it is technically difficult to attach errors.
### Return Links
Each time a link is provided, check whether the function chill_return_path, chill_forward_return_path, or chill_return_path_or should be used.
* From the list page, to the opening of an element, or the creation button => use chill_path_add_return_path
* In these edit pages:
* use chill_return_path_or in the "Cancel" button;
* for the "Save and view" and "Save and close" buttons => ?
### Assets for Suggestion Lists
Create a list of suggestions to add (the entire item is clickable)
```html
<ul class="list-suggest add-items">
<li>
<span>item</span>
</li>
</ul>
```
Create a list of suggestions to remove (with a clickable red cross, the anchor <a> is empty)
```html
<ul class="list-suggest remove-items">
<li>
<span>
item
</span>
</li>
</ul>
```
Create a removable title (with a clickable red cross, the anchor <a> is empty)
```html
<div class="item-title">
<span>title</span>
</div>
```
The classes `cols` or `inline` can be added alongside `list-suggest` to modify the layout of the list. In the last example, add a `removable` class to the `<span>` if you want to make the item removable.

View File

@ -4,7 +4,6 @@ en cours de rédaction
## Translations
Par bundle, toutes les traductions des pages twig se trouvent dans un seul fichier `translations/messages.fr.yaml`.
## Emplacement des fichiers
@ -142,7 +141,6 @@ ul.record_actions {
## Render box
## URL
### Nommage des routes
@ -234,6 +232,13 @@ Même conventions que dans les autres pages html de l'application, **mais `admin
`/{_locale}/admin/bundle/entity/{id}/action`
### Nommage des tables de base de donnée
Lors de la création d'une nouvelle entité et de la table de base de données correspondante, nous suivons la convention d'appellation suivante pour la table de base de données :
`chill_{bundle_identifier}_{nom_de_l'entité}`.
Par exemple : chill_person_spoken_languages
## Règles UI chill
@ -293,8 +298,6 @@ A prevoir:
> quand on passe loption render: bloc, on peut placer le render_box dans une boucle for plus large qui fonctionne avec la classe flex-table ou la classe flex-bloc, ce qui donnera un affichage en rangée (table) ou en blocs. [name=Mathieu]
#### En vue
Il existe systématiquement une "box" équivalente en vue.

View File

@ -1,9 +1,15 @@
# Chill framework
# Main Chill Bundles and Chill framework
Documentation of the Chill software.
Chill is a software for social workers. It allows them to keep track of the social work they do.
The online documentation can be found at http://docs.chill.social
See our website for more information https://www.chill.social
See the [`docs`][1] directory for more.
## Installation
[1]: docs/README.md
Chill-bundles is a set of bundles that should be used within a Symfony application.
A symfony application will help you to customize all the configuration options, change the behaviour of some parts of the usual-way that chill works, … without to have to fork this repository !
See [the instructions in the docs](./docs/source/installation/index.rst).
Those instructions are also built [online](https://docs.chill.social).

7
assets/translator.ts Normal file
View File

@ -0,0 +1,7 @@
import { trans, setLocale, setLocaleFallbacks } from "./ux-translator";
setLocaleFallbacks({"en": "fr", "nl": "fr", "fr": "en"});
setLocale('fr');
export { trans };
export * from '../var/translations';

View File

@ -0,0 +1,3 @@
This directory import the symfony ux-translator files directly into chill-bundles.
This remove the yarn dependencies from the real package, which breaks our installation.

View File

@ -0,0 +1 @@
export declare function format(id: string, parameters: Record<string, string | number>, locale: string): string;

View File

@ -0,0 +1 @@
export declare function formatIntl(id: string, parameters: Record<string, string | number>, locale: string): string;

View File

@ -0,0 +1,27 @@
export type DomainType = string;
export type LocaleType = string;
export type TranslationsType = Record<DomainType, {
parameters: ParametersType;
}>;
export type NoParametersType = Record<string, never>;
export type ParametersType = Record<string, string | number | Date> | NoParametersType;
export type RemoveIntlIcuSuffix<T> = T extends `${infer U}+intl-icu` ? U : T;
export type DomainsOf<M> = M extends Message<infer Translations, LocaleType> ? keyof Translations : never;
export type LocaleOf<M> = M extends Message<TranslationsType, infer Locale> ? Locale : never;
export type ParametersOf<M, D extends DomainType> = M extends Message<infer Translations, LocaleType> ? Translations[D] extends {
parameters: infer Parameters;
} ? Parameters : never : never;
export interface Message<Translations extends TranslationsType, Locale extends LocaleType> {
id: string;
translations: {
[domain in DomainType]: {
[locale in Locale]: string;
};
};
}
export declare function setLocale(locale: LocaleType | null): void;
export declare function getLocale(): LocaleType;
export declare function throwWhenNotFound(enabled: boolean): void;
export declare function setLocaleFallbacks(localeFallbacks: Record<LocaleType, LocaleType>): void;
export declare function getLocaleFallbacks(): Record<LocaleType, LocaleType>;
export declare function trans<M extends Message<TranslationsType, LocaleType>, D extends DomainsOf<M>, P extends ParametersOf<M, D>>(...args: P extends NoParametersType ? [message: M, parameters?: P, domain?: RemoveIntlIcuSuffix<D>, locale?: LocaleOf<M>] : [message: M, parameters: P, domain?: RemoveIntlIcuSuffix<D>, locale?: LocaleOf<M>]): string;

View File

@ -0,0 +1 @@
export * from './translator';

View File

@ -0,0 +1,283 @@
import { IntlMessageFormat } from 'intl-messageformat';
function strtr(string, replacePairs) {
const regex = Object.entries(replacePairs).map(([from]) => {
return from.replace(/([-[\]{}()*+?.\\^$|#,])/g, '\\$1');
});
if (regex.length === 0) {
return string;
}
return string.replace(new RegExp(regex.join('|'), 'g'), (matched) => replacePairs[matched].toString());
}
function format(id, parameters, locale) {
if (null === id || '' === id) {
return '';
}
if (typeof parameters['%count%'] === 'undefined' || Number.isNaN(parameters['%count%'])) {
return strtr(id, parameters);
}
const number = Number(parameters['%count%']);
let parts = [];
if (/^\|+$/.test(id)) {
parts = id.split('|');
}
else {
parts = id.match(/(?:\|\||[^|])+/g) || [];
}
const intervalRegex = /^(?<interval>({\s*(-?\d+(\.\d+)?[\s*,\s*\-?\d+(.\d+)?]*)\s*})|(?<left_delimiter>[[\]])\s*(?<left>-Inf|-?\d+(\.\d+)?)\s*,\s*(?<right>\+?Inf|-?\d+(\.\d+)?)\s*(?<right_delimiter>[[\]]))\s*(?<message>.*?)$/s;
const standardRules = [];
for (let part of parts) {
part = part.trim().replace(/\|\|/g, '|');
const matches = part.match(intervalRegex);
if (matches) {
const matchGroups = matches.groups || {};
if (matches[2]) {
for (const n of matches[3].split(',')) {
if (number === Number(n)) {
return strtr(matchGroups.message, parameters);
}
}
}
else {
const leftNumber = '-Inf' === matchGroups.left ? Number.NEGATIVE_INFINITY : Number(matchGroups.left);
const rightNumber = ['Inf', '+Inf'].includes(matchGroups.right)
? Number.POSITIVE_INFINITY
: Number(matchGroups.right);
if (('[' === matchGroups.left_delimiter ? number >= leftNumber : number > leftNumber) &&
(']' === matchGroups.right_delimiter ? number <= rightNumber : number < rightNumber)) {
return strtr(matchGroups.message, parameters);
}
}
}
else {
const ruleMatch = part.match(/^\w+:\s*(.*?)$/);
standardRules.push(ruleMatch ? ruleMatch[1] : part);
}
}
const position = getPluralizationRule(number, locale);
if (typeof standardRules[position] === 'undefined') {
if (1 === parts.length && typeof standardRules[0] !== 'undefined') {
return strtr(standardRules[0], parameters);
}
throw new Error(`Unable to choose a translation for "${id}" with locale "${locale}" for value "${number}". Double check that this translation has the correct plural options (e.g. "There is one apple|There are %count% apples").`);
}
return strtr(standardRules[position], parameters);
}
function getPluralizationRule(number, locale) {
number = Math.abs(number);
let _locale = locale;
if (locale === 'pt_BR' || locale === 'en_US_POSIX') {
return 0;
}
_locale = _locale.length > 3 ? _locale.substring(0, _locale.indexOf('_')) : _locale;
switch (_locale) {
case 'af':
case 'bn':
case 'bg':
case 'ca':
case 'da':
case 'de':
case 'el':
case 'en':
case 'en_US_POSIX':
case 'eo':
case 'es':
case 'et':
case 'eu':
case 'fa':
case 'fi':
case 'fo':
case 'fur':
case 'fy':
case 'gl':
case 'gu':
case 'ha':
case 'he':
case 'hu':
case 'is':
case 'it':
case 'ku':
case 'lb':
case 'ml':
case 'mn':
case 'mr':
case 'nah':
case 'nb':
case 'ne':
case 'nl':
case 'nn':
case 'no':
case 'oc':
case 'om':
case 'or':
case 'pa':
case 'pap':
case 'ps':
case 'pt':
case 'so':
case 'sq':
case 'sv':
case 'sw':
case 'ta':
case 'te':
case 'tk':
case 'ur':
case 'zu':
return 1 === number ? 0 : 1;
case 'am':
case 'bh':
case 'fil':
case 'fr':
case 'gun':
case 'hi':
case 'hy':
case 'ln':
case 'mg':
case 'nso':
case 'pt_BR':
case 'ti':
case 'wa':
return number < 2 ? 0 : 1;
case 'be':
case 'bs':
case 'hr':
case 'ru':
case 'sh':
case 'sr':
case 'uk':
return 1 === number % 10 && 11 !== number % 100
? 0
: number % 10 >= 2 && number % 10 <= 4 && (number % 100 < 10 || number % 100 >= 20)
? 1
: 2;
case 'cs':
case 'sk':
return 1 === number ? 0 : number >= 2 && number <= 4 ? 1 : 2;
case 'ga':
return 1 === number ? 0 : 2 === number ? 1 : 2;
case 'lt':
return 1 === number % 10 && 11 !== number % 100
? 0
: number % 10 >= 2 && (number % 100 < 10 || number % 100 >= 20)
? 1
: 2;
case 'sl':
return 1 === number % 100 ? 0 : 2 === number % 100 ? 1 : 3 === number % 100 || 4 === number % 100 ? 2 : 3;
case 'mk':
return 1 === number % 10 ? 0 : 1;
case 'mt':
return 1 === number
? 0
: 0 === number || (number % 100 > 1 && number % 100 < 11)
? 1
: number % 100 > 10 && number % 100 < 20
? 2
: 3;
case 'lv':
return 0 === number ? 0 : 1 === number % 10 && 11 !== number % 100 ? 1 : 2;
case 'pl':
return 1 === number
? 0
: number % 10 >= 2 && number % 10 <= 4 && (number % 100 < 12 || number % 100 > 14)
? 1
: 2;
case 'cy':
return 1 === number ? 0 : 2 === number ? 1 : 8 === number || 11 === number ? 2 : 3;
case 'ro':
return 1 === number ? 0 : 0 === number || (number % 100 > 0 && number % 100 < 20) ? 1 : 2;
case 'ar':
return 0 === number
? 0
: 1 === number
? 1
: 2 === number
? 2
: number % 100 >= 3 && number % 100 <= 10
? 3
: number % 100 >= 11 && number % 100 <= 99
? 4
: 5;
default:
return 0;
}
}
function formatIntl(id, parameters, locale) {
if (id === '') {
return '';
}
const intlMessage = new IntlMessageFormat(id, [locale.replace('_', '-')], undefined, { ignoreTag: true });
parameters = { ...parameters };
Object.entries(parameters).forEach(([key, value]) => {
if (key.includes('%') || key.includes('{')) {
delete parameters[key];
parameters[key.replace(/[%{} ]/g, '').trim()] = value;
}
});
return intlMessage.format(parameters);
}
let _locale = null;
let _localeFallbacks = {};
let _throwWhenNotFound = false;
function setLocale(locale) {
_locale = locale;
}
function getLocale() {
return (_locale ||
document.documentElement.getAttribute('data-symfony-ux-translator-locale') ||
(document.documentElement.lang ? document.documentElement.lang.replace('-', '_') : null) ||
'en');
}
function throwWhenNotFound(enabled) {
_throwWhenNotFound = enabled;
}
function setLocaleFallbacks(localeFallbacks) {
_localeFallbacks = localeFallbacks;
}
function getLocaleFallbacks() {
return _localeFallbacks;
}
function trans(message, parameters = {}, domain = 'messages', locale = null) {
if (typeof domain === 'undefined') {
domain = 'messages';
}
if (typeof locale === 'undefined' || null === locale) {
locale = getLocale();
}
if (typeof message.translations === 'undefined') {
return message.id;
}
const localesFallbacks = getLocaleFallbacks();
const translationsIntl = message.translations[`${domain}+intl-icu`];
if (typeof translationsIntl !== 'undefined') {
while (typeof translationsIntl[locale] === 'undefined') {
locale = localesFallbacks[locale];
if (!locale) {
break;
}
}
if (locale) {
return formatIntl(translationsIntl[locale], parameters, locale);
}
}
const translations = message.translations[domain];
if (typeof translations !== 'undefined') {
while (typeof translations[locale] === 'undefined') {
locale = localesFallbacks[locale];
if (!locale) {
break;
}
}
if (locale) {
return format(translations[locale], parameters, locale);
}
}
if (_throwWhenNotFound) {
throw new Error(`No translation message found with id "${message.id}".`);
}
return message.id;
}
export { getLocale, getLocaleFallbacks, setLocale, setLocaleFallbacks, throwWhenNotFound, trans };

1
assets/ux-translator/dist/utils.d.ts vendored Normal file
View File

@ -0,0 +1 @@
export declare function strtr(string: string, replacePairs: Record<string, string | number>): string;

View File

@ -0,0 +1,34 @@
{
"name": "@symfony/ux-translator",
"description": "Symfony Translator for JavaScript",
"license": "MIT",
"version": "1.0.0",
"main": "dist/translator_controller.js",
"types": "dist/translator_controller.d.ts",
"scripts": {
"build": "node ../../../bin/build_package.js .",
"watch": "node ../../../bin/build_package.js . --watch",
"test": "../../../bin/test_package.sh .",
"check": "biome check",
"ci": "biome ci"
},
"symfony": {
"importmap": {
"intl-messageformat": "^10.5.11",
"@symfony/ux-translator": "path:%PACKAGE%/dist/translator_controller.js",
"@app/translations": "path:var/translations/index.js",
"@app/translations/configuration": "path:var/translations/configuration.js"
}
},
"peerDependencies": {
"intl-messageformat": "^10.5.11"
},
"peerDependenciesMeta": {
"intl-messageformat": {
"optional": false
}
},
"devDependencies": {
"intl-messageformat": "^10.5.11"
}
}

View File

@ -4,6 +4,10 @@
use App\Kernel;
use Symfony\Bundle\FrameworkBundle\Console\Application;
if (!is_dir(dirname(__DIR__).'/vendor')) {
throw new LogicException('Dependencies are missing. Try running "composer install".');
}
if (!is_file(dirname(__DIR__).'/vendor/autoload_runtime.php')) {
throw new LogicException('Symfony Runtime is missing. Try running "composer require symfony/runtime".');
}

34
compose.override.yaml Normal file
View File

@ -0,0 +1,34 @@
services:
###> doctrine/doctrine-bundle ###
database:
ports:
- "127.0.0.1:5454:5432"
###< doctrine/doctrine-bundle ###
###> symfony/mailer ###
mailer:
image: axllent/mailpit
ports:
- "1025"
- "8025"
environment:
MP_SMTP_AUTH_ACCEPT_ANY: 1
MP_SMTP_AUTH_ALLOW_INSECURE: 1
###< symfony/mailer ###
redis:
ports:
- 127.0.0.1:6363:6379
relatorio:
ports:
- 8888
rabbitmq:
ports:
- 127.0.0.1:5689:5672
- 127.0.0.1:15689:15672
# required to make data persistent
hostname: my-rabbit
volumes:
- ./docker/rabbitmq/data:/var/lib/rabbitmq

56
compose.yaml Normal file
View File

@ -0,0 +1,56 @@
services:
###> doctrine/doctrine-bundle ###
database:
image: postgis/postgis:${POSTGRES_VERSION:-16}-3.4-alpine
environment:
POSTGRES_DB: ${POSTGRES_DB:-app}
# You should definitely change the password in production
POSTGRES_PASSWORD: ${POSTGRES_PASSWORD:-!ChangeMe!}
POSTGRES_USER: ${POSTGRES_USER:-app}
volumes:
# - database_data:/var/lib/postgresql/data:rw
# You may use a bind-mounted host directory instead, so that it is harder to accidentally remove the volume and lose all your data!
- ./docker/db/data:/var/lib/postgresql/data:rw
###< doctrine/doctrine-bundle ###
redis:
image: redis
relatorio:
image: registry.gitlab.com/champs-libres/public/relatorio-tornado/app:latest
sign-worker:
image: h3m6q87t.gra7.container-registry.ovh.net/sign-pdf-worker/worker:latest
environment:
AMQP_URL: amqp://guest:guest@rabbitmq:5672/%2f/to_python_sign
LOG_LEVEL: INFO
PKCS12_PATH: /etc/sign-pdf/dummy.p12
TIMESTAMP_URL: http://freetsa.org/tsr
QUEUE_IN: to_python_sign
EXCHANGE_OUT: signed_docs
OUT_ROUTING_KEY: signed_doc
TSA_CERT_CHAIN: /etc/sign-pdf/tsa/tsa-chain.pem
TSA_CONFIG_PATH: /etc/sign-pdf/rootca.conf
TSA_KEY_PASSWORD: "5678"
volumes:
- "./resources/dev-certificate/dummy.p12:/etc/sign-pdf/dummy.p12:ro"
- "./resources/dev-certificate/rootca.conf:/etc/sign-pdf/rootca.conf:ro"
- "./resources/dev-certificate/tsa:/etc/sign-pdf/tsa:ro"
- "./resources/dev-certificate/tsa_serial:/var/lib/tsa/tsa_serial:rw"
links:
- rabbitmq
depends_on:
rabbitmq:
condition: service_healthy
rabbitmq:
image: rabbitmq:3-management-alpine
healthcheck:
test: rabbitmq-diagnostics -q ping
interval: 30s
timeout: 30s
retries: 3
volumes:
###> doctrine/doctrine-bundle ###
database_data:
###< doctrine/doctrine-bundle ###

View File

@ -13,13 +13,14 @@
"ext-json": "*",
"ext-openssl": "*",
"ext-redis": "*",
"ext-zlib": "*",
"champs-libres/wopi-bundle": "dev-master@dev",
"champs-libres/wopi-lib": "dev-master@dev",
"doctrine/data-fixtures": "^1.8",
"doctrine/doctrine-bundle": "^2.1",
"doctrine/doctrine-migrations-bundle": "^3.0",
"doctrine/orm": "^2.13.0",
"erusev/parsedown": "^1.7",
"graylog2/gelf-php": "^1.5",
"knplabs/knp-menu-bundle": "^3.0",
"knplabs/knp-time-bundle": "^1.12",
"knpuniversity/oauth2-client-bundle": "^2.10",
@ -32,6 +33,7 @@
"phpoffice/phpspreadsheet": "^1.16",
"ramsey/uuid-doctrine": "^1.7",
"sensio/framework-extra-bundle": "^5.5",
"smalot/pdfparser": "^2.10",
"spomky-labs/base64url": "^2.0",
"symfony/asset": "^5.4",
"symfony/browser-kit": "^5.4",
@ -43,6 +45,7 @@
"symfony/dom-crawler": "^5.4",
"symfony/error-handler": "^5.4",
"symfony/event-dispatcher": "^5.4",
"symfony/event-dispatcher-contracts": "^2.4",
"symfony/expression-language": "^5.4",
"symfony/filesystem": "^5.4",
"symfony/finder": "^5.4",
@ -55,7 +58,9 @@
"symfony/messenger": "^5.4",
"symfony/mime": "^5.4",
"symfony/monolog-bundle": "^3.5",
"symfony/notifier": "^5.4",
"symfony/options-resolver": "^5.4",
"symfony/ovh-cloud-notifier": "^5.4",
"symfony/process": "^5.4",
"symfony/property-access": "^5.4",
"symfony/property-info": "^5.4",
@ -70,6 +75,7 @@
"symfony/templating": "^5.4",
"symfony/translation": "^5.4",
"symfony/twig-bundle": "^5.4",
"symfony/ux-translator": "^2.22",
"symfony/validator": "^5.4",
"symfony/webpack-encore-bundle": "^1.11",
"symfony/workflow": "^5.4",
@ -84,6 +90,7 @@
"require-dev": {
"doctrine/doctrine-fixtures-bundle": "^3.3",
"fakerphp/faker": "^1.13",
"friendsofphp/php-cs-fixer": "3.65.0",
"jangregor/phpstan-prophecy": "^1.0",
"nelmio/alice": "^3.8",
"nikic/php-parser": "^4.15",
@ -92,15 +99,18 @@
"phpstan/phpstan": "^1.9",
"phpstan/phpstan-deprecation-rules": "^1.1",
"phpstan/phpstan-strict-rules": "^1.0",
"phpunit/phpunit": ">= 7.5",
"phpunit/phpunit": "^10.5.24",
"rector/rector": "^1.1.0",
"symfony/amqp-messenger": "^5.4.45",
"symfony/debug-bundle": "^5.4",
"symfony/dotenv": "^5.4",
"symfony/flex": "^2.4",
"symfony/maker-bundle": "^1.20",
"symfony/phpunit-bridge": "^5.4",
"symfony/phpunit-bridge": "^7.1",
"symfony/runtime": "^5.4",
"symfony/stopwatch": "^5.4",
"symfony/var-dumper": "^5.4"
"symfony/var-dumper": "^5.4",
"symfony/web-profiler-bundle": "^5.4"
},
"conflict": {
"symfony/symfony": "*"
@ -115,11 +125,12 @@
"Chill\\DocGeneratorBundle\\": "src/Bundle/ChillDocGeneratorBundle",
"Chill\\DocStoreBundle\\": "src/Bundle/ChillDocStoreBundle",
"Chill\\EventBundle\\": "src/Bundle/ChillEventBundle",
"Chill\\FranceTravailApiBundle\\": "src/Bundle/ChillFranceTravailApiBundle/src",
"Chill\\JobBundle\\": "src/Bundle/ChillJobBundle/src",
"Chill\\MainBundle\\": "src/Bundle/ChillMainBundle",
"Chill\\PersonBundle\\": "src/Bundle/ChillPersonBundle",
"Chill\\ReportBundle\\": "src/Bundle/ChillReportBundle",
"Chill\\TaskBundle\\": "src/Bundle/ChillTaskBundle",
"Chill\\TicketBundle\\": "src/Bundle/ChillTicketBundle/src",
"Chill\\ThirdPartyBundle\\": "src/Bundle/ChillThirdPartyBundle",
"Chill\\WopiBundle\\": "src/Bundle/ChillWopiBundle/src",
"Chill\\Utils\\Rector\\": "utils/rector/src"
@ -127,9 +138,8 @@
},
"autoload-dev": {
"psr-4": {
"App\\": "tests",
"App\\": "src/app",
"Chill\\DocGeneratorBundle\\Tests\\": "src/Bundle/ChillDocGeneratorBundle/tests",
"Chill\\TicketBundle\\Tests\\": "src/Bundle/ChillTicketBundle/tests",
"Chill\\WopiBundle\\Tests\\": "src/Bundle/ChillDocGeneratorBundle/tests",
"Chill\\Utils\\Rector\\Tests\\": "utils/rector/tests"
}
@ -142,16 +152,24 @@
"phpro/grumphp": true,
"phpstan/extension-installer": true,
"roave/you-are-using-it-wrong": true,
"symfony/runtime": true
"symfony/runtime": true,
"symfony/flex": true
},
"bin-dir": "bin",
"optimize-autoloader": true,
"sort-packages": true
},
"scripts": {
"auto-scripts": {
"cache:clear": "symfony-cmd"
"cache:clear": "symfony-cmd",
"assets:install %PUBLIC_DIR%": "symfony-cmd"
},
"php-cs-fixer": "php-cs-fixer fix --config=./.php-cs-fixer.dist.php --show-progress=none"
"php-cs-fixer": "php-cs-fixer fix --config=./.php-cs-fixer.dist.php --show-progress=none",
"phpstan": "phpstan --no-progress",
"rector": "rector --no-progress-bar"
},
"extra": {
"symfony": {
"docker": true
}
}
}

View File

@ -1,15 +1,26 @@
<?php
declare(strict_types=1);
/*
* Chill is a software for social workers
*
* For the full copyright and license information, please view
* the LICENSE file that was distributed with this source code.
*/
return [
Symfony\Bundle\FrameworkBundle\FrameworkBundle::class => ['all' => true],
loophp\PsrHttpMessageBridgeBundle\PsrHttpMessageBridgeBundle::class => ['all' => true],
ChampsLibres\WopiBundle\WopiBundle::class => ['all' => true],
Doctrine\Bundle\DoctrineBundle\DoctrineBundle::class => ['all' => true],
Doctrine\Bundle\FixturesBundle\DoctrineFixturesBundle::class => ['dev' => true, 'test' => true],
Doctrine\Bundle\MigrationsBundle\DoctrineMigrationsBundle::class => ['all' => true],
Knp\Bundle\MenuBundle\KnpMenuBundle::class => ['all' => true],
Knp\Bundle\TimeBundle\KnpTimeBundle::class => ['all' => true],
KnpU\OAuth2ClientBundle\KnpUOAuth2ClientBundle::class => ['all' => true],
Symfony\Bundle\SecurityBundle\SecurityBundle::class => ['all' => true],
Lexik\Bundle\JWTAuthenticationBundle\LexikJWTAuthenticationBundle::class => ['all' => true],
Nelmio\Alice\Bridge\Symfony\NelmioAliceBundle::class => ['dev' => true, 'test' => true],
Misd\PhoneNumberBundle\MisdPhoneNumberBundle::class => ['all' => true],
Sensio\Bundle\FrameworkExtraBundle\SensioFrameworkExtraBundle::class => ['all' => true],
Symfony\Bundle\DebugBundle\DebugBundle::class => ['dev' => true],
Symfony\Bundle\MakerBundle\MakerBundle::class => ['dev' => true],
Symfony\Bundle\MonologBundle\MonologBundle::class => ['all' => true],
Symfony\WebpackEncoreBundle\WebpackEncoreBundle::class => ['all' => true],
Symfony\Bundle\TwigBundle\TwigBundle::class => ['all' => true],
Twig\Extra\TwigExtraBundle\TwigExtraBundle::class => ['all' => true],
Chill\ActivityBundle\ChillActivityBundle::class => ['all' => true],
Chill\AsideActivityBundle\ChillAsideActivityBundle::class => ['all' => true],
Chill\CalendarBundle\ChillCalendarBundle::class => ['all' => true],
@ -23,25 +34,7 @@ return [
Chill\TaskBundle\ChillTaskBundle::class => ['all' => true],
Chill\ThirdPartyBundle\ChillThirdPartyBundle::class => ['all' => true],
Chill\BudgetBundle\ChillBudgetBundle::class => ['all' => true],
Doctrine\Bundle\DoctrineBundle\DoctrineBundle::class => ['all' => true],
Doctrine\Bundle\FixturesBundle\DoctrineFixturesBundle::class => ['dev' => true, 'test' => true],
Doctrine\Bundle\MigrationsBundle\DoctrineMigrationsBundle::class => ['all' => true],
Sensio\Bundle\FrameworkExtraBundle\SensioFrameworkExtraBundle::class => ['all' => true],
Symfony\Bundle\DebugBundle\DebugBundle::class => ['dev' => true, 'test' => true],
Symfony\Bundle\FrameworkBundle\FrameworkBundle::class => ['all' => true],
Symfony\Bundle\MakerBundle\MakerBundle::class => ['dev' => true],
Symfony\Bundle\MonologBundle\MonologBundle::class => ['all' => true],
Symfony\Bundle\SecurityBundle\SecurityBundle::class => ['all' => true],
Symfony\Bundle\TwigBundle\TwigBundle::class => ['all' => true],
//Symfony\Bundle\WebProfilerBundle\WebProfilerBundle::class => ['dev' => true, 'test' => true],
Symfony\WebpackEncoreBundle\WebpackEncoreBundle::class => ['all' => true],
Knp\Bundle\MenuBundle\KnpMenuBundle::class => ['all' => true],
Knp\Bundle\TimeBundle\KnpTimeBundle::class => ['all' => true],
Twig\Extra\TwigExtraBundle\TwigExtraBundle::class => ['all' => true],
loophp\PsrHttpMessageBridgeBundle\PsrHttpMessageBridgeBundle::class => ['all' => true],
\Misd\PhoneNumberBundle\MisdPhoneNumberBundle::class => ['all' => true],
ChampsLibres\WopiBundle\WopiBundle::class => ['all' => true],
Chill\WopiBundle\ChillWopiBundle::class => ['all' => true],
\Lexik\Bundle\JWTAuthenticationBundle\LexikJWTAuthenticationBundle::class => ['all' => true],
Chill\TicketBundle\ChillTicketBundle::class => ['all' => true],
Symfony\Bundle\WebProfilerBundle\WebProfilerBundle::class => ['dev' => true, 'test' => true],
Symfony\UX\Translator\UxTranslatorBundle::class => ['all' => true],
];

View File

@ -17,17 +17,3 @@ framework:
# Namespaced pools use the above "app" backend by default
#pools:
#my.dedicated.cache: null
default_redis_provider: '%env(resolve:REDIS_URL)%'
pools:
cache.user_data:
adapter: cache.adapter.redis
public: true
default_lifetime: 300 # 5 minutes
# will be used in chill_main.tag_aware_cache service
cache.tags:
adapter: cache.adapter.redis
public: false
default_lifetime: 300

View File

@ -0,0 +1,14 @@
framework:
cache:
default_redis_provider: '%env(resolve:REDIS_URL)%'
pools:
cache.user_data:
adapter: cache.adapter.redis
public: true
default_lifetime: 300 # 5 minutes
# will be used in chill_main.tag_aware_cache service
cache.tags:
adapter: cache.adapter.redis
public: false
default_lifetime: 300

121
config/packages/chill.yaml Normal file
View File

@ -0,0 +1,121 @@
chill_main:
available_languages: [ '%env(resolve:LOCALE)%', 'en' ]
available_countries: ['BE', 'FR']
notifications:
from_email: '%env(resolve:NOTIFICATION_FROM_EMAIL)%'
from_name: '%env(resolve:NOTIFICATION_FROM_NAME)%'
host: '%env(resolve:NOTIFICATION_HOST)%'
redis:
host: '%env(resolve:REDIS_HOST)%'
port: '%env(resolve:REDIS_PORT)%'
phone_helper:
twilio_sid: '%env(resolve:TWILIO_SID)%'
twilio_secret: '%env(resolve:TWILIO_SECRET)%'
default_carrier_code: '%env(resolve:DEFAULT_CARRIER_CODE)%'
short_messages:
dsn: '%env(string:SHORT_MESSAGE_DSN)%'
acl:
form_show_scopes: true
form_show_centers: true
access_global_history: false
access_user_change_password: true
access_permissions_group_list: true
add_address:
default_country: '%env(string:ADD_ADDRESS_DEFAULT_COUNTRY)%'
map_center:
x: '%env(float:ADD_ADDRESS_MAP_CENTER_X)%'
y: '%env(float:ADD_ADDRESS_MAP_CENTER_Y)%'
z: '%env(float:ADD_ADDRESS_MAP_CENTER_Z)%'
when@test:
chill_main:
available_languages:
- 'fr'
- 'en'
chill_custom_fields:
show_empty_values_in_views: false
chill_person:
create_person_allowed: false
create_parcours_allowed: false
allow_multiple_simultaneous_accompanying_periods: true
accompanying_periods_fields:
user: visible
# createdBy, step, origin, intensity, scopes, requestor, anonymous, emergency, confidential : visible(default) | hidden
person_fields:
acceptEmail: hidden
alt_names:
- key: jeune_fille
labels:
lang: fr
label: Nom de naissance
marital_status: visible
civility: visible
deathdate: visible
validation:
center_required: true
chill_activity:
form:
time_duration:
-
label: '5 minutes'
seconds: 300
-
label: '10 minutes'
seconds: 600
-
label: '15 minutes'
seconds: 900
-
label: '20 minutes'
seconds: 1200
-
label: '25 minutes'
seconds: 1500
-
label: '30 minutes'
seconds: 1800
-
label: '45 minutes'
seconds: 2700
-
label: '1 hour'
seconds: 3600
-
label: '1 hour 15'
seconds: 4500
-
label: '1 hour 30'
seconds: 5400
-
label: '1 hour 45'
seconds: 6300
-
label: '2 hours'
seconds: 7200
-
label: '2 hours 15'
seconds: 8100
-
label: '2 hours 30'
seconds: 9000
-
label: '2 hours 45'
seconds: 9900
-
label: '3 hours'
seconds: 10800
-
label: '3 hours 30'
seconds: 12600
-
label: '4 hours'
seconds: 14400
-
label: '4 hours 30'
seconds: 16200
-
label: '5 hours'
seconds: 18000

View File

@ -0,0 +1,85 @@
chill_budget:
resources:
- { key: fixed_contract, labels: [{ lang: fr, label: "Salarié en CDI" }]}
- { key: temporary_contract, labels: [{ lang: fr, label: "Salarié en CDD"}]}
- { key: interim, labels: [{ lang: fr, label: "Salarié en intérim"}]}
- { key: other_revenues, labels: [{ lang: fr, label: "Revenus non salariés, commerçant, artisan,..."}]}
- { key: agricultural_activity, labels: [{ lang: fr, label: "Exploitant agricole"}]}
- { key: chomage_ass, labels: [{ lang: fr, label: "Allocations chômage ASS"}]}
- { key: chomage_are, labels: [{ lang: fr, label: "Allocations chômage ARE"}]}
- { key: remuneration_stage, labels: [{ lang: fr, label: "Rémunération de stage, dapprentissage,..."}]}
- { key: daily_allowences, labels: [{ lang: fr, label: "Indemnités journalières"}]}
- { key: others, labels: [{ lang: fr, label: "Autres"}]}
- { key: pension, labels: [{ lang: fr, label: "Pension de retraite"}]}
- { key: invalidity, labels: [{ lang: fr, label: "Pension d'invalidité"}]}
- { key: reversion, labels: [{ lang: fr, label: "Pension de réversion"}]}
- { key: widowhood, labels: [{ lang: fr, label: "Pension de veuvage"}]}
- { key: military, labels: [{ lang: fr, label: "Pension militaire"}]}
- { key: food, labels: [{ lang: fr, label: "Pension alimentaire"}]}
- { key: compensation, labels: [{ lang: fr, label: "Pension de prestation compensatoire"}]}
- { key: allocation_handicap_adult, labels: [{ lang: fr, label: "Allocation aux adultes handicapés"}]}
- { key: rsa, labels: [{ lang: fr, label: "RSA"}]}
- { key: annuity_accident, labels: [{ lang: fr, label: "Rente accident"}]}
- { key: premium_al_pl, labels: [{ lang: fr, label: "Prime dactivité AL/APL au bénéficiaire"}]}
- { key: premium_thirdparty, labels: [{ lang: fr, label: "Prime dactivité versé au tiers"}]}
- { key: other_income, labels: [{ lang: fr, label: "Autres ressources (ARS, ...)"}]}
- { key: allocation_family, labels: [{ lang: fr, label: "Allocations familiales"}]}
- { key: allocation_basic, labels: [{ lang: fr, label: "Allocation de base"}]}
- { key: free_choice_saving, labels: [{ lang: fr, label: "Complément de libre choix du mode de garde"}]}
- { key: shared_benefits_child, labels: [{ lang: fr, label: "Prestation partagée éducation de lenfant"}]}
- { key: complimentary_family, labels: [{ lang: fr, label: "Complément familial"}]}
- { key: allocation_family_support, labels: [{ lang: fr, label: "Allocation de soutien familial"}]}
- { key: allocation_education_child_handicap, labels: [{ lang: fr, label: "Allocation déducation de lenfant handicapé"}]}
charges:
- { key: rent, labels: [{ lang: fr, label: "Loyer" }]}
- { key: home_ownership, labels: [{ lang: fr, label: "Accession à la propriété" }]}
- { key: costs_accomodation, labels: [{ lang: fr, label: "Frais dhébergement" }]}
- { key: home_insurance, labels: [{ lang: fr, label: "Assurance habitation" }]}
- { key: taxes, labels: [{ lang: fr, label: "Impôts (taxe habitation, taxe foncière, ordures ménagères, redevances incitatives)" }]}
- { key: impots, labels: [{lang: fr, label: "Impôts"}]}
- { key: electricity, labels: [{ lang: fr, label: "Electricité" }]}
- { key: gas, labels: [{ lang: fr, label: "Gaz en bouteille" }]}
- { key: heating, labels: [{ lang: fr, label: "Autre moyen de chauffage" }]}
- { key: water, labels: [{ lang: fr, label: "Eau" }]}
- { key: school_fees, labels: [ { lang: fr, label: "Frais de scolarité"}]}
- { key: alimony, labels: [ { lang: fr, label: "Pension alimentaire à reverser"}]}
- { key: child_care, labels: [ { lang: fr, label: "Frais de garde (en totalité)"}]}
- { key: telecom, labels: [ { lang: fr, label: "Frais de communication fixe"}]}
- { key: mobilephone, labels: [ { lang: fr, label: "Frais de communication mobile"}]}
- { key: internet, labels: [ { lang: fr, label: "Frais de communication internet"}]}
- { key: insurance, labels: [{ lang: fr, label: "Assurances"}]}
- { key: debt_commission, labels: [{ lang: fr, label: "Saisine de la commission surendettement"}]}
- { key: recovery_plan, labels: [{ lang: fr, label: "Plan de redressement"}]}
- { key: rpr, labels: [{ lang: fr, label: "PRP"}]}
- { key: moratoire, labels: [{lang: fr, label: "Moratoire"}]}
- { key: mutuelle, labels: [{lang: fr, label: "Mutuelle"}]}
- { key: transport, labels: [{lang: fr, label: "Frais de transport"}]}
- { key: decouvbank, labels: [{lang: fr, label: "Découvert bancaire utilisé"}]}
- { key: procsaisie, labels: [{lang: fr, label: "Procédure de saisie"}]}
- { key: indus, labels: [{lang: fr, label: "Indus"}]}
- { key: apurement, labels: [{lang: fr, label: "Plan d'apurement"}]}
- { key: debt_rent, labels: [{lang: fr, label: "Dette de loyer (hors APL)"}]}
- { key: debt_property, labels: [{lang: fr, label: "Dette d'accession à la propriété"}]}
- { key: debt_lodging, labels: [{lang: fr, label: "Dette de frais dhébergement"}]}
- { key: debt_electricity, labels: [{lang: fr, label: "Dette d'électricité"}]}
- { key: debt_water, labels: [{lang: fr, label: "Dette d'eau"}]}
- { key: debt_heating, labels: [{lang: fr, label: "Dette d'autre moyen de chauffage"}]}
- { key: debt_gas, labels: [{lang: fr, label: "Dette de gaz en bouteille"}]}
- { key: debt_house_insurance, labels: [{lang: fr, label: "Dette d'assurance habitation"}]}
- { key: debt_housing_taxes, labels: [{lang: fr, label: "Dette d'impôts liées au logement"}]}
- { key: debt_taxes, labels: [{lang: fr, label: "Dette d'impôts autres"}]}
- { key: debt_school, labels: [{lang: fr, label: "Dette de frais de scolarité (cantine, transport, frais de scolarité, frais de garde)"}]}
- { key: debt_alimentation, labels: [{lang: fr, label: "Dette de pension alimentaire à reverser"}]}
- { key: debt_childcare, labels: [{lang: fr, label: "Dette de frais de garde (en totalité)"}]}
- { key: debt_phone, labels: [{lang: fr, label: "Dette de communication fixe"}]}
- { key: debt_mobile, labels: [{lang: fr, label: "Dette de communication portable"}]}
- { key: debt_internet, labels: [{lang: fr, label: "Dette de communication internet"}]}
- { key: debt_car_insurance, labels: [{lang: fr, label: "Dette d'assurance auto"}]}
- { key: debt_mutual, labels: [{lang: fr, label: "Dette de mutuelle"}]}
- { key: debt_transport, labels: [{lang: fr, label: "Dette de frais de transport"}]}
- { key: debt_bank, labels: [{lang: fr, label: "Dette de découvert bancaire utilisé"}]}
- { key: debt_garbage, labels: [{lang: fr, label: "Dette de taxe dordures ménagère"}]}
- { key: debt_other, labels: [{lang: fr, label: "Dette autre"}]}
- { key: autre, labels: [{lang: fr, label: "Autre"}]}

View File

@ -0,0 +1,3 @@
chill_calendar:
remote_calendars_sync:
enabled: false

View File

@ -0,0 +1,5 @@
chill_doc_generator:
driver:
type: relatorio
relatorio:
url: 'http://%env(RELATORIO_HOST)%:%env(RELATORIO_PORT)%/'

View File

@ -1,4 +1,7 @@
chill_doc_store:
use_driver: openstack
local_storage:
storage_path: '%kernel.project_dir%/var/storage'
openstack:
temp_url:
temp_url_key: '%env(resolve:ASYNC_UPLOAD_TEMP_URL_KEY)%' # Required

View File

@ -0,0 +1,11 @@
chill_main:
workflow_signature:
base_signer:
document_kinds:
- { key: id_card, labels: [ { lang: fr, label: "Carte d'identité" } ] }
- { key: passport, labels: [ { lang: fr, label: "Passeport" } ] }
- { key: drivers_license, labels: [ { lang: fr, label: "Permis de conduire" } ] }
- { key: visa_long_stay, labels: [ { lang: fr, label: "Visa de long séjour" } ] }
- { key: resident_permit, labels: [ { lang: fr, label: "Carte de séjour" } ] }
- { key: residency_card, labels: [ { lang: fr, label: "Carte de résident" } ] }
- { key: provisionary_residency_permit, labels: [ { lang: fr, label: "Autorisation provisoire de séjour" } ] }

View File

@ -0,0 +1,5 @@
when@dev:
debug:
# Forwards VarDumper Data clones to a centralized server allowing to inspect dumps on CLI or in your browser.
# See the "server:dump" command to start a new server.
dump_destination: "tcp://%env(VAR_DUMPER_SERVER)%"

View File

@ -0,0 +1,38 @@
doctrine:
dbal:
url: '%env(resolve:DATABASE_URL)%'
# IMPORTANT: You MUST configure your server version,
# either here or in the DATABASE_URL env var (see .env file)
#server_version: '16'
use_savepoints: true
orm:
auto_generate_proxy_classes: true
naming_strategy: doctrine.orm.naming_strategy.default
auto_mapping: true
when@test:
doctrine:
dbal:
# "TEST_TOKEN" is typically set by ParaTest
dbname_suffix: '_test%env(default::TEST_TOKEN)%'
when@prod:
doctrine:
orm:
auto_generate_proxy_classes: false
proxy_dir: '%kernel.build_dir%/doctrine/orm/Proxies'
query_cache_driver:
type: pool
pool: doctrine.system_cache_pool
result_cache_driver:
type: pool
pool: doctrine.result_cache_pool
framework:
cache:
pools:
doctrine.result_cache_pool:
adapter: cache.app
doctrine.system_cache_pool:
adapter: cache.system

View File

@ -0,0 +1,2 @@
doctrine_migrations:
enable_profiler: false

View File

@ -7,25 +7,15 @@ doctrine_migrations:
'Chill\Migrations\CustomFields': '@ChillCustomFieldsBundle/migrations'
'Chill\Migrations\Event': '@ChillEventBundle/migrations'
'Chill\Migrations\Person': '@ChillPersonBundle/migrations'
'Chill\Migrations\Report': '@ChillReportBundle/migrations'
'Chill\Migrations\Task': '@ChillTaskBundle/migrations'
'Chill\Migrations\ThirdParty': '@ChillThirdPartyBundle/migrations'
'Chill\Migrations\AsideActivity': '@ChillAsideActivityBundle/migrations'
'Chill\Migrations\DocGenerator': '@ChillDocGeneratorBundle/migrations'
'Chill\Migrations\AsideActivity': '@ChillAsideActivityBundle/migrations'
'Chill\Migrations\Calendar': '@ChillCalendarBundle/migrations'
'Chill\Migrations\Budget': '@ChillBudgetBundle/migrations'
'Chill\Migrations\Ticket': '@ChillTicketBundle/migrations'
'Chill\Migrations\Report': '@ChillReportBundle/migrations'
all_or_nothing:
true
services:
'Doctrine\Migrations\Version\Comparator': 'Chill\MainBundle\Doctrine\Migrations\VersionComparator'
storage:
table_storage:
table_name: 'migration_versions'
version_column_name: 'version'
version_column_length: 1024
executed_at_column_name: 'executed_at'
execution_time_column_name: 'execution_time'

View File

@ -1,16 +1,6 @@
# see https://symfony.com/doc/current/reference/configuration/framework.html
framework:
secret: '%env(APP_SECRET)%'
http_client:
default_options:
verify_peer: false
verify_host: false
trusted_hosts:
- '^(localhost|127.0.0.1|web)$'
- '%env(resolve:TRUSTED_HOSTS)%'
#csrf_protection: true
http_method_override: false
@ -27,12 +17,6 @@ framework:
php_errors:
log: true
#error_controller: App\Controller\ErrorController::show
## sf4 check: ou à déplacer dans un chill.yaml
assets:
json_manifest_path: '%kernel.project_dir%/public/build/manifest.json'
when@test:
framework:
test: true

View File

@ -1,3 +1,8 @@
framework:
assets:
json_manifest_path: '%kernel.project_dir%/public/build/manifest.json'
when@test:
framework:
assets:
json_manifest_path: null

View File

@ -0,0 +1,3 @@
knpu_oauth2_client:
clients:
# configure your clients as described here: https://github.com/knpuniversity/oauth2-client-bundle#configuration

View File

@ -0,0 +1,4 @@
lexik_jwt_authentication:
secret_key: '%env(resolve:JWT_SECRET_KEY)%'
public_key: '%env(resolve:JWT_PUBLIC_KEY)%'
pass_phrase: '%env(JWT_PASSPHRASE)%'

View File

@ -0,0 +1,9 @@
lexik_jwt_authentication:
# required for wopi - recommended duration
token_ttl: 36000
# required for wopi - token in parameter access_token
token_extractors:
query_parameter:
enabled: true
name: access_token

View File

@ -0,0 +1,3 @@
framework:
mailer:
dsn: '%env(MAILER_DSN)%'

View File

@ -0,0 +1,4 @@
framework:
mailer:
envelope:
sender: '%env(NOTIFICATION_FROM_EMAIL)%'

View File

@ -0,0 +1,75 @@
framework:
messenger:
# reset services after consuming messages
reset_on_message: true
# Uncomment this (and the failed transport below) to send failed messages to this transport for later handling.
failure_transport: failed
transports:
# those transports are added by chill-bundles recipes
sync: sync://
async:
dsn: '%env(MESSENGER_TRANSPORT_DSN)%/async'
options:
exchange:
name: async
type: fanout
queues:
async: ~
auto_setup: true
priority: '%env(MESSENGER_TRANSPORT_DSN)%/priority'
# end of transports added by chill-bundles recipes
# https://symfony.com/doc/current/messenger.html#transport-configuration
failed: 'doctrine://default?queue_name=failed'
to_sign_worker:
dsn: '%env(MESSENGER_TRANSPORT_DSN)%/to_python_sign'
serializer: Chill\DocStoreBundle\Service\Signature\Driver\BaseSigner\RequestPdfSignMessageSerializer
options:
exchange:
name: to_python_sign
type: direct
queues:
to_python_sign: ~
signed_docs:
dsn: '%env(MESSENGER_TRANSPORT_DSN)%/signed_docs'
serializer: Chill\DocStoreBundle\Service\Signature\Driver\BaseSigner\PdfSignedMessageSerializer
options:
exchange:
name: signed_docs
type: direct
queues:
signed_docs:
binding_keys: [signed_doc]
auto_setup: false
routing:
# routes added by chill-bundles recipes
'Chill\CalendarBundle\Messenger\Message\CalendarRangeMessage': async
'Chill\CalendarBundle\Messenger\Message\CalendarRangeRemovedMessage': async
'Chill\CalendarBundle\Messenger\Message\CalendarRemovedMessage': async
'Chill\CalendarBundle\Messenger\Message\CalendarMessage': async
'Chill\CalendarBundle\Messenger\Message\InviteUpdateMessage': async
'Chill\CalendarBundle\Messenger\Message\MSGraphChangeNotificationMessage': async
'Chill\MainBundle\Service\ShortMessage\ShortMessage': async
'Chill\DocGeneratorBundle\Service\Messenger\RequestGenerationMessage': priority
'Chill\PersonBundle\AccompanyingPeriod\Lifecycle\AccompanyingPeriodStepChangeRequestMessage': async
'Chill\DocStoreBundle\Service\Signature\Driver\BaseSigner\RequestPdfSignMessage': to_sign_worker
'Chill\DocStoreBundle\Service\StoredObjectCleaner\RemoveOldVersionMessage': async
'Chill\MainBundle\Workflow\Messenger\PostSignatureStateChangeMessage': priority
'Chill\MainBundle\Workflow\Messenger\PostPublicViewMessage': async
'Chill\MainBundle\Service\Workflow\CancelStaleWorkflowMessage': async
# end of routes added by chill-bundles recipes
# Route your messages to the transports
# 'App\Message\YourMessage': async
# 'Symfony\Component\Mailer\Messenger\SendEmailMessage': async
when@test:
framework:
messenger:
transports:
async: 'in-memory://'
priority: 'in-memory://'
signed_docs: 'in-memory://'

View File

@ -0,0 +1,13 @@
# To persist libphonenumber\PhoneNumber objects, add the Misd\PhoneNumberBundle\Doctrine\DBAL\Types\PhoneNumberType mapping to your application's config.
# This requires: doctrine/doctrine-bundle
#doctrine:
# dbal:
# types:
# phone_number: Misd\PhoneNumberBundle\Doctrine\DBAL\Types\PhoneNumberType
#misd_phone_number:
# twig: false
# form: false
# serializer: false
# validator:
# default_region: GB

View File

@ -0,0 +1,62 @@
monolog:
channels:
- deprecation # Deprecations are logged in the dedicated "deprecation" channel when it exists
when@dev:
monolog:
handlers:
main:
type: stream
path: "%kernel.logs_dir%/%kernel.environment%.log"
level: debug
channels: ["!event"]
# uncomment to get logging in your browser
# you may have to allow bigger header sizes in your Web server configuration
#firephp:
# type: firephp
# level: info
#chromephp:
# type: chromephp
# level: info
console:
type: console
process_psr_3_messages: false
channels: ["!event", "!doctrine", "!console"]
when@test:
monolog:
handlers:
main:
type: fingers_crossed
action_level: error
handler: nested
excluded_http_codes: [404, 405]
channels: ["!event"]
nested:
type: stream
path: "%kernel.logs_dir%/%kernel.environment%.log"
level: debug
when@prod:
monolog:
handlers:
main:
type: fingers_crossed
action_level: error
handler: nested
excluded_http_codes: [404, 405]
buffer_size: 50 # How many messages should be saved? Prevent memory leaks
nested:
type: stream
path: php://stderr
level: debug
formatter: monolog.formatter.json
console:
type: console
process_psr_3_messages: false
channels: ["!event", "!doctrine"]
deprecation:
type: stream
channels: [deprecation]
path: php://stderr
formatter: monolog.formatter.json

View File

@ -0,0 +1,12 @@
when@dev: &dev
nelmio_alice:
functions_blacklist:
- 'current'
- 'shuffle'
- 'date'
- 'time'
- 'file'
- 'md5'
- 'sha1'
when@test: *dev

Some files were not shown because too many files have changed in this diff Show More