mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-09-22 14:45:43 +00:00
Compare commits
448 Commits
testing-20
...
295-cancel
Author | SHA1 | Date | |
---|---|---|---|
fad7bdf235
|
|||
8521cea46c
|
|||
4ead7ba761
|
|||
9721b166eb
|
|||
1b21cd6c33
|
|||
97860a9487
|
|||
2fb46c65c2
|
|||
f4356ac249
|
|||
d152efe084
|
|||
ee9530d03f
|
|||
b97eabf0d2
|
|||
2e69d2df90
|
|||
cb446edd18
|
|||
5d84e997c1
|
|||
35199b6993
|
|||
dab68fb409
|
|||
6001bb6447
|
|||
29fec50515
|
|||
34edb02cd0
|
|||
860ae5cedf
|
|||
bf056046ab
|
|||
4d73f9b81a
|
|||
dd159f4379 | |||
49ad25b4c8
|
|||
ad94310981
|
|||
e8f09b507f
|
|||
e29e1db6ed
|
|||
8c4f342ca1
|
|||
745a29f742
|
|||
41ffc470a0
|
|||
46b31ae1ea
|
|||
8c5e94e295
|
|||
9c8a84cdbd
|
|||
a82b99aecc
|
|||
deb4bda16e
|
|||
c1e5f4a57e
|
|||
6fc5a10dc4
|
|||
18abc84e68
|
|||
e85c31826f
|
|||
d119ba49f7
|
|||
c21de777fd
|
|||
15eaf648df
|
|||
42471269db
|
|||
9475a708c3
|
|||
bf1af1aaad | |||
8ea87053f0
|
|||
3c9ee41b3b
|
|||
d0031e82e8
|
|||
20f2bc6c35
|
|||
71d3aa3969
|
|||
ce781a5b58
|
|||
2dd275a074 | |||
5f5d4b8f06 | |||
cc8214d52c
|
|||
0c797c2997
|
|||
ee6edba206
|
|||
3e6d764b9b
|
|||
3e5a558cdf
|
|||
0e6b7d76a4
|
|||
b2042bd1e4 | |||
6e9f111fd9
|
|||
313fb9ffdf
|
|||
063bc2857f
|
|||
615629d1b4
|
|||
667e144681
|
|||
e17203ca3a
|
|||
c6a6d76790
|
|||
3d49c959e0
|
|||
|
86896a12e6 | ||
|
3a959b7044 | ||
|
f8d95384ea | ||
b6edbb3eed
|
|||
00cc3b7806
|
|||
7ab52ff09e
|
|||
2d82c1e105
|
|||
e477a49c92
|
|||
0db2652f08
|
|||
c38f7c1179
|
|||
67d24cb951
|
|||
cb90261309
|
|||
2feea24c41
|
|||
1b16d4fe3b
|
|||
ce5659219a
|
|||
5fefe09a39
|
|||
e21db73b84
|
|||
3978ea9a47
|
|||
4fbb7811ac
|
|||
2b7ea4178b
|
|||
8a374864fa
|
|||
bb848746d5
|
|||
3738c110f8
|
|||
f57fdb2b4c
|
|||
b57824fc7e
|
|||
6b4e1ed2d3
|
|||
b0485dbcc8
|
|||
c16219dc6d
|
|||
ad47804c91 | |||
85e2466611 | |||
94d6b5eff8 | |||
d87f380f16 | |||
58bf722fae | |||
50fb79ebbf | |||
58912f1d98 | |||
9604ba5f4b | |||
b689a51a48 | |||
8c0d2f58ba | |||
212230448b | |||
2bfb8fe387 | |||
6362b98a00 | |||
6e2a08cae8 | |||
305105faae | |||
85811cc6ae | |||
7eee995627 | |||
c0c448fb39 | |||
6445342136 | |||
d52e54fd2a | |||
547a9d1369 | |||
288a02f5b7 | |||
2f9884072c | |||
ee45ff61a6 | |||
5dfd8daf3a | |||
564813ef3d
|
|||
5fed42a623
|
|||
a46e987f81 | |||
81220b5b22 | |||
5b0019cde7 | |||
b19dd4fc11 | |||
44226d6f7f
|
|||
d75607a1d2 | |||
bf66af0f25 | |||
15f3e474a0 | |||
5623cf946e | |||
0a6f3a99da | |||
b42473b01d | |||
be19d09bad | |||
50bd9f32c3 | |||
1396304af5 | |||
c33e4adeec | |||
7351a35c42 | |||
72e3325626 | |||
0a46b5304d | |||
|
e57d52d00e | ||
64e527672d | |||
123168a5ee
|
|||
3836d0dc9b
|
|||
51ab4bef38
|
|||
|
567ca8a26f | ||
|
111305d09c | ||
|
67395f52b5 | ||
|
421226c0dc | ||
|
77da2c1ac6 | ||
|
39d3ba2f40 | ||
|
fb62e54d63 | ||
|
c968d6c541 | ||
|
c428e6665f | ||
|
5b7e3f0336 | ||
|
0c8ef37860 | ||
|
794c479b9e | ||
|
1bee3114ac | ||
|
1344b65dd4 | ||
|
68dcf4dd28 | ||
|
b0a8fd54a8 | ||
|
0f589ec57e | ||
|
2d4fc45a0c | ||
|
c80f23f0db | ||
|
c950400fe2 | ||
|
21c1e77d36 | ||
|
bbfd0caf10 | ||
|
9192883217 | ||
3836622d27 | |||
cc2c4be1b0 | |||
873940786f | |||
c82991674e | |||
3fc3f32c5f | |||
20af766cdf | |||
681f637d13 | |||
fb8a6d960e | |||
a2310a662f | |||
dd7d126bec | |||
29f6a43288 | |||
74be6460d4 | |||
c8e87ced35 | |||
b8002d56ec | |||
a80b36bb31 | |||
116fe35ad2 | |||
5b95336bac | |||
f9d5ba7778 | |||
f76379551c | |||
15094d5a91 | |||
db73dcffc7 | |||
8aec69f0f9
|
|||
9f88eef249
|
|||
d689ce9aef
|
|||
d5e4991982
|
|||
1079c7e394 | |||
ca68b58246
|
|||
747a1de321
|
|||
9e92ede16f
|
|||
31f842471a
|
|||
7d0f9175be
|
|||
e83307ca6d
|
|||
bc2dfd159c | |||
b100792a34 | |||
00ceee1fd5 | |||
215eba41b7 | |||
52a3d1be1b | |||
8d543be5cc | |||
0474b25859 | |||
db94af0958
|
|||
3e8805bdda | |||
a887602f4f
|
|||
c1cf27c42d
|
|||
fe6b4848e6
|
|||
b5af9f7b63
|
|||
7f3de62b2c
|
|||
cfa51cd659 | |||
facc4affed | |||
f9122341d1 | |||
7dd5f542a6 | |||
3b80d9a93b | |||
790576863f | |||
25e89571f7 | |||
435836c7d1 | |||
af4db22184 | |||
724b98e8c5 | |||
2adc8b3bf6 | |||
21b79c1981 | |||
428494ca1f | |||
5d57ec8a3b | |||
719fabc878 | |||
e9a9a3430f | |||
ead1abb825
|
|||
54d045f261
|
|||
702a5a27d2 | |||
|
41dd4d89f7 | ||
|
3a7ed7ef8f | ||
c648a560cc | |||
3d7c8596ee | |||
345f379650 | |||
3262a1dd02 | |||
a9f4f8c973 | |||
c19c597ba0 | |||
03800029c9 | |||
064dfc5a56 | |||
ba95687f46 | |||
a309cc0774
|
|||
5b0babb9b0 | |||
ac2f314395 | |||
8c92d11722 | |||
3db4fff80d
|
|||
fb743b522d | |||
d1653a074b | |||
254122d125 | |||
c9d2e37cee | |||
2c99ea17d4 | |||
18df08e8c3 | |||
db3961275b
|
|||
cd488d7576 | |||
436661d952 | |||
c3b8d42047 | |||
c9d54a5fea
|
|||
|
9c28df25a1 | ||
86c862e69d
|
|||
d88b5a0098
|
|||
|
c5a24e8ac5 | ||
9bc6fe6aff
|
|||
18a03fd740
|
|||
e9d4b9e2ab | |||
efaad1981d | |||
742f2540f6 | |||
bab6528ed6 | |||
a25f2c7539 | |||
c06e76a0ee | |||
4607c36b57 | |||
7c03a25f1a | |||
cce04ee490 | |||
e54633d14d | |||
d9892f6822 | |||
f75c7a0232 | |||
062afd6695 | |||
830dace1ba | |||
2ce9810243 | |||
26b3d84d62 | |||
30078db841 | |||
aaac80be84 | |||
a0fead48e1 | |||
2d09efb2e0 | |||
3a87513a11 | |||
|
d9c50cffb7 | ||
|
25ccb16308 | ||
|
ba25c181f5 | ||
d3956319ca | |||
bd36735cb1 | |||
1310d53589 | |||
e38d47ec5e | |||
36f2275a56 | |||
9a34064b23 | |||
4c3bfc90b5 | |||
1812e84c92 | |||
dfa7de4f38 | |||
610239930b
|
|||
145419a76b | |||
b65e2c62c4 | |||
89f5231649
|
|||
b1ba5cc608 | |||
87a6757e5e | |||
bd41308bbd
|
|||
f8fa96d836
|
|||
d28cec3786
|
|||
7cd36cd483
|
|||
d3d98cdec2
|
|||
49dd7f94fa
|
|||
916724c0c5
|
|||
|
102d0dad94 | ||
|
8d225dd68c | ||
|
61d0005be8 | ||
73797b98f6 | |||
3d40db7493 | |||
760d65b972 | |||
d26fa6bde6 | |||
427f232ab8 | |||
99818c211d
|
|||
a9f0059743
|
|||
5bc542a567
|
|||
482f279dc5 | |||
e0828b1f0f | |||
e015f71bb0 | |||
04a48f22ad | |||
ad4fe80240 | |||
4b82e67952 | |||
c8ccce83fd
|
|||
47f4cfddbb
|
|||
e95f9e9846 | |||
1f4bef754d
|
|||
19e34d5dc0
|
|||
fab00f679c
|
|||
791b3776c5
|
|||
6bd38f1a58
|
|||
68d21c9267
|
|||
e7ca89e0c1
|
|||
fc8bc33ba9
|
|||
cbd9489810
|
|||
e9a9262fae | |||
d9e37d0958 | |||
65c41e6fa9 | |||
7923b5a1ef | |||
4a229ebf6b | |||
90b615c5b2
|
|||
5ca222b501 | |||
3e4495dd6e
|
|||
bca0d04201
|
|||
f66ac50571 | |||
b454774836
|
|||
008f344e49
|
|||
90bfd87ec6
|
|||
cc0030c1cd
|
|||
d60ba3ecb2
|
|||
cd5001ac74 | |||
98f47ac512
|
|||
31b541d12f
|
|||
72045ce082
|
|||
0bfb3de465
|
|||
9ec4c77fb7
|
|||
77c53972c8
|
|||
350d991a85
|
|||
0ce9cdd07a
|
|||
1993fac1c4
|
|||
83883567a2
|
|||
29d57934a1
|
|||
f43d79c940
|
|||
be730679c8
|
|||
f62f1891d8
|
|||
ebb856fe85
|
|||
61877e0157
|
|||
4c3f082163
|
|||
35109133f6
|
|||
a220dad83b
|
|||
9eb571549b
|
|||
db8257d230 | |||
bce93efe83 | |||
06401af801 | |||
ea1d4c48f2
|
|||
|
33cba27dd4 | ||
a7ec7c9f37 | |||
c9e13be736 | |||
b9b342fe44 | |||
31f29f0bc5 | |||
0bc9fff825 | |||
25f93e8a89 | |||
4e0d8e4def | |||
1ecc825945 | |||
addc623add | |||
1b96deb4ee | |||
f510acd170 | |||
835409cb94 | |||
2121b3ef28 | |||
6c9101c167 | |||
b46883fe36 | |||
8d58805abd | |||
c3a799cb7d | |||
bc683b28d6 | |||
d91b1a70bf | |||
853014d8d2 | |||
ad6154a1e4 | |||
50c04382ef | |||
d62e9ce269 | |||
2149ef1cb4 | |||
d15fbadd27 | |||
fbbf421d8b | |||
fe695f1a14 | |||
d0ec6f9819 | |||
0b739fda34 | |||
9b8e143855 | |||
a533ab77ed | |||
087032881b | |||
82667a1c0f | |||
db6408926b | |||
f5c7ab6ef0 | |||
a13ada2937 | |||
3be8a39a1a | |||
d7eb1e01da | |||
bd62202d22 | |||
0e3de2ec8a | |||
aa2a398f9e | |||
33187448a0 | |||
a4482ad28b | |||
8ed5a023e8 | |||
653ac1d62b | |||
499009ac43 | |||
192b161e78 | |||
1b1f355123 | |||
39a863448c | |||
0c1a4a5f59 | |||
6f358ee1a9 | |||
0f36b9349b | |||
d18cc29acf | |||
4220d1a2d3 | |||
1ae27152c2 | |||
b946f8c10a | |||
62d6106801 | |||
89fb87f71f | |||
1337360690 | |||
9324c33caf | |||
c2dd9ef676 | |||
a42d7231d9 | |||
38deaf6f36 | |||
04fc5b6614 | |||
384b2be577 |
@@ -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"
|
|
@@ -1,5 +0,0 @@
|
|||||||
kind: Feature
|
|
||||||
body: Add job bundle (module emploi)
|
|
||||||
time: 2024-05-22T16:49:33.730465146+02:00
|
|
||||||
custom:
|
|
||||||
Issue: ""
|
|
@@ -1,6 +0,0 @@
|
|||||||
kind: Feature
|
|
||||||
body: |
|
|
||||||
Upgrade import of address list to the last version of compiled addresses of belgian-best-address
|
|
||||||
time: 2024-05-30T16:00:03.440767606+02:00
|
|
||||||
custom:
|
|
||||||
Issue: ""
|
|
@@ -1,6 +0,0 @@
|
|||||||
kind: Feature
|
|
||||||
body: |
|
|
||||||
Upgrade CKEditor and refactor configuration with use of typescript
|
|
||||||
time: 2024-05-31T19:02:42.776662753+02:00
|
|
||||||
custom:
|
|
||||||
Issue: ""
|
|
8
.changes/unreleased/Feature-20240614-153236.yaml
Normal file
8
.changes/unreleased/Feature-20240614-153236.yaml
Normal file
@@ -0,0 +1,8 @@
|
|||||||
|
kind: Feature
|
||||||
|
body: |-
|
||||||
|
Electronic signature
|
||||||
|
|
||||||
|
Implementation of the electronic signature for documents within chill.
|
||||||
|
time: 2024-06-14T15:32:36.875891692+02:00
|
||||||
|
custom:
|
||||||
|
Issue: ""
|
7
.changes/unreleased/Feature-20240614-153537.yaml
Normal file
7
.changes/unreleased/Feature-20240614-153537.yaml
Normal file
@@ -0,0 +1,7 @@
|
|||||||
|
kind: Feature
|
||||||
|
body: 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.
|
||||||
|
time: 2024-06-14T15:35:37.582159301+02:00
|
||||||
|
custom:
|
||||||
|
Issue: "286"
|
5
.changes/unreleased/Feature-20240718-151233.yaml
Normal file
5
.changes/unreleased/Feature-20240718-151233.yaml
Normal file
@@ -0,0 +1,5 @@
|
|||||||
|
kind: Feature
|
||||||
|
body: Metadata form added for person signatures
|
||||||
|
time: 2024-07-18T15:12:33.8134266+02:00
|
||||||
|
custom:
|
||||||
|
Issue: "288"
|
@@ -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: ""
|
|
21
.changes/v2.20.0.md
Normal file
21
.changes/v2.20.0.md
Normal 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
3
.changes/v2.20.1.md
Normal 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
31
.changes/v2.21.0.md
Normal 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
6
.changes/v2.22.0.md
Normal 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
5
.changes/v2.22.1.md
Normal 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
3
.changes/v2.22.2.md
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
## v2.22.2 - 2024-07-03
|
||||||
|
### Fixed
|
||||||
|
* Remove scope required for event participation stats
|
11
.changes/v2.23.0.md
Normal file
11
.changes/v2.23.0.md
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
## v2.23.0 - 2024-07-23
|
||||||
|
### 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
|
||||||
|
|
||||||
|
### Fixed
|
||||||
|
* Fix resolving of centers for an household, which will fix in turn the access control
|
||||||
|
* Resolved type hinting error in activity list export
|
5
.changes/v3.0.0.md
Normal file
5
.changes/v3.0.0.md
Normal 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
|
@@ -122,7 +122,7 @@ unit_tests:
|
|||||||
- php tests/console chill:db:sync-views --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=2G tests/console cache:clear --env=test
|
||||||
- php -d memory_limit=3G tests/console doctrine:fixtures:load -n --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
|
- php -d memory_limit=4G bin/phpunit --colors=never --exclude-group dbIntensive,openstack-integration,collabora-integration
|
||||||
artifacts:
|
artifacts:
|
||||||
expire_in: 1 day
|
expire_in: 1 day
|
||||||
paths:
|
paths:
|
||||||
@@ -138,4 +138,4 @@ release:
|
|||||||
- echo "running release_job"
|
- echo "running release_job"
|
||||||
release:
|
release:
|
||||||
tag_name: '$CI_COMMIT_TAG'
|
tag_name: '$CI_COMMIT_TAG'
|
||||||
description: "./.changes/v$CI_COMMIT_TAG.md"
|
description: "./.changes/$CI_COMMIT_TAG.md"
|
||||||
|
93
CHANGELOG.md
93
CHANGELOG.md
@@ -6,6 +6,99 @@ adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html),
|
|||||||
and is generated by [Changie](https://github.com/miniscruff/changie).
|
and is generated by [Changie](https://github.com/miniscruff/changie).
|
||||||
|
|
||||||
|
|
||||||
|
## 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.23.0 - 2024-07-23
|
||||||
|
### 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
|
||||||
|
|
||||||
|
### Fixed
|
||||||
|
* Fix resolving of centers for an household, which will fix in turn the access control
|
||||||
|
* Resolved type hinting error in activity list export
|
||||||
|
|
||||||
|
## 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
|
## v2.19.0 - 2024-05-14
|
||||||
### Feature
|
### 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
|
* ([#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
|
||||||
|
@@ -19,7 +19,6 @@
|
|||||||
"doctrine/doctrine-migrations-bundle": "^3.0",
|
"doctrine/doctrine-migrations-bundle": "^3.0",
|
||||||
"doctrine/orm": "^2.13.0",
|
"doctrine/orm": "^2.13.0",
|
||||||
"erusev/parsedown": "^1.7",
|
"erusev/parsedown": "^1.7",
|
||||||
"graylog2/gelf-php": "^1.5",
|
|
||||||
"knplabs/knp-menu-bundle": "^3.0",
|
"knplabs/knp-menu-bundle": "^3.0",
|
||||||
"knplabs/knp-time-bundle": "^1.12",
|
"knplabs/knp-time-bundle": "^1.12",
|
||||||
"knpuniversity/oauth2-client-bundle": "^2.10",
|
"knpuniversity/oauth2-client-bundle": "^2.10",
|
||||||
@@ -32,6 +31,7 @@
|
|||||||
"phpoffice/phpspreadsheet": "^1.16",
|
"phpoffice/phpspreadsheet": "^1.16",
|
||||||
"ramsey/uuid-doctrine": "^1.7",
|
"ramsey/uuid-doctrine": "^1.7",
|
||||||
"sensio/framework-extra-bundle": "^5.5",
|
"sensio/framework-extra-bundle": "^5.5",
|
||||||
|
"smalot/pdfparser": "^2.10",
|
||||||
"spomky-labs/base64url": "^2.0",
|
"spomky-labs/base64url": "^2.0",
|
||||||
"symfony/asset": "^5.4",
|
"symfony/asset": "^5.4",
|
||||||
"symfony/browser-kit": "^5.4",
|
"symfony/browser-kit": "^5.4",
|
||||||
@@ -92,12 +92,12 @@
|
|||||||
"phpstan/phpstan": "^1.9",
|
"phpstan/phpstan": "^1.9",
|
||||||
"phpstan/phpstan-deprecation-rules": "^1.1",
|
"phpstan/phpstan-deprecation-rules": "^1.1",
|
||||||
"phpstan/phpstan-strict-rules": "^1.0",
|
"phpstan/phpstan-strict-rules": "^1.0",
|
||||||
"phpunit/phpunit": ">= 7.5",
|
"phpunit/phpunit": "^10.5.24",
|
||||||
"rector/rector": "^1.1.0",
|
"rector/rector": "^1.1.0",
|
||||||
"symfony/debug-bundle": "^5.4",
|
"symfony/debug-bundle": "^5.4",
|
||||||
"symfony/dotenv": "^5.4",
|
"symfony/dotenv": "^5.4",
|
||||||
"symfony/maker-bundle": "^1.20",
|
"symfony/maker-bundle": "^1.20",
|
||||||
"symfony/phpunit-bridge": "^5.4",
|
"symfony/phpunit-bridge": "^7.1",
|
||||||
"symfony/runtime": "^5.4",
|
"symfony/runtime": "^5.4",
|
||||||
"symfony/stopwatch": "^5.4",
|
"symfony/stopwatch": "^5.4",
|
||||||
"symfony/var-dumper": "^5.4"
|
"symfony/var-dumper": "^5.4"
|
||||||
|
125
docs/source/installation/enable-collabora-for-dev.rst
Normal file
125
docs/source/installation/enable-collabora-for-dev.rst
Normal file
@@ -0,0 +1,125 @@
|
|||||||
|
|
||||||
|
Enable CODE for development
|
||||||
|
===========================
|
||||||
|
|
||||||
|
For editing a document, there must be a way to communicate between the collabora server and the symfony server, in
|
||||||
|
both direction. The domain name should also be the same for collabora server and for the browser which access to the
|
||||||
|
online editor.
|
||||||
|
|
||||||
|
Using ngrok (or other http tunnel)
|
||||||
|
----------------------------------
|
||||||
|
|
||||||
|
One can configure a tunnel server to expose your local install to the web, and access to your local server using the
|
||||||
|
tunnel url.
|
||||||
|
|
||||||
|
Start ngrok
|
||||||
|
^^^^^^^^^^^
|
||||||
|
|
||||||
|
This can be achieve using `ngrok <https://ngrok.com/>`_.
|
||||||
|
|
||||||
|
.. note::
|
||||||
|
|
||||||
|
The configuration of ngrok is outside of the scope of this document. Refers to the ngrok's documentation.
|
||||||
|
|
||||||
|
.. code-block:: bash
|
||||||
|
|
||||||
|
# ensuring that your server is running through http and port 8000
|
||||||
|
ngrok http 8000
|
||||||
|
# then open the link given by the ngrok utility and you should reach your app
|
||||||
|
|
||||||
|
At this step, ensure that you can reach your local app using the ngrok url.
|
||||||
|
|
||||||
|
Configure Collabora
|
||||||
|
^^^^^^^^^^^^^^^^^^^
|
||||||
|
|
||||||
|
The collabora server must be executed online and configure to access to your ngrok installation. Ensure that the aliasgroup
|
||||||
|
exists for your ngrok application (`See the CODE documentation: <https://sdk.collaboraonline.com/docs/installation/Configuration.html#multihost-configuration>`_).
|
||||||
|
|
||||||
|
Configure your app
|
||||||
|
^^^^^^^^^^^^^^^^^^
|
||||||
|
|
||||||
|
Set the :code:`EDITOR_SERVER` variable to point to your collabora server, this should be done in your :code:`.env.local` file.
|
||||||
|
|
||||||
|
At this point, everything must be fine. In case of errors, watch the log from your collabora server, use the `profiler <https://symfony.com/doc/current/profiler.html>`_
|
||||||
|
to debug the requests.
|
||||||
|
|
||||||
|
.. note::
|
||||||
|
|
||||||
|
In case of error while validating proof (you'll see those message in the collabora's logs), you can temporarily disable
|
||||||
|
the proof validation adding this code snippet in `config/services.yaml`:
|
||||||
|
|
||||||
|
.. code-block:: yaml
|
||||||
|
|
||||||
|
when@dev:
|
||||||
|
# add only in dev environment, to avoid security problems
|
||||||
|
services:
|
||||||
|
ChampsLibres\WopiLib\Contract\Service\ProofValidatorInterface:
|
||||||
|
# this class will always validate proof
|
||||||
|
alias: Chill\WopiBundle\Service\Wopi\NullProofValidator
|
||||||
|
|
||||||
|
With a local CODE image
|
||||||
|
-----------------------
|
||||||
|
|
||||||
|
.. warning::
|
||||||
|
|
||||||
|
This configuration is not sure, and must be refined. The documentation does not seems to be entirely valid.
|
||||||
|
|
||||||
|
Use a local domain name and https for your app
|
||||||
|
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||||
|
|
||||||
|
Use the proxy feature from embedded symfony server to run your app. `See the dedicated doc <https://symfony.com/doc/current/setup/symfony_server.html#local-domain-names>`
|
||||||
|
|
||||||
|
Configure also the `https certificate <https://symfony.com/doc/current/setup/symfony_server.html#enabling-tls>`_
|
||||||
|
|
||||||
|
In this example, your local domain name will be :code:`my-domain` and the url will be :code:`https://my-domain.wip`.
|
||||||
|
|
||||||
|
Ensure that the proxy is running.
|
||||||
|
|
||||||
|
Create a certificate database for collabora
|
||||||
|
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
||||||
|
|
||||||
|
Collabora must validate your certificate generated by symfony console. For that, you need `to create a NSS database <https://sdk.collaboraonline.com/docs/installation/Configuration.html#validating-digital-signatures>`
|
||||||
|
and configure collabora to use it.
|
||||||
|
|
||||||
|
At first, export the certificate for symfony development. Use the graphical interface from your browser to get the
|
||||||
|
certificate as a PEM file.
|
||||||
|
|
||||||
|
.. code-block:: bash
|
||||||
|
|
||||||
|
# create your database in a custom directory
|
||||||
|
mkdir /path/to/your/directory
|
||||||
|
certutil -N -d /path/to/your/directory
|
||||||
|
cat /path/to/your/ca.crt | certutil -d . -A symfony -t -t C,P,C,u,w -a
|
||||||
|
|
||||||
|
Launch CODE properly configured
|
||||||
|
|
||||||
|
.. code-block:: yaml
|
||||||
|
|
||||||
|
collabora:
|
||||||
|
image: collabora/code:latest
|
||||||
|
environment:
|
||||||
|
- SLEEPFORDEBUGGER=0
|
||||||
|
- DONT_GEN_SSL_CERT="True"
|
||||||
|
# add path to the database
|
||||||
|
- extra_params=--o:ssl.enable=false --o:ssl.termination=false --o:logging.level=7 -o:certificates.database_path=/etc/custom-certificates/nss-database
|
||||||
|
- username=admin
|
||||||
|
- password=admin
|
||||||
|
- dictionaries=en_US
|
||||||
|
- aliasgroup1=https://my-domain.wip
|
||||||
|
ports:
|
||||||
|
- "127.0.0.1:9980:9980"
|
||||||
|
volumes:
|
||||||
|
- "/path/to/your/directory/nss-database:/etc/custom-certificates/nss-database"
|
||||||
|
extra_hosts:
|
||||||
|
- "my-domain.wip:host-gateway"
|
||||||
|
|
||||||
|
Configure your app
|
||||||
|
^^^^^^^^^^^^^^^^^^
|
||||||
|
|
||||||
|
Into your :code:`.env.local` file:
|
||||||
|
|
||||||
|
.. code-block:: env
|
||||||
|
|
||||||
|
EDITOR_SERVER=http://${COLLABORA_HOST}:${COLLABORA_PORT}
|
||||||
|
|
||||||
|
At this step, you should be able to edit a document through collabora.
|
@@ -56,7 +56,7 @@ We strongly encourage you to initialize a git repository at this step, to track
|
|||||||
cat <<< "$(jq '.extra.symfony += {"endpoint": ["flex://defaults", "https://gitlab.com/api/v4/projects/57371968/repository/files/index.json/raw?ref=main"]}' composer.json)" > composer.json
|
cat <<< "$(jq '.extra.symfony += {"endpoint": ["flex://defaults", "https://gitlab.com/api/v4/projects/57371968/repository/files/index.json/raw?ref=main"]}' composer.json)" > composer.json
|
||||||
# install chill and some dependencies
|
# install chill and some dependencies
|
||||||
# TODO fix the suffix "alpha1" and replace by ^3.0.0 when version 3.0.0 will be released
|
# TODO fix the suffix "alpha1" and replace by ^3.0.0 when version 3.0.0 will be released
|
||||||
symfony composer require chill-project/chill-bundles v3.0.0-alpha1 champs-libres/wopi-lib dev-master@dev champs-libres/wopi-bundle dev-master@dev
|
symfony composer require chill-project/chill-bundles v3.0.0-RC3 champs-libres/wopi-lib dev-master@dev champs-libres/wopi-bundle dev-master@dev
|
||||||
|
|
||||||
We encourage you to accept the inclusion of the "Docker configuration from recipes": this is the documented way to run the database.
|
We encourage you to accept the inclusion of the "Docker configuration from recipes": this is the documented way to run the database.
|
||||||
You must also accept to configure recipes from the contrib repository, unless you want to configure the bundles manually).
|
You must also accept to configure recipes from the contrib repository, unless you want to configure the bundles manually).
|
||||||
@@ -95,7 +95,7 @@ custom developments. But most of the time, this should be fine.
|
|||||||
|
|
||||||
You have to configure some local variables, which are described in the :code:`.env` file. The secrets should not be stored
|
You have to configure some local variables, which are described in the :code:`.env` file. The secrets should not be stored
|
||||||
in this :code:`.env` file, but instead using the `secrets management tool <https://symfony.com/doc/current/configuration/secrets.html>`_
|
in this :code:`.env` file, but instead using the `secrets management tool <https://symfony.com/doc/current/configuration/secrets.html>`_
|
||||||
or in the :code:`.env.local` file, which should not be commited to the git repository.
|
or in the :code:`.env.local` file, which should not be committed to the git repository.
|
||||||
|
|
||||||
You do not need to set variables for the smtp server, redis server and relatorio server, as they are generated automatically
|
You do not need to set variables for the smtp server, redis server and relatorio server, as they are generated automatically
|
||||||
by the symfony server, from the docker compose services.
|
by the symfony server, from the docker compose services.
|
||||||
@@ -110,10 +110,15 @@ you can either:
|
|||||||
.. code-block:: env
|
.. code-block:: env
|
||||||
|
|
||||||
ADMIN_PASSWORD=\$2y\$13\$iyvJLuT4YEa6iWXyQV4/N.hNHpNG8kXlYDkkt5MkYy4FXcSwYAwmm
|
ADMIN_PASSWORD=\$2y\$13\$iyvJLuT4YEa6iWXyQV4/N.hNHpNG8kXlYDkkt5MkYy4FXcSwYAwmm
|
||||||
|
# note: if you copy-paste the line above, the password will be "admin".
|
||||||
|
|
||||||
- add the generated password to the secrets manager (**note**: you must add the generated hashed password to the secrets env,
|
- add the generated password to the secrets manager (**note**: you must add the generated hashed password to the secrets env,
|
||||||
not the password in clear text).
|
not the password in clear text).
|
||||||
|
|
||||||
|
- set up the jwt authentication bundle
|
||||||
|
|
||||||
|
Some environment variables are available for the JWT authentication bundle in the :code:`.env` file.
|
||||||
|
|
||||||
Prepare migrations and other tools
|
Prepare migrations and other tools
|
||||||
**********************************
|
**********************************
|
||||||
|
|
||||||
@@ -130,6 +135,8 @@ To continue the installation process, you will have to run migrations:
|
|||||||
symfony console messenger:setup-transports
|
symfony console messenger:setup-transports
|
||||||
# prepare some views
|
# prepare some views
|
||||||
symfony console chill:db:sync-views
|
symfony console chill:db:sync-views
|
||||||
|
# generate jwt token, required for some api features (webdav access, ...)
|
||||||
|
symfony console lexik:jwt:generate-keypair
|
||||||
|
|
||||||
.. warning::
|
.. warning::
|
||||||
|
|
||||||
@@ -164,7 +171,7 @@ can rely on the whole chill framework, meaning there is no need to add them to t
|
|||||||
You will require some bundles to have the following development tools:
|
You will require some bundles to have the following development tools:
|
||||||
|
|
||||||
- add fixtures
|
- add fixtures
|
||||||
- add profiler and var-dumper to debug
|
- add profiler and debug bundle
|
||||||
|
|
||||||
Install fixtures
|
Install fixtures
|
||||||
****************
|
****************
|
||||||
@@ -179,7 +186,7 @@ Install fixtures
|
|||||||
This will generate user accounts, centers, and some basic configuration.
|
This will generate user accounts, centers, and some basic configuration.
|
||||||
|
|
||||||
The accounts created are: :code:`center a_social`, :code:`center b_social`, :code:`center a_direction`, ... The full list is
|
The accounts created are: :code:`center a_social`, :code:`center b_social`, :code:`center a_direction`, ... The full list is
|
||||||
visibile in the "users" table: :code:`docker compose exec database psql -U app -c "SELECT username FROM users"`.
|
visible in the "users" table: :code:`docker compose exec database psql -U app -c "SELECT username FROM users"`.
|
||||||
|
|
||||||
The password is always :code:`password`.
|
The password is always :code:`password`.
|
||||||
|
|
||||||
@@ -192,7 +199,7 @@ Add web profiler and debugger
|
|||||||
|
|
||||||
.. code-block:: bash
|
.. code-block:: bash
|
||||||
|
|
||||||
symfony composer require --dev symfony/web-profiler-bundle symfony/var-dumper
|
symfony composer require --dev symfony/web-profiler-bundle symfony/debug-bundle
|
||||||
|
|
||||||
Working on chill bundles
|
Working on chill bundles
|
||||||
************************
|
************************
|
||||||
|
@@ -46,12 +46,14 @@
|
|||||||
"@fullcalendar/vue3": "^6.1.4",
|
"@fullcalendar/vue3": "^6.1.4",
|
||||||
"@popperjs/core": "^2.9.2",
|
"@popperjs/core": "^2.9.2",
|
||||||
"@types/leaflet": "^1.9.3",
|
"@types/leaflet": "^1.9.3",
|
||||||
|
"@types/dompurify": "^3.0.5",
|
||||||
"dropzone": "^5.7.6",
|
"dropzone": "^5.7.6",
|
||||||
"es6-promise": "^4.2.8",
|
"es6-promise": "^4.2.8",
|
||||||
"leaflet": "^1.7.1",
|
"leaflet": "^1.7.1",
|
||||||
|
"marked": "^12.0.2",
|
||||||
"masonry-layout": "^4.2.2",
|
"masonry-layout": "^4.2.2",
|
||||||
"mime": "^4.0.0",
|
"mime": "^4.0.0",
|
||||||
"swagger-ui": "^4.15.5",
|
"pdfjs-dist": "^4.3.136",
|
||||||
"vis-network": "^9.1.0",
|
"vis-network": "^9.1.0",
|
||||||
"vue": "^3.2.37",
|
"vue": "^3.2.37",
|
||||||
"vue-i18n": "^9.1.6",
|
"vue-i18n": "^9.1.6",
|
||||||
|
15
rector.php
15
rector.php
@@ -39,10 +39,14 @@ return static function (RectorConfig $rectorConfig): void {
|
|||||||
|
|
||||||
//define sets of rules
|
//define sets of rules
|
||||||
$rectorConfig->sets([
|
$rectorConfig->sets([
|
||||||
\Rector\Set\ValueObject\LevelSetList::UP_TO_PHP_82,
|
LevelSetList::UP_TO_PHP_82,
|
||||||
\Rector\Symfony\Set\SymfonyLevelSetList::UP_TO_SYMFONY_54,
|
\Rector\Symfony\Set\SymfonySetList::SYMFONY_40,
|
||||||
|
\Rector\Symfony\Set\SymfonySetList::SYMFONY_41,
|
||||||
|
\Rector\Symfony\Set\SymfonySetList::SYMFONY_42,
|
||||||
|
\Rector\Symfony\Set\SymfonySetList::SYMFONY_43,
|
||||||
|
\Rector\Symfony\Set\SymfonySetList::SYMFONY_44,
|
||||||
\Rector\Doctrine\Set\DoctrineSetList::DOCTRINE_CODE_QUALITY,
|
\Rector\Doctrine\Set\DoctrineSetList::DOCTRINE_CODE_QUALITY,
|
||||||
\Rector\Doctrine\Set\DoctrineSetList::ANNOTATIONS_TO_ATTRIBUTES,
|
\Rector\PHPUnit\Set\PHPUnitSetList::PHPUNIT_90,
|
||||||
]);
|
]);
|
||||||
|
|
||||||
$rectorConfig->ruleWithConfiguration(\Rector\Php80\Rector\Class_\AnnotationToAttributeRector::class, [
|
$rectorConfig->ruleWithConfiguration(\Rector\Php80\Rector\Class_\AnnotationToAttributeRector::class, [
|
||||||
@@ -65,9 +69,8 @@ return static function (RectorConfig $rectorConfig): void {
|
|||||||
|
|
||||||
// skip some path...
|
// skip some path...
|
||||||
$rectorConfig->skip([
|
$rectorConfig->skip([
|
||||||
// we must adapt service definition
|
// waiting for fixing this bug: https://github.com/rectorphp/rector-doctrine/issues/342
|
||||||
\Rector\Symfony\Symfony28\Rector\MethodCall\GetToConstructorInjectionRector::class,
|
\Rector\Doctrine\CodeQuality\Rector\Property\ImproveDoctrineCollectionDocTypeInEntityRector::class,
|
||||||
\Rector\Symfony\Symfony34\Rector\Closure\ContainerGetNameToTypeInTestsRector::class,
|
|
||||||
]);
|
]);
|
||||||
|
|
||||||
$rectorConfig->ruleWithConfiguration(AnnotationToAttributeRector::class, [
|
$rectorConfig->ruleWithConfiguration(AnnotationToAttributeRector::class, [
|
||||||
|
@@ -68,7 +68,7 @@ final class ActivityController extends AbstractController
|
|||||||
private readonly FilterOrderHelperFactoryInterface $filterOrderHelperFactory,
|
private readonly FilterOrderHelperFactoryInterface $filterOrderHelperFactory,
|
||||||
private readonly TranslatableStringHelperInterface $translatableStringHelper,
|
private readonly TranslatableStringHelperInterface $translatableStringHelper,
|
||||||
private readonly PaginatorFactory $paginatorFactory,
|
private readonly PaginatorFactory $paginatorFactory,
|
||||||
private readonly ChillSecurity $security
|
private readonly ChillSecurity $security,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -99,10 +99,10 @@ final class ActivityController extends AbstractController
|
|||||||
|
|
||||||
$form = $this->createDeleteForm($activity->getId(), $person, $accompanyingPeriod);
|
$form = $this->createDeleteForm($activity->getId(), $person, $accompanyingPeriod);
|
||||||
|
|
||||||
if (Request::METHOD_DELETE === $request->getMethod()) {
|
if (Request::METHOD_POST === $request->getMethod()) {
|
||||||
$form->handleRequest($request);
|
$form->handleRequest($request);
|
||||||
|
|
||||||
if ($form->isValid()) {
|
if ($form->isSubmitted() && $form->isValid()) {
|
||||||
$this->logger->notice('An activity has been removed', [
|
$this->logger->notice('An activity has been removed', [
|
||||||
'by_user' => $this->getUser()->getUsername(),
|
'by_user' => $this->getUser()->getUsername(),
|
||||||
'activity_id' => $activity->getId(),
|
'activity_id' => $activity->getId(),
|
||||||
@@ -640,7 +640,6 @@ final class ActivityController extends AbstractController
|
|||||||
|
|
||||||
return $this->createFormBuilder()
|
return $this->createFormBuilder()
|
||||||
->setAction($this->generateUrl('chill_activity_activity_delete', $params))
|
->setAction($this->generateUrl('chill_activity_activity_delete', $params))
|
||||||
->setMethod('DELETE')
|
|
||||||
->add('submit', SubmitType::class, ['label' => 'Delete'])
|
->add('submit', SubmitType::class, ['label' => 'Delete'])
|
||||||
->getForm();
|
->getForm();
|
||||||
}
|
}
|
||||||
|
@@ -80,7 +80,7 @@ class Activity implements AccompanyingPeriodLinkedWithSocialIssuesEntityInterfac
|
|||||||
private \DateTime $date;
|
private \DateTime $date;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var Collection<StoredObject>
|
* @var Collection<int, StoredObject>
|
||||||
*/
|
*/
|
||||||
#[Assert\Valid(traverse: true)]
|
#[Assert\Valid(traverse: true)]
|
||||||
#[ORM\ManyToMany(targetEntity: StoredObject::class, cascade: ['persist'])]
|
#[ORM\ManyToMany(targetEntity: StoredObject::class, cascade: ['persist'])]
|
||||||
@@ -107,7 +107,7 @@ class Activity implements AccompanyingPeriodLinkedWithSocialIssuesEntityInterfac
|
|||||||
private ?Person $person = null;
|
private ?Person $person = null;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var Collection<Person>
|
* @var Collection<int, \Chill\PersonBundle\Entity\Person>
|
||||||
*/
|
*/
|
||||||
#[Groups(['read', 'docgen:read'])]
|
#[Groups(['read', 'docgen:read'])]
|
||||||
#[ORM\ManyToMany(targetEntity: Person::class)]
|
#[ORM\ManyToMany(targetEntity: Person::class)]
|
||||||
@@ -117,7 +117,7 @@ class Activity implements AccompanyingPeriodLinkedWithSocialIssuesEntityInterfac
|
|||||||
private PrivateCommentEmbeddable $privateComment;
|
private PrivateCommentEmbeddable $privateComment;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var Collection<ActivityReason>
|
* @var Collection<int, ActivityReason>
|
||||||
*/
|
*/
|
||||||
#[Groups(['docgen:read'])]
|
#[Groups(['docgen:read'])]
|
||||||
#[ORM\ManyToMany(targetEntity: ActivityReason::class)]
|
#[ORM\ManyToMany(targetEntity: ActivityReason::class)]
|
||||||
@@ -132,7 +132,7 @@ class Activity implements AccompanyingPeriodLinkedWithSocialIssuesEntityInterfac
|
|||||||
private string $sentReceived = '';
|
private string $sentReceived = '';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var Collection<SocialAction>
|
* @var Collection<int, \Chill\PersonBundle\Entity\SocialWork\SocialAction>
|
||||||
*/
|
*/
|
||||||
#[Groups(['read', 'docgen:read'])]
|
#[Groups(['read', 'docgen:read'])]
|
||||||
#[ORM\ManyToMany(targetEntity: SocialAction::class)]
|
#[ORM\ManyToMany(targetEntity: SocialAction::class)]
|
||||||
@@ -140,7 +140,7 @@ class Activity implements AccompanyingPeriodLinkedWithSocialIssuesEntityInterfac
|
|||||||
private Collection $socialActions;
|
private Collection $socialActions;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var Collection<SocialIssue>
|
* @var Collection<int, SocialIssue>
|
||||||
*/
|
*/
|
||||||
#[Groups(['read', 'docgen:read'])]
|
#[Groups(['read', 'docgen:read'])]
|
||||||
#[ORM\ManyToMany(targetEntity: SocialIssue::class)]
|
#[ORM\ManyToMany(targetEntity: SocialIssue::class)]
|
||||||
@@ -148,7 +148,7 @@ class Activity implements AccompanyingPeriodLinkedWithSocialIssuesEntityInterfac
|
|||||||
private Collection $socialIssues;
|
private Collection $socialIssues;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var Collection<ThirdParty>
|
* @var Collection<int, ThirdParty>
|
||||||
*/
|
*/
|
||||||
#[Groups(['read', 'docgen:read'])]
|
#[Groups(['read', 'docgen:read'])]
|
||||||
#[ORM\ManyToMany(targetEntity: ThirdParty::class)]
|
#[ORM\ManyToMany(targetEntity: ThirdParty::class)]
|
||||||
@@ -162,7 +162,7 @@ class Activity implements AccompanyingPeriodLinkedWithSocialIssuesEntityInterfac
|
|||||||
private ?User $user = null;
|
private ?User $user = null;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var Collection<User>
|
* @var Collection<int, User>
|
||||||
*/
|
*/
|
||||||
#[Groups(['read', 'docgen:read'])]
|
#[Groups(['read', 'docgen:read'])]
|
||||||
#[ORM\ManyToMany(targetEntity: User::class)]
|
#[ORM\ManyToMany(targetEntity: User::class)]
|
||||||
|
@@ -40,9 +40,9 @@ class ActivityReasonCategory implements \Stringable
|
|||||||
/**
|
/**
|
||||||
* Array of ActivityReason.
|
* Array of ActivityReason.
|
||||||
*
|
*
|
||||||
* @var Collection<ActivityReason>
|
* @var Collection<int, ActivityReason>
|
||||||
*/
|
*/
|
||||||
#[ORM\OneToMany(targetEntity: ActivityReason::class, mappedBy: 'category')]
|
#[ORM\OneToMany(mappedBy: 'category', targetEntity: ActivityReason::class)]
|
||||||
private Collection $reasons;
|
private Collection $reasons;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@@ -28,7 +28,7 @@ class ActivityReasonAggregator implements AggregatorInterface, ExportElementVali
|
|||||||
public function __construct(
|
public function __construct(
|
||||||
protected ActivityReasonCategoryRepository $activityReasonCategoryRepository,
|
protected ActivityReasonCategoryRepository $activityReasonCategoryRepository,
|
||||||
protected ActivityReasonRepository $activityReasonRepository,
|
protected ActivityReasonRepository $activityReasonRepository,
|
||||||
protected TranslatableStringHelper $translatableStringHelper
|
protected TranslatableStringHelper $translatableStringHelper,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
public function addRole(): ?string
|
public function addRole(): ?string
|
||||||
|
@@ -26,7 +26,7 @@ class ActivityUsersJobAggregator implements AggregatorInterface
|
|||||||
|
|
||||||
public function __construct(
|
public function __construct(
|
||||||
private readonly UserJobRepositoryInterface $userJobRepository,
|
private readonly UserJobRepositoryInterface $userJobRepository,
|
||||||
private readonly TranslatableStringHelperInterface $translatableStringHelper
|
private readonly TranslatableStringHelperInterface $translatableStringHelper,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
public function addRole(): ?string
|
public function addRole(): ?string
|
||||||
|
@@ -26,7 +26,7 @@ class ActivityUsersScopeAggregator implements AggregatorInterface
|
|||||||
|
|
||||||
public function __construct(
|
public function __construct(
|
||||||
private readonly ScopeRepositoryInterface $scopeRepository,
|
private readonly ScopeRepositoryInterface $scopeRepository,
|
||||||
private readonly TranslatableStringHelperInterface $translatableStringHelper
|
private readonly TranslatableStringHelperInterface $translatableStringHelper,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
public function addRole(): ?string
|
public function addRole(): ?string
|
||||||
|
@@ -26,7 +26,7 @@ class CreatorJobAggregator implements AggregatorInterface
|
|||||||
|
|
||||||
public function __construct(
|
public function __construct(
|
||||||
private readonly UserJobRepositoryInterface $userJobRepository,
|
private readonly UserJobRepositoryInterface $userJobRepository,
|
||||||
private readonly TranslatableStringHelper $translatableStringHelper
|
private readonly TranslatableStringHelper $translatableStringHelper,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
public function addRole(): ?string
|
public function addRole(): ?string
|
||||||
|
@@ -26,7 +26,7 @@ class CreatorScopeAggregator implements AggregatorInterface
|
|||||||
|
|
||||||
public function __construct(
|
public function __construct(
|
||||||
private readonly ScopeRepository $scopeRepository,
|
private readonly ScopeRepository $scopeRepository,
|
||||||
private readonly TranslatableStringHelper $translatableStringHelper
|
private readonly TranslatableStringHelper $translatableStringHelper,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
public function addRole(): ?string
|
public function addRole(): ?string
|
||||||
|
@@ -42,7 +42,7 @@ class StatActivityDuration implements ExportInterface, GroupedExportInterface
|
|||||||
/**
|
/**
|
||||||
* The action for this report.
|
* The action for this report.
|
||||||
*/
|
*/
|
||||||
protected string $action = 'sum'
|
protected string $action = 'sum',
|
||||||
) {
|
) {
|
||||||
$this->filterStatsByCenters = $parameterBag->get('chill_main')['acl']['filter_stats_by_center'];
|
$this->filterStatsByCenters = $parameterBag->get('chill_main')['acl']['filter_stats_by_center'];
|
||||||
}
|
}
|
||||||
|
@@ -39,7 +39,7 @@ class ListActivityHelper
|
|||||||
private readonly TranslatorInterface $translator,
|
private readonly TranslatorInterface $translator,
|
||||||
private readonly TranslatableStringHelperInterface $translatableStringHelper,
|
private readonly TranslatableStringHelperInterface $translatableStringHelper,
|
||||||
private readonly TranslatableStringExportLabelHelper $translatableStringLabelHelper,
|
private readonly TranslatableStringExportLabelHelper $translatableStringLabelHelper,
|
||||||
private readonly UserHelper $userHelper
|
private readonly UserHelper $userHelper,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
public function addSelect(QueryBuilder $qb): void
|
public function addSelect(QueryBuilder $qb): void
|
||||||
@@ -152,7 +152,7 @@ class ListActivityHelper
|
|||||||
return '';
|
return '';
|
||||||
}
|
}
|
||||||
|
|
||||||
return $this->translator->trans($value);
|
return $this->translator->trans((string) $value);
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
@@ -73,7 +73,7 @@ final readonly class PeriodHavingActivityBetweenDatesFilter implements FilterInt
|
|||||||
|
|
||||||
$qb->andWhere(
|
$qb->andWhere(
|
||||||
$qb->expr()->exists(
|
$qb->expr()->exists(
|
||||||
'SELECT 1 FROM '.Activity::class." {$alias} WHERE {$alias}.date >= :{$from} AND {$alias}.date < :{$to} AND {$alias}.accompanyingPeriod = acp"
|
'SELECT 1 FROM '.Activity::class." {$alias} WHERE {$alias}.date >= :{$from} AND {$alias}.date < :{$to} AND {$alias}.accompanyingPeriod = activity.accompanyingPeriod"
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
|
||||||
|
@@ -25,7 +25,7 @@ final readonly class ActivityPresenceFilter implements FilterInterface
|
|||||||
{
|
{
|
||||||
public function __construct(
|
public function __construct(
|
||||||
private TranslatableStringHelperInterface $translatableStringHelper,
|
private TranslatableStringHelperInterface $translatableStringHelper,
|
||||||
private TranslatorInterface $translator
|
private TranslatorInterface $translator,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
public function getTitle()
|
public function getTitle()
|
||||||
|
@@ -26,7 +26,7 @@ class ActivityTypeFilter implements ExportElementValidatedInterface, FilterInter
|
|||||||
{
|
{
|
||||||
public function __construct(
|
public function __construct(
|
||||||
protected TranslatableStringHelperInterface $translatableStringHelper,
|
protected TranslatableStringHelperInterface $translatableStringHelper,
|
||||||
protected ActivityTypeRepositoryInterface $activityTypeRepository
|
protected ActivityTypeRepositoryInterface $activityTypeRepository,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
public function addRole(): ?string
|
public function addRole(): ?string
|
||||||
|
@@ -29,7 +29,7 @@ class UsersJobFilter implements FilterInterface
|
|||||||
|
|
||||||
public function __construct(
|
public function __construct(
|
||||||
private readonly TranslatableStringHelperInterface $translatableStringHelper,
|
private readonly TranslatableStringHelperInterface $translatableStringHelper,
|
||||||
private readonly UserJobRepositoryInterface $userJobRepository
|
private readonly UserJobRepositoryInterface $userJobRepository,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
public function addRole(): ?string
|
public function addRole(): ?string
|
||||||
|
@@ -29,7 +29,7 @@ class UsersScopeFilter implements FilterInterface
|
|||||||
|
|
||||||
public function __construct(
|
public function __construct(
|
||||||
private readonly ScopeRepositoryInterface $scopeRepository,
|
private readonly ScopeRepositoryInterface $scopeRepository,
|
||||||
private readonly TranslatableStringHelperInterface $translatableStringHelper
|
private readonly TranslatableStringHelperInterface $translatableStringHelper,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
public function addRole(): ?string
|
public function addRole(): ?string
|
||||||
|
@@ -59,7 +59,7 @@ class ActivityType extends AbstractType
|
|||||||
protected TranslatableStringHelper $translatableStringHelper,
|
protected TranslatableStringHelper $translatableStringHelper,
|
||||||
protected array $timeChoices,
|
protected array $timeChoices,
|
||||||
protected SocialIssueRender $socialIssueRender,
|
protected SocialIssueRender $socialIssueRender,
|
||||||
protected SocialActionRender $socialActionRender
|
protected SocialActionRender $socialActionRender,
|
||||||
) {
|
) {
|
||||||
if (!$tokenStorage->getToken()->getUser() instanceof User) {
|
if (!$tokenStorage->getToken()->getUser() instanceof User) {
|
||||||
throw new \RuntimeException('you should have a valid user');
|
throw new \RuntimeException('you should have a valid user');
|
||||||
|
@@ -27,7 +27,7 @@ class PickActivityReasonType extends AbstractType
|
|||||||
public function __construct(
|
public function __construct(
|
||||||
private readonly ActivityReasonRepository $activityReasonRepository,
|
private readonly ActivityReasonRepository $activityReasonRepository,
|
||||||
private readonly ActivityReasonRender $reasonRender,
|
private readonly ActivityReasonRender $reasonRender,
|
||||||
private readonly TranslatableStringHelperInterface $translatableStringHelper
|
private readonly TranslatableStringHelperInterface $translatableStringHelper,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
public function configureOptions(OptionsResolver $resolver)
|
public function configureOptions(OptionsResolver $resolver)
|
||||||
|
@@ -0,0 +1,49 @@
|
|||||||
|
<?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.
|
||||||
|
*/
|
||||||
|
|
||||||
|
namespace Chill\ActivityBundle\Menu;
|
||||||
|
|
||||||
|
use Chill\ActivityBundle\Security\Authorization\ActivityVoter;
|
||||||
|
use Chill\MainBundle\Routing\LocalMenuBuilderInterface;
|
||||||
|
use Knp\Menu\MenuItem;
|
||||||
|
use Symfony\Component\Security\Core\Security;
|
||||||
|
|
||||||
|
final readonly class AccompanyingCourseQuickMenuBuilder implements LocalMenuBuilderInterface
|
||||||
|
{
|
||||||
|
public function __construct(private Security $security) {}
|
||||||
|
|
||||||
|
public static function getMenuIds(): array
|
||||||
|
{
|
||||||
|
return ['accompanying_course_quick_menu'];
|
||||||
|
}
|
||||||
|
|
||||||
|
public function buildMenu($menuId, MenuItem $menu, array $parameters)
|
||||||
|
{
|
||||||
|
/** @var \Chill\PersonBundle\Entity\AccompanyingPeriod $accompanyingCourse */
|
||||||
|
$accompanyingCourse = $parameters['accompanying-course'];
|
||||||
|
|
||||||
|
if ($this->security->isGranted(ActivityVoter::CREATE, $accompanyingCourse)) {
|
||||||
|
$menu
|
||||||
|
->addChild('Create a new activity in accompanying course', [
|
||||||
|
'route' => 'chill_activity_activity_new',
|
||||||
|
'routeParameters' => [
|
||||||
|
// 'activityType_id' => '',
|
||||||
|
'accompanying_period_id' => $accompanyingCourse->getId(),
|
||||||
|
],
|
||||||
|
])
|
||||||
|
->setExtras([
|
||||||
|
'order' => 10,
|
||||||
|
'icon' => 'plus',
|
||||||
|
])
|
||||||
|
;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
@@ -32,7 +32,7 @@ final readonly class ActivityDocumentACLAwareRepository implements ActivityDocum
|
|||||||
private EntityManagerInterface $em,
|
private EntityManagerInterface $em,
|
||||||
private CenterResolverManagerInterface $centerResolverManager,
|
private CenterResolverManagerInterface $centerResolverManager,
|
||||||
private AuthorizationHelperForCurrentUserInterface $authorizationHelperForCurrentUser,
|
private AuthorizationHelperForCurrentUserInterface $authorizationHelperForCurrentUser,
|
||||||
private Security $security
|
private Security $security,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
public function buildFetchQueryActivityDocumentLinkedToPersonFromPersonContext(Person $person, ?\DateTimeImmutable $startDate = null, ?\DateTimeImmutable $endDate = null, ?string $content = null): FetchQueryInterface
|
public function buildFetchQueryActivityDocumentLinkedToPersonFromPersonContext(Person $person, ?\DateTimeImmutable $startDate = null, ?\DateTimeImmutable $endDate = null, ?string $content = null): FetchQueryInterface
|
||||||
|
@@ -25,7 +25,7 @@ class ActivityReasonRepository extends ServiceEntityRepository
|
|||||||
{
|
{
|
||||||
public function __construct(
|
public function __construct(
|
||||||
ManagerRegistry $registry,
|
ManagerRegistry $registry,
|
||||||
private readonly RequestStack $requestStack
|
private readonly RequestStack $requestStack,
|
||||||
) {
|
) {
|
||||||
parent::__construct($registry, ActivityReason::class);
|
parent::__construct($registry, ActivityReason::class);
|
||||||
}
|
}
|
||||||
|
@@ -12,6 +12,8 @@ declare(strict_types=1);
|
|||||||
namespace Chill\ActivityBundle\Repository;
|
namespace Chill\ActivityBundle\Repository;
|
||||||
|
|
||||||
use Chill\ActivityBundle\Entity\Activity;
|
use Chill\ActivityBundle\Entity\Activity;
|
||||||
|
use Chill\DocStoreBundle\Entity\StoredObject;
|
||||||
|
use Chill\DocStoreBundle\Repository\AssociatedEntityToStoredObjectInterface;
|
||||||
use Chill\PersonBundle\Entity\AccompanyingPeriod;
|
use Chill\PersonBundle\Entity\AccompanyingPeriod;
|
||||||
use Chill\PersonBundle\Entity\Person;
|
use Chill\PersonBundle\Entity\Person;
|
||||||
use Doctrine\Bundle\DoctrineBundle\Repository\ServiceEntityRepository;
|
use Doctrine\Bundle\DoctrineBundle\Repository\ServiceEntityRepository;
|
||||||
@@ -23,7 +25,7 @@ use Doctrine\Persistence\ManagerRegistry;
|
|||||||
* @method Activity[] findAll()
|
* @method Activity[] findAll()
|
||||||
* @method Activity[] findBy(array $criteria, array $orderBy = null, $limit = null, $offset = null)
|
* @method Activity[] findBy(array $criteria, array $orderBy = null, $limit = null, $offset = null)
|
||||||
*/
|
*/
|
||||||
class ActivityRepository extends ServiceEntityRepository
|
class ActivityRepository extends ServiceEntityRepository implements AssociatedEntityToStoredObjectInterface
|
||||||
{
|
{
|
||||||
public function __construct(ManagerRegistry $registry)
|
public function __construct(ManagerRegistry $registry)
|
||||||
{
|
{
|
||||||
@@ -97,4 +99,16 @@ class ActivityRepository extends ServiceEntityRepository
|
|||||||
|
|
||||||
return $qb->getQuery()->getResult();
|
return $qb->getQuery()->getResult();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public function findAssociatedEntityToStoredObject(StoredObject $storedObject): ?Activity
|
||||||
|
{
|
||||||
|
$qb = $this->createQueryBuilder('a');
|
||||||
|
$query = $qb
|
||||||
|
->leftJoin('a.documents', 'ad')
|
||||||
|
->where('ad.id = :storedObjectId')
|
||||||
|
->setParameter('storedObjectId', $storedObject->getId())
|
||||||
|
->getQuery();
|
||||||
|
|
||||||
|
return $query->getOneOrNullResult();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@@ -15,9 +15,9 @@ use Chill\ActivityBundle\Entity\ActivityType;
|
|||||||
use Doctrine\ORM\EntityManagerInterface;
|
use Doctrine\ORM\EntityManagerInterface;
|
||||||
use Doctrine\ORM\EntityRepository;
|
use Doctrine\ORM\EntityRepository;
|
||||||
|
|
||||||
final class ActivityTypeRepository implements ActivityTypeRepositoryInterface
|
final readonly class ActivityTypeRepository implements ActivityTypeRepositoryInterface
|
||||||
{
|
{
|
||||||
private readonly EntityRepository $repository;
|
private EntityRepository $repository;
|
||||||
|
|
||||||
public function __construct(EntityManagerInterface $em)
|
public function __construct(EntityManagerInterface $em)
|
||||||
{
|
{
|
||||||
|
@@ -68,7 +68,7 @@
|
|||||||
<div class="wl-col title"><h3>{{ 'Referrer'|trans }}</h3></div>
|
<div class="wl-col title"><h3>{{ 'Referrer'|trans }}</h3></div>
|
||||||
<div class="wl-col list">
|
<div class="wl-col list">
|
||||||
<p class="wl-item">
|
<p class="wl-item">
|
||||||
<span class="badge-user">{{ activity.user|chill_entity_render_box }}</span>
|
<span class="badge-user">{{ activity.user|chill_entity_render_box({'at_date': activity.date}) }}</span>
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@@ -87,7 +87,7 @@
|
|||||||
<li>
|
<li>
|
||||||
{% if bloc.type == 'user' %}
|
{% if bloc.type == 'user' %}
|
||||||
<span class="badge-user">
|
<span class="badge-user">
|
||||||
{{ item|chill_entity_render_box({'render': 'raw', 'addAltNames': false }) }}
|
{{ item|chill_entity_render_box({'render': 'raw', 'addAltNames': false, 'at_date': entity.date }) }}
|
||||||
</span>
|
</span>
|
||||||
{% else %}
|
{% else %}
|
||||||
{{ _self.insert_onthefly(bloc.type, item) }}
|
{{ _self.insert_onthefly(bloc.type, item) }}
|
||||||
@@ -114,7 +114,7 @@
|
|||||||
<li>
|
<li>
|
||||||
{% if bloc.type == 'user' %}
|
{% if bloc.type == 'user' %}
|
||||||
<span class="badge-user">
|
<span class="badge-user">
|
||||||
{{ item|chill_entity_render_box({'render': 'raw', 'addAltNames': false }) }}
|
{{ item|chill_entity_render_box({'render': 'raw', 'addAltNames': false, 'at_date': entity.date }) }}
|
||||||
</span>
|
</span>
|
||||||
{% else %}
|
{% else %}
|
||||||
{{ _self.insert_onthefly(bloc.type, item) }}
|
{{ _self.insert_onthefly(bloc.type, item) }}
|
||||||
@@ -142,7 +142,7 @@
|
|||||||
<span class="wl-item">
|
<span class="wl-item">
|
||||||
{% if bloc.type == 'user' %}
|
{% if bloc.type == 'user' %}
|
||||||
<span class="badge-user">
|
<span class="badge-user">
|
||||||
{{ item|chill_entity_render_box({'render': 'raw', 'addAltNames': false }) }}
|
{{ item|chill_entity_render_box({'render': 'raw', 'addAltNames': false, 'at_date': entity.date }) }}
|
||||||
{%- if context == 'calendar_accompanyingCourse' or context == 'calendar_person' %}
|
{%- if context == 'calendar_accompanyingCourse' or context == 'calendar_person' %}
|
||||||
{% set invite = entity.inviteForUser(item) %}
|
{% set invite = entity.inviteForUser(item) %}
|
||||||
{% if invite is not null %}
|
{% if invite is not null %}
|
||||||
|
@@ -41,7 +41,7 @@
|
|||||||
{% if activity.user and t.userVisible %}
|
{% if activity.user and t.userVisible %}
|
||||||
<li>
|
<li>
|
||||||
<span class="item-key">{{ 'Referrer'|trans ~ ': ' }}</span>
|
<span class="item-key">{{ 'Referrer'|trans ~ ': ' }}</span>
|
||||||
<span class="badge-user">{{ activity.user|chill_entity_render_box }}</span>
|
<span class="badge-user">{{ activity.user|chill_entity_render_box({'at_date': activity.date}) }}</span>
|
||||||
</li>
|
</li>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
|
@@ -37,7 +37,7 @@
|
|||||||
{%- if entity.user is not null %}
|
{%- if entity.user is not null %}
|
||||||
<dt class="inline">{{ 'Referrer'|trans|capitalize }}</dt>
|
<dt class="inline">{{ 'Referrer'|trans|capitalize }}</dt>
|
||||||
<dd>
|
<dd>
|
||||||
<span class="badge-user">{{ entity.user|chill_entity_render_box }}</span>
|
<span class="badge-user">{{ entity.user|chill_entity_render_box({'at_date': entity.date}) }}</span>
|
||||||
</dd>
|
</dd>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
|
|
||||||
|
@@ -0,0 +1,54 @@
|
|||||||
|
<?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.
|
||||||
|
*/
|
||||||
|
|
||||||
|
namespace Chill\ActivityBundle\Security\Authorization;
|
||||||
|
|
||||||
|
use Chill\ActivityBundle\Entity\Activity;
|
||||||
|
use Chill\ActivityBundle\Repository\ActivityRepository;
|
||||||
|
use Chill\DocStoreBundle\Repository\AssociatedEntityToStoredObjectInterface;
|
||||||
|
use Chill\DocStoreBundle\Security\Authorization\StoredObjectRoleEnum;
|
||||||
|
use Chill\DocStoreBundle\Security\Authorization\StoredObjectVoter\AbstractStoredObjectVoter;
|
||||||
|
use Chill\DocStoreBundle\Service\WorkflowStoredObjectPermissionHelper;
|
||||||
|
use Symfony\Component\Security\Core\Security;
|
||||||
|
|
||||||
|
class ActivityStoredObjectVoter extends AbstractStoredObjectVoter
|
||||||
|
{
|
||||||
|
public function __construct(
|
||||||
|
private readonly ActivityRepository $repository,
|
||||||
|
Security $security,
|
||||||
|
WorkflowStoredObjectPermissionHelper $workflowDocumentService,
|
||||||
|
) {
|
||||||
|
parent::__construct($security, $workflowDocumentService);
|
||||||
|
}
|
||||||
|
|
||||||
|
protected function getRepository(): AssociatedEntityToStoredObjectInterface
|
||||||
|
{
|
||||||
|
return $this->repository;
|
||||||
|
}
|
||||||
|
|
||||||
|
protected function getClass(): string
|
||||||
|
{
|
||||||
|
return Activity::class;
|
||||||
|
}
|
||||||
|
|
||||||
|
protected function attributeToRole(StoredObjectRoleEnum $attribute): string
|
||||||
|
{
|
||||||
|
return match ($attribute) {
|
||||||
|
StoredObjectRoleEnum::EDIT => ActivityVoter::UPDATE,
|
||||||
|
StoredObjectRoleEnum::SEE => ActivityVoter::SEE_DETAILS,
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
protected function canBeAssociatedWithWorkflow(): bool
|
||||||
|
{
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
}
|
@@ -75,7 +75,7 @@ class ActivityVoter extends AbstractChillVoter implements ProvideRoleHierarchyIn
|
|||||||
|
|
||||||
public function __construct(
|
public function __construct(
|
||||||
protected Security $security,
|
protected Security $security,
|
||||||
VoterHelperFactoryInterface $voterHelperFactory
|
VoterHelperFactoryInterface $voterHelperFactory,
|
||||||
) {
|
) {
|
||||||
$this->voterHelper = $voterHelperFactory->generate(self::class)
|
$this->voterHelper = $voterHelperFactory->generate(self::class)
|
||||||
->addCheckFor(Person::class, [self::SEE, self::CREATE])
|
->addCheckFor(Person::class, [self::SEE, self::CREATE])
|
||||||
@@ -145,7 +145,7 @@ class ActivityVoter extends AbstractChillVoter implements ProvideRoleHierarchyIn
|
|||||||
throw new \RuntimeException('Could not determine context of activity.');
|
throw new \RuntimeException('Could not determine context of activity.');
|
||||||
}
|
}
|
||||||
} elseif ($subject instanceof AccompanyingPeriod) {
|
} elseif ($subject instanceof AccompanyingPeriod) {
|
||||||
if (AccompanyingPeriod::STEP_CLOSED === $subject->getStep()) {
|
if (AccompanyingPeriod::STEP_CLOSED === $subject->getStep() || AccompanyingPeriod::STEP_DRAFT === $subject->getStep()) {
|
||||||
if (\in_array($attribute, [self::UPDATE, self::CREATE, self::DELETE], true)) {
|
if (\in_array($attribute, [self::UPDATE, self::CREATE, self::DELETE], true)) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
@@ -50,7 +50,7 @@ class ActivityContext implements
|
|||||||
private readonly TranslatorInterface $translator,
|
private readonly TranslatorInterface $translator,
|
||||||
private readonly BaseContextData $baseContextData,
|
private readonly BaseContextData $baseContextData,
|
||||||
private readonly ThirdPartyRender $thirdPartyRender,
|
private readonly ThirdPartyRender $thirdPartyRender,
|
||||||
private readonly ThirdPartyRepository $thirdPartyRepository
|
private readonly ThirdPartyRepository $thirdPartyRepository,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
public function adminFormReverseTransform(array $data): array
|
public function adminFormReverseTransform(array $data): array
|
||||||
|
@@ -56,7 +56,7 @@ class ListActivitiesByAccompanyingPeriodContext implements
|
|||||||
private readonly SocialIssueRepository $socialIssueRepository,
|
private readonly SocialIssueRepository $socialIssueRepository,
|
||||||
private readonly ThirdPartyRepository $thirdPartyRepository,
|
private readonly ThirdPartyRepository $thirdPartyRepository,
|
||||||
private readonly TranslatableStringHelperInterface $translatableStringHelper,
|
private readonly TranslatableStringHelperInterface $translatableStringHelper,
|
||||||
private readonly UserRepository $userRepository
|
private readonly UserRepository $userRepository,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
public function adminFormReverseTransform(array $data): array
|
public function adminFormReverseTransform(array $data): array
|
||||||
|
@@ -76,7 +76,7 @@ final class TranslatableActivityReasonTest extends TypeTestCase
|
|||||||
*/
|
*/
|
||||||
protected function getTranslatableStringHelper(
|
protected function getTranslatableStringHelper(
|
||||||
$locale = 'en',
|
$locale = 'en',
|
||||||
$fallbackLocale = 'en'
|
$fallbackLocale = 'en',
|
||||||
) {
|
) {
|
||||||
$prophet = new \Prophecy\Prophet();
|
$prophet = new \Prophecy\Prophet();
|
||||||
$requestStack = $prophet->prophesize();
|
$requestStack = $prophet->prophesize();
|
||||||
|
@@ -60,7 +60,7 @@ final class TranslatableActivityTypeTest extends KernelTestCase
|
|||||||
$this->assertInstanceOf(
|
$this->assertInstanceOf(
|
||||||
ActivityType::class,
|
ActivityType::class,
|
||||||
$form->getData()['type'],
|
$form->getData()['type'],
|
||||||
'The data is an instance of Chill\\ActivityBundle\\Entity\\ActivityType'
|
'The data is an instance of Chill\ActivityBundle\Entity\ActivityType'
|
||||||
);
|
);
|
||||||
$this->assertEquals($type->getId(), $form->getData()['type']->getId());
|
$this->assertEquals($type->getId(), $form->getData()['type']->getId());
|
||||||
|
|
||||||
|
@@ -138,7 +138,7 @@ final class ActivityVoterTest extends KernelTestCase
|
|||||||
Scope $scope,
|
Scope $scope,
|
||||||
Center $center,
|
Center $center,
|
||||||
$attribute,
|
$attribute,
|
||||||
$message
|
$message,
|
||||||
) {
|
) {
|
||||||
$token = $this->prepareToken($user);
|
$token = $this->prepareToken($user);
|
||||||
$activity = $this->prepareActivity($scope, $this->preparePerson($center));
|
$activity = $this->prepareActivity($scope, $this->preparePerson($center));
|
||||||
|
@@ -32,7 +32,7 @@ class TimelineActivityProvider implements TimelineProviderInterface
|
|||||||
protected EntityManagerInterface $em,
|
protected EntityManagerInterface $em,
|
||||||
protected AuthorizationHelperInterface $helper,
|
protected AuthorizationHelperInterface $helper,
|
||||||
TokenStorageInterface $storage,
|
TokenStorageInterface $storage,
|
||||||
protected ActivityACLAwareRepository $aclAwareRepository
|
protected ActivityACLAwareRepository $aclAwareRepository,
|
||||||
) {
|
) {
|
||||||
if (!$storage->getToken()->getUser() instanceof User) {
|
if (!$storage->getToken()->getUser() instanceof User) {
|
||||||
throw new \RuntimeException('A user should be authenticated !');
|
throw new \RuntimeException('A user should be authenticated !');
|
||||||
|
@@ -77,6 +77,18 @@ Choose a type: Choisir un type
|
|||||||
4 hours: 4 heures
|
4 hours: 4 heures
|
||||||
4 hours 30: 4 heures 30
|
4 hours 30: 4 heures 30
|
||||||
5 hours: 5 heures
|
5 hours: 5 heures
|
||||||
|
5 hours 30: 5 heure 30
|
||||||
|
6 hours: 6 heures
|
||||||
|
6 hours 30: 6 heure 30
|
||||||
|
7 hours: 7 heures
|
||||||
|
7 hours 30: 7 heure 30
|
||||||
|
8 hours: 8 heures
|
||||||
|
8 hours 30: 8 heure 30
|
||||||
|
9 hours: 9 heures
|
||||||
|
9 hours 30: 9 heure 30
|
||||||
|
10 hours: 10 heures
|
||||||
|
11 hours: 11 heures
|
||||||
|
12 hours: 12 heures
|
||||||
Concerned groups: Parties concernées par l'échange
|
Concerned groups: Parties concernées par l'échange
|
||||||
Persons in accompanying course: Usagers du parcours
|
Persons in accompanying course: Usagers du parcours
|
||||||
Third persons: Tiers non-pro.
|
Third persons: Tiers non-pro.
|
||||||
@@ -210,6 +222,7 @@ Documents label: Libellé du champ Documents
|
|||||||
# activity type category admin
|
# activity type category admin
|
||||||
ActivityTypeCategory list: Liste des catégories des types d'échange
|
ActivityTypeCategory list: Liste des catégories des types d'échange
|
||||||
Create a new activity type category: Créer une nouvelle catégorie de type d'échange
|
Create a new activity type category: Créer une nouvelle catégorie de type d'échange
|
||||||
|
Create a new activity in accompanying course: Créer un échange dans le parcours
|
||||||
|
|
||||||
# activity delete
|
# activity delete
|
||||||
Remove activity: Supprimer un échange
|
Remove activity: Supprimer un échange
|
||||||
|
@@ -25,7 +25,7 @@ final class AsideActivityController extends CRUDController
|
|||||||
{
|
{
|
||||||
public function __construct(
|
public function __construct(
|
||||||
private readonly AsideActivityCategoryRepository $categoryRepository,
|
private readonly AsideActivityCategoryRepository $categoryRepository,
|
||||||
private readonly Security $security
|
private readonly Security $security,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
public function createEntity(string $action, Request $request): object
|
public function createEntity(string $action, Request $request): object
|
||||||
@@ -76,7 +76,7 @@ final class AsideActivityController extends CRUDController
|
|||||||
string $action,
|
string $action,
|
||||||
$query,
|
$query,
|
||||||
Request $request,
|
Request $request,
|
||||||
PaginatorInterface $paginator
|
PaginatorInterface $paginator,
|
||||||
) {
|
) {
|
||||||
if ('index' === $action) {
|
if ('index' === $action) {
|
||||||
return $query->orderBy('e.date', 'DESC');
|
return $query->orderBy('e.date', 'DESC');
|
||||||
|
@@ -22,9 +22,9 @@ use Symfony\Component\Validator\Context\ExecutionContextInterface;
|
|||||||
class AsideActivityCategory
|
class AsideActivityCategory
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* @var Collection<AsideActivityCategory>
|
* @var Collection<int, AsideActivityCategory>
|
||||||
*/
|
*/
|
||||||
#[ORM\OneToMany(targetEntity: AsideActivityCategory::class, mappedBy: 'parent')]
|
#[ORM\OneToMany(mappedBy: 'parent', targetEntity: AsideActivityCategory::class)]
|
||||||
private Collection $children;
|
private Collection $children;
|
||||||
|
|
||||||
#[ORM\Id]
|
#[ORM\Id]
|
||||||
|
@@ -22,7 +22,7 @@ class ByActivityTypeAggregator implements AggregatorInterface
|
|||||||
{
|
{
|
||||||
public function __construct(
|
public function __construct(
|
||||||
private readonly AsideActivityCategoryRepository $asideActivityCategoryRepository,
|
private readonly AsideActivityCategoryRepository $asideActivityCategoryRepository,
|
||||||
private readonly TranslatableStringHelper $translatableStringHelper
|
private readonly TranslatableStringHelper $translatableStringHelper,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
public function addRole(): ?string
|
public function addRole(): ?string
|
||||||
|
@@ -26,7 +26,7 @@ class ByUserJobAggregator implements AggregatorInterface
|
|||||||
|
|
||||||
public function __construct(
|
public function __construct(
|
||||||
private readonly UserJobRepositoryInterface $userJobRepository,
|
private readonly UserJobRepositoryInterface $userJobRepository,
|
||||||
private readonly TranslatableStringHelperInterface $translatableStringHelper
|
private readonly TranslatableStringHelperInterface $translatableStringHelper,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
public function addRole(): ?string
|
public function addRole(): ?string
|
||||||
|
@@ -26,7 +26,7 @@ class ByUserScopeAggregator implements AggregatorInterface
|
|||||||
|
|
||||||
public function __construct(
|
public function __construct(
|
||||||
private readonly ScopeRepositoryInterface $scopeRepository,
|
private readonly ScopeRepositoryInterface $scopeRepository,
|
||||||
private readonly TranslatableStringHelperInterface $translatableStringHelper
|
private readonly TranslatableStringHelperInterface $translatableStringHelper,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
public function addRole(): ?string
|
public function addRole(): ?string
|
||||||
|
@@ -41,7 +41,7 @@ final readonly class ListAsideActivity implements ListInterface, GroupedExportIn
|
|||||||
private AsideActivityCategoryRepository $asideActivityCategoryRepository,
|
private AsideActivityCategoryRepository $asideActivityCategoryRepository,
|
||||||
private CategoryRender $categoryRender,
|
private CategoryRender $categoryRender,
|
||||||
private LocationRepository $locationRepository,
|
private LocationRepository $locationRepository,
|
||||||
private TranslatableStringHelperInterface $translatableStringHelper
|
private TranslatableStringHelperInterface $translatableStringHelper,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
public function buildForm(FormBuilderInterface $builder) {}
|
public function buildForm(FormBuilderInterface $builder) {}
|
||||||
|
@@ -27,7 +27,7 @@ class ByActivityTypeFilter implements FilterInterface
|
|||||||
public function __construct(
|
public function __construct(
|
||||||
private readonly CategoryRender $categoryRender,
|
private readonly CategoryRender $categoryRender,
|
||||||
private readonly TranslatableStringHelperInterface $translatableStringHelper,
|
private readonly TranslatableStringHelperInterface $translatableStringHelper,
|
||||||
private readonly AsideActivityCategoryRepository $asideActivityTypeRepository
|
private readonly AsideActivityCategoryRepository $asideActivityTypeRepository,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
public function addRole(): ?string
|
public function addRole(): ?string
|
||||||
|
@@ -24,7 +24,7 @@ use Symfony\Component\Security\Core\Security;
|
|||||||
final readonly class ByLocationFilter implements FilterInterface
|
final readonly class ByLocationFilter implements FilterInterface
|
||||||
{
|
{
|
||||||
public function __construct(
|
public function __construct(
|
||||||
private Security $security
|
private Security $security,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
public function getTitle(): string
|
public function getTitle(): string
|
||||||
|
@@ -29,7 +29,7 @@ class ByUserJobFilter implements FilterInterface
|
|||||||
|
|
||||||
public function __construct(
|
public function __construct(
|
||||||
private readonly TranslatableStringHelperInterface $translatableStringHelper,
|
private readonly TranslatableStringHelperInterface $translatableStringHelper,
|
||||||
private readonly UserJobRepositoryInterface $userJobRepository
|
private readonly UserJobRepositoryInterface $userJobRepository,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
public function addRole(): ?string
|
public function addRole(): ?string
|
||||||
|
@@ -29,7 +29,7 @@ class ByUserScopeFilter implements FilterInterface
|
|||||||
|
|
||||||
public function __construct(
|
public function __construct(
|
||||||
private readonly ScopeRepositoryInterface $scopeRepository,
|
private readonly ScopeRepositoryInterface $scopeRepository,
|
||||||
private readonly TranslatableStringHelperInterface $translatableStringHelper
|
private readonly TranslatableStringHelperInterface $translatableStringHelper,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
public function addRole(): ?string
|
public function addRole(): ?string
|
||||||
|
@@ -44,7 +44,7 @@ class UserMenuBuilder implements LocalMenuBuilderInterface
|
|||||||
CountNotificationTask $counter,
|
CountNotificationTask $counter,
|
||||||
TokenStorageInterface $tokenStorage,
|
TokenStorageInterface $tokenStorage,
|
||||||
TranslatorInterface $translator,
|
TranslatorInterface $translator,
|
||||||
AuthorizationCheckerInterface $authorizationChecker
|
AuthorizationCheckerInterface $authorizationChecker,
|
||||||
) {
|
) {
|
||||||
$this->counter = $counter;
|
$this->counter = $counter;
|
||||||
$this->tokenStorage = $tokenStorage;
|
$this->tokenStorage = $tokenStorage;
|
||||||
|
@@ -49,13 +49,13 @@
|
|||||||
<li>
|
<li>
|
||||||
<span>
|
<span>
|
||||||
<abbr class="referrer" title={{ 'Created by'|trans }}>{{ 'By'|trans }}:</abbr>
|
<abbr class="referrer" title={{ 'Created by'|trans }}>{{ 'By'|trans }}:</abbr>
|
||||||
<b>{{ entity.createdBy|chill_entity_render_box }}</b>
|
<b>{{ entity.createdBy|chill_entity_render_box({'at_date': entity.date}) }}</b>
|
||||||
</span>
|
</span>
|
||||||
</li>
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<span>
|
<span>
|
||||||
<abbr class="referrer" title={{ 'Created for'|trans }}>{{ 'For'|trans }}:</abbr>
|
<abbr class="referrer" title={{ 'Created for'|trans }}>{{ 'For'|trans }}:</abbr>
|
||||||
<b>{{ entity.agent|chill_entity_render_box }}</b>
|
<b>{{ entity.agent|chill_entity_render_box({'at_date': entity.date}) }}</b>
|
||||||
|
|
||||||
</span>
|
</span>
|
||||||
</li>
|
</li>
|
||||||
|
@@ -18,10 +18,10 @@
|
|||||||
<dd>{{ entity.type|chill_entity_render_box }}</dd>
|
<dd>{{ entity.type|chill_entity_render_box }}</dd>
|
||||||
|
|
||||||
<dt class="inline">{{ 'Created by'|trans }}</dt>
|
<dt class="inline">{{ 'Created by'|trans }}</dt>
|
||||||
<dd>{{ entity.createdBy }}</dd>
|
<dd>{{ entity.createdBy|chill_entity_render_box({'at_date': entity.date}) }}</dd>
|
||||||
|
|
||||||
<dt class="inline">{{ 'Created for'|trans }}</dt>
|
<dt class="inline">{{ 'Created for'|trans }}</dt>
|
||||||
<dd>{{ entity.agent }}</dd>
|
<dd>{{ entity.agent|chill_entity_render_box({'at_date': entity.date}) }}</dd>
|
||||||
|
|
||||||
<dt class="inline">{{ 'Asideactivity location'|trans }}</dt>
|
<dt class="inline">{{ 'Asideactivity location'|trans }}</dt>
|
||||||
{%- if entity.location.name is defined -%}
|
{%- if entity.location.name is defined -%}
|
||||||
|
@@ -26,7 +26,7 @@ class AsideActivityVoter extends AbstractChillVoter implements ProvideRoleHierar
|
|||||||
private readonly VoterHelperInterface $voterHelper;
|
private readonly VoterHelperInterface $voterHelper;
|
||||||
|
|
||||||
public function __construct(
|
public function __construct(
|
||||||
VoterHelperFactoryInterface $voterHelperFactory
|
VoterHelperFactoryInterface $voterHelperFactory,
|
||||||
) {
|
) {
|
||||||
$this->voterHelper = $voterHelperFactory
|
$this->voterHelper = $voterHelperFactory
|
||||||
->generate(self::class)
|
->generate(self::class)
|
||||||
|
@@ -72,21 +72,21 @@ days: jours
|
|||||||
1 hour 30: 1 heure 30
|
1 hour 30: 1 heure 30
|
||||||
1 hour 45: 1 heure 45
|
1 hour 45: 1 heure 45
|
||||||
2 hours: 2 heures
|
2 hours: 2 heures
|
||||||
2 hours 30: 2 heure 30
|
2 hours 30: 2 heures 30
|
||||||
3 hours: 3 heures
|
3 hours: 3 heures
|
||||||
3 hours 30: 3 heure 30
|
3 hours 30: 3 heures 30
|
||||||
4 hours: 4 heures
|
4 hours: 4 heures
|
||||||
4 hours 30: 4 heure 30
|
4 hours 30: 4 heures 30
|
||||||
5 hours: 5 heures
|
5 hours: 5 heures
|
||||||
5 hours 30: 5 heure 30
|
5 hours 30: 5 heures 30
|
||||||
6 hours: 6 heures
|
6 hours: 6 heures
|
||||||
6 hours 30: 6 heure 30
|
6 hours 30: 6 heures 30
|
||||||
7 hours: 7 heures
|
7 hours: 7 heures
|
||||||
7 hours 30: 7 heure 30
|
7 hours 30: 7 heures 30
|
||||||
8 hours: 8 heures
|
8 hours: 8 heures
|
||||||
8 hours 30: 8 heure 30
|
8 hours 30: 8 heures 30
|
||||||
9 hours: 9 heures
|
9 hours: 9 heures
|
||||||
9 hours 30: 9 heure 30
|
9 hours 30: 9 heures 30
|
||||||
10 hours: 10 heures
|
10 hours: 10 heures
|
||||||
1/2 day: 1/2 jour
|
1/2 day: 1/2 jour
|
||||||
1 day: 1 jour
|
1 day: 1 jour
|
||||||
|
@@ -54,7 +54,7 @@ abstract class AbstractElementController extends AbstractController
|
|||||||
$indexPage = 'chill_budget_elements_household_index';
|
$indexPage = 'chill_budget_elements_household_index';
|
||||||
}
|
}
|
||||||
|
|
||||||
if (Request::METHOD_DELETE === $request->getMethod()) {
|
if (Request::METHOD_POST === $request->getMethod()) {
|
||||||
$form->handleRequest($request);
|
$form->handleRequest($request);
|
||||||
|
|
||||||
if ($form->isSubmitted() && $form->isValid()) {
|
if ($form->isSubmitted() && $form->isValid()) {
|
||||||
@@ -198,10 +198,9 @@ abstract class AbstractElementController extends AbstractController
|
|||||||
/**
|
/**
|
||||||
* Creates a form to delete a help request entity by id.
|
* Creates a form to delete a help request entity by id.
|
||||||
*/
|
*/
|
||||||
private function createDeleteForm(): Form
|
private function createDeleteForm(): \Symfony\Component\Form\FormInterface
|
||||||
{
|
{
|
||||||
return $this->createFormBuilder()
|
return $this->createFormBuilder()
|
||||||
->setMethod(Request::METHOD_DELETE)
|
|
||||||
->add('submit', SubmitType::class, ['label' => 'Delete'])
|
->add('submit', SubmitType::class, ['label' => 'Delete'])
|
||||||
->getForm();
|
->getForm();
|
||||||
}
|
}
|
||||||
|
@@ -15,9 +15,9 @@ use Chill\BudgetBundle\Entity\ChargeKind;
|
|||||||
use Doctrine\ORM\EntityManagerInterface;
|
use Doctrine\ORM\EntityManagerInterface;
|
||||||
use Doctrine\ORM\EntityRepository;
|
use Doctrine\ORM\EntityRepository;
|
||||||
|
|
||||||
final class ChargeKindRepository implements ChargeKindRepositoryInterface
|
final readonly class ChargeKindRepository implements ChargeKindRepositoryInterface
|
||||||
{
|
{
|
||||||
private readonly EntityRepository $repository;
|
private EntityRepository $repository;
|
||||||
|
|
||||||
public function __construct(EntityManagerInterface $entityManager)
|
public function __construct(EntityManagerInterface $entityManager)
|
||||||
{
|
{
|
||||||
|
@@ -15,9 +15,9 @@ use Chill\BudgetBundle\Entity\ResourceKind;
|
|||||||
use Doctrine\ORM\EntityManagerInterface;
|
use Doctrine\ORM\EntityManagerInterface;
|
||||||
use Doctrine\ORM\EntityRepository;
|
use Doctrine\ORM\EntityRepository;
|
||||||
|
|
||||||
final class ResourceKindRepository implements ResourceKindRepositoryInterface
|
final readonly class ResourceKindRepository implements ResourceKindRepositoryInterface
|
||||||
{
|
{
|
||||||
private readonly EntityRepository $repository;
|
private EntityRepository $repository;
|
||||||
|
|
||||||
public function __construct(EntityManagerInterface $entityManager)
|
public function __construct(EntityManagerInterface $entityManager)
|
||||||
{
|
{
|
||||||
|
@@ -47,7 +47,7 @@ class SendTestShortMessageOnCalendarCommand extends Command
|
|||||||
private readonly PhoneNumberHelperInterface $phoneNumberHelper,
|
private readonly PhoneNumberHelperInterface $phoneNumberHelper,
|
||||||
private readonly ShortMessageForCalendarBuilderInterface $messageForCalendarBuilder,
|
private readonly ShortMessageForCalendarBuilderInterface $messageForCalendarBuilder,
|
||||||
private readonly ShortMessageTransporterInterface $transporter,
|
private readonly ShortMessageTransporterInterface $transporter,
|
||||||
private readonly UserRepositoryInterface $userRepository
|
private readonly UserRepositoryInterface $userRepository,
|
||||||
) {
|
) {
|
||||||
parent::__construct('chill:calendar:test-send-short-message');
|
parent::__construct('chill:calendar:test-send-short-message');
|
||||||
}
|
}
|
||||||
|
@@ -59,7 +59,7 @@ class CalendarController extends AbstractController
|
|||||||
private readonly AccompanyingPeriodRepository $accompanyingPeriodRepository,
|
private readonly AccompanyingPeriodRepository $accompanyingPeriodRepository,
|
||||||
private readonly UserRepositoryInterface $userRepository,
|
private readonly UserRepositoryInterface $userRepository,
|
||||||
private readonly TranslatorInterface $translator,
|
private readonly TranslatorInterface $translator,
|
||||||
private readonly \Doctrine\Persistence\ManagerRegistry $managerRegistry
|
private readonly \Doctrine\Persistence\ManagerRegistry $managerRegistry,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -84,7 +84,7 @@ class CalendarController extends AbstractController
|
|||||||
|
|
||||||
$form = $this->createDeleteForm($entity);
|
$form = $this->createDeleteForm($entity);
|
||||||
|
|
||||||
if (Request::METHOD_DELETE === $request->getMethod()) {
|
if (Request::METHOD_POST === $request->getMethod()) {
|
||||||
$form->handleRequest($request);
|
$form->handleRequest($request);
|
||||||
|
|
||||||
if ($form->isValid()) {
|
if ($form->isValid()) {
|
||||||
@@ -512,7 +512,6 @@ class CalendarController extends AbstractController
|
|||||||
{
|
{
|
||||||
return $this->createFormBuilder()
|
return $this->createFormBuilder()
|
||||||
->setAction($this->generateUrl('chill_calendar_calendar_delete', ['id' => $calendar->getId()]))
|
->setAction($this->generateUrl('chill_calendar_calendar_delete', ['id' => $calendar->getId()]))
|
||||||
->setMethod('DELETE')
|
|
||||||
->add('submit', SubmitType::class, ['label' => 'Delete'])
|
->add('submit', SubmitType::class, ['label' => 'Delete'])
|
||||||
->getForm();
|
->getForm();
|
||||||
}
|
}
|
||||||
|
@@ -103,7 +103,7 @@ class Calendar implements TrackCreationInterface, TrackUpdateInterface, HasCente
|
|||||||
private int $dateTimeVersion = 0;
|
private int $dateTimeVersion = 0;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var Collection<CalendarDoc>
|
* @var Collection<int, \Chill\CalendarBundle\Entity\CalendarDoc>
|
||||||
*/
|
*/
|
||||||
#[ORM\OneToMany(mappedBy: 'calendar', targetEntity: CalendarDoc::class, orphanRemoval: true)]
|
#[ORM\OneToMany(mappedBy: 'calendar', targetEntity: CalendarDoc::class, orphanRemoval: true)]
|
||||||
private Collection $documents;
|
private Collection $documents;
|
||||||
@@ -120,7 +120,7 @@ class Calendar implements TrackCreationInterface, TrackUpdateInterface, HasCente
|
|||||||
private ?int $id = null;
|
private ?int $id = null;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var Collection&Selectable<int, Invite>
|
* @var \Doctrine\Common\Collections\Collection<int, \Chill\CalendarBundle\Entity\Invite>&Selectable
|
||||||
*/
|
*/
|
||||||
#[Serializer\Groups(['read', 'docgen:read'])]
|
#[Serializer\Groups(['read', 'docgen:read'])]
|
||||||
#[ORM\OneToMany(mappedBy: 'calendar', targetEntity: Invite::class, cascade: ['persist', 'remove', 'merge', 'detach'], orphanRemoval: true)]
|
#[ORM\OneToMany(mappedBy: 'calendar', targetEntity: Invite::class, cascade: ['persist', 'remove', 'merge', 'detach'], orphanRemoval: true)]
|
||||||
@@ -143,7 +143,7 @@ class Calendar implements TrackCreationInterface, TrackUpdateInterface, HasCente
|
|||||||
private ?Person $person = null;
|
private ?Person $person = null;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var Collection<Person>
|
* @var Collection<int, Person>
|
||||||
*/
|
*/
|
||||||
#[Serializer\Groups(['calendar:read', 'read', 'calendar:light', 'docgen:read'])]
|
#[Serializer\Groups(['calendar:read', 'read', 'calendar:light', 'docgen:read'])]
|
||||||
#[Assert\Count(min: 1, minMessage: 'calendar.At least {{ limit }} person is required.')]
|
#[Assert\Count(min: 1, minMessage: 'calendar.At least {{ limit }} person is required.')]
|
||||||
@@ -157,7 +157,7 @@ class Calendar implements TrackCreationInterface, TrackUpdateInterface, HasCente
|
|||||||
private PrivateCommentEmbeddable $privateComment;
|
private PrivateCommentEmbeddable $privateComment;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @var Collection<ThirdParty>
|
* @var Collection<int, ThirdParty>
|
||||||
*/
|
*/
|
||||||
#[Serializer\Groups(['calendar:read', 'read', 'calendar:light', 'docgen:read'])]
|
#[Serializer\Groups(['calendar:read', 'read', 'calendar:light', 'docgen:read'])]
|
||||||
#[ORM\ManyToMany(targetEntity: ThirdParty::class)]
|
#[ORM\ManyToMany(targetEntity: ThirdParty::class)]
|
||||||
@@ -440,6 +440,16 @@ class Calendar implements TrackCreationInterface, TrackUpdateInterface, HasCente
|
|||||||
return $this->startDate;
|
return $this->startDate;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* get the date of the calendar.
|
||||||
|
*
|
||||||
|
* Useful for showing the date of the calendar event, required by twig in some places.
|
||||||
|
*/
|
||||||
|
public function getDate(): ?\DateTimeImmutable
|
||||||
|
{
|
||||||
|
return $this->getStartDate();
|
||||||
|
}
|
||||||
|
|
||||||
public function getStatus(): ?string
|
public function getStatus(): ?string
|
||||||
{
|
{
|
||||||
return $this->status;
|
return $this->status;
|
||||||
|
@@ -47,7 +47,7 @@ class CalendarDoc implements TrackCreationInterface, TrackUpdateInterface
|
|||||||
Calendar $calendar,
|
Calendar $calendar,
|
||||||
#[ORM\ManyToOne(targetEntity: StoredObject::class, cascade: ['persist'])]
|
#[ORM\ManyToOne(targetEntity: StoredObject::class, cascade: ['persist'])]
|
||||||
#[ORM\JoinColumn(nullable: false)]
|
#[ORM\JoinColumn(nullable: false)]
|
||||||
private ?StoredObject $storedObject
|
private ?StoredObject $storedObject,
|
||||||
) {
|
) {
|
||||||
$this->setCalendar($calendar);
|
$this->setCalendar($calendar);
|
||||||
$this->datetimeVersion = $calendar->getDateTimeVersion();
|
$this->datetimeVersion = $calendar->getDateTimeVersion();
|
||||||
|
@@ -26,7 +26,7 @@ final readonly class JobAggregator implements AggregatorInterface
|
|||||||
|
|
||||||
public function __construct(
|
public function __construct(
|
||||||
private UserJobRepository $jobRepository,
|
private UserJobRepository $jobRepository,
|
||||||
private TranslatableStringHelper $translatableStringHelper
|
private TranslatableStringHelper $translatableStringHelper,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
public function addRole(): ?string
|
public function addRole(): ?string
|
||||||
|
@@ -26,7 +26,7 @@ final readonly class ScopeAggregator implements AggregatorInterface
|
|||||||
|
|
||||||
public function __construct(
|
public function __construct(
|
||||||
private ScopeRepository $scopeRepository,
|
private ScopeRepository $scopeRepository,
|
||||||
private TranslatableStringHelper $translatableStringHelper
|
private TranslatableStringHelper $translatableStringHelper,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
public function addRole(): ?string
|
public function addRole(): ?string
|
||||||
|
@@ -28,7 +28,7 @@ final readonly class JobFilter implements FilterInterface
|
|||||||
|
|
||||||
public function __construct(
|
public function __construct(
|
||||||
private TranslatableStringHelper $translatableStringHelper,
|
private TranslatableStringHelper $translatableStringHelper,
|
||||||
private UserJobRepositoryInterface $userJobRepository
|
private UserJobRepositoryInterface $userJobRepository,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
public function addRole(): ?string
|
public function addRole(): ?string
|
||||||
|
@@ -30,7 +30,7 @@ class ScopeFilter implements FilterInterface
|
|||||||
public function __construct(
|
public function __construct(
|
||||||
protected TranslatorInterface $translator,
|
protected TranslatorInterface $translator,
|
||||||
private readonly TranslatableStringHelper $translatableStringHelper,
|
private readonly TranslatableStringHelper $translatableStringHelper,
|
||||||
private readonly ScopeRepositoryInterface $scopeRepository
|
private readonly ScopeRepositoryInterface $scopeRepository,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
public function addRole(): ?string
|
public function addRole(): ?string
|
||||||
|
@@ -37,7 +37,7 @@ class CalendarType extends AbstractType
|
|||||||
private readonly IdToUsersDataTransformer $idToUsersDataTransformer,
|
private readonly IdToUsersDataTransformer $idToUsersDataTransformer,
|
||||||
private readonly IdToLocationDataTransformer $idToLocationDataTransformer,
|
private readonly IdToLocationDataTransformer $idToLocationDataTransformer,
|
||||||
private readonly ThirdPartiesToIdDataTransformer $partiesToIdDataTransformer,
|
private readonly ThirdPartiesToIdDataTransformer $partiesToIdDataTransformer,
|
||||||
private readonly IdToCalendarRangeDataTransformer $calendarRangeDataTransformer
|
private readonly IdToCalendarRangeDataTransformer $calendarRangeDataTransformer,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
public function buildForm(FormBuilderInterface $builder, array $options)
|
public function buildForm(FormBuilderInterface $builder, array $options)
|
||||||
|
@@ -0,0 +1,48 @@
|
|||||||
|
<?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.
|
||||||
|
*/
|
||||||
|
|
||||||
|
namespace Chill\CalendarBundle\Menu;
|
||||||
|
|
||||||
|
use Chill\CalendarBundle\Security\Voter\CalendarVoter;
|
||||||
|
use Chill\MainBundle\Routing\LocalMenuBuilderInterface;
|
||||||
|
use Knp\Menu\MenuItem;
|
||||||
|
use Symfony\Component\Security\Core\Security;
|
||||||
|
|
||||||
|
final readonly class AccompanyingCourseQuickMenuBuilder implements LocalMenuBuilderInterface
|
||||||
|
{
|
||||||
|
public function __construct(private Security $security) {}
|
||||||
|
|
||||||
|
public static function getMenuIds(): array
|
||||||
|
{
|
||||||
|
return ['accompanying_course_quick_menu'];
|
||||||
|
}
|
||||||
|
|
||||||
|
public function buildMenu($menuId, MenuItem $menu, array $parameters)
|
||||||
|
{
|
||||||
|
/** @var \Chill\PersonBundle\Entity\AccompanyingPeriod $accompanyingCourse */
|
||||||
|
$accompanyingCourse = $parameters['accompanying-course'];
|
||||||
|
|
||||||
|
if ($this->security->isGranted(CalendarVoter::CREATE, $accompanyingCourse)) {
|
||||||
|
$menu
|
||||||
|
->addChild('Create a new calendar in accompanying course', [
|
||||||
|
'route' => 'chill_calendar_calendar_new',
|
||||||
|
'routeParameters' => [
|
||||||
|
'accompanying_period_id' => $accompanyingCourse->getId(),
|
||||||
|
],
|
||||||
|
])
|
||||||
|
->setExtras([
|
||||||
|
'order' => 20,
|
||||||
|
'icon' => 'plus',
|
||||||
|
])
|
||||||
|
;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
@@ -46,7 +46,7 @@ class CalendarMessage
|
|||||||
public function __construct(
|
public function __construct(
|
||||||
Calendar $calendar,
|
Calendar $calendar,
|
||||||
private readonly string $action,
|
private readonly string $action,
|
||||||
User $byUser
|
User $byUser,
|
||||||
) {
|
) {
|
||||||
$this->calendarId = $calendar->getId();
|
$this->calendarId = $calendar->getId();
|
||||||
$this->byUserId = $byUser->getId();
|
$this->byUserId = $byUser->getId();
|
||||||
|
@@ -59,7 +59,7 @@ final readonly class MSUserAbsenceReader implements MSUserAbsenceReaderInterface
|
|||||||
'alwaysEnabled' => true,
|
'alwaysEnabled' => true,
|
||||||
'scheduled' => RemoteEventConverter::convertStringDateWithoutTimezone($automaticRepliesSettings['scheduledStartDateTime']['dateTime']) < $this->clock->now()
|
'scheduled' => RemoteEventConverter::convertStringDateWithoutTimezone($automaticRepliesSettings['scheduledStartDateTime']['dateTime']) < $this->clock->now()
|
||||||
&& RemoteEventConverter::convertStringDateWithoutTimezone($automaticRepliesSettings['scheduledEndDateTime']['dateTime']) > $this->clock->now(),
|
&& RemoteEventConverter::convertStringDateWithoutTimezone($automaticRepliesSettings['scheduledEndDateTime']['dateTime']) > $this->clock->now(),
|
||||||
default => throw new UserAbsenceSyncException('this status is not documented by Microsoft')
|
default => throw new UserAbsenceSyncException('this status is not documented by Microsoft'),
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -177,7 +177,7 @@ class MapCalendarToUser
|
|||||||
User $user,
|
User $user,
|
||||||
int $expiration,
|
int $expiration,
|
||||||
?string $id = null,
|
?string $id = null,
|
||||||
?string $secret = null
|
?string $secret = null,
|
||||||
): void {
|
): void {
|
||||||
$user->setAttributeByDomain(self::METADATA_KEY, self::EXPIRATION_SUBSCRIPTION_EVENT, $expiration);
|
$user->setAttributeByDomain(self::METADATA_KEY, self::EXPIRATION_SUBSCRIPTION_EVENT, $expiration);
|
||||||
|
|
||||||
|
@@ -37,12 +37,12 @@ class RemoteEventConverter
|
|||||||
* valid when the remote string contains also a timezone, like in
|
* valid when the remote string contains also a timezone, like in
|
||||||
* lastModifiedDate.
|
* lastModifiedDate.
|
||||||
*/
|
*/
|
||||||
final public const REMOTE_DATETIMEZONE_FORMAT = 'Y-m-d\\TH:i:s.u?P';
|
final public const REMOTE_DATETIMEZONE_FORMAT = 'Y-m-d\TH:i:s.u?P';
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Same as above, but sometimes the date is expressed with only 6 milliseconds.
|
* Same as above, but sometimes the date is expressed with only 6 milliseconds.
|
||||||
*/
|
*/
|
||||||
final public const REMOTE_DATETIMEZONE_FORMAT_ALT = 'Y-m-d\\TH:i:s.uP';
|
final public const REMOTE_DATETIMEZONE_FORMAT_ALT = 'Y-m-d\TH:i:s.uP';
|
||||||
|
|
||||||
private const REMOTE_DATE_FORMAT = 'Y-m-d\TH:i:s.u0';
|
private const REMOTE_DATE_FORMAT = 'Y-m-d\TH:i:s.u0';
|
||||||
|
|
||||||
@@ -57,7 +57,7 @@ class RemoteEventConverter
|
|||||||
private readonly LocationConverter $locationConverter,
|
private readonly LocationConverter $locationConverter,
|
||||||
private readonly LoggerInterface $logger,
|
private readonly LoggerInterface $logger,
|
||||||
private readonly PersonRenderInterface $personRender,
|
private readonly PersonRenderInterface $personRender,
|
||||||
private readonly TranslatorInterface $translator
|
private readonly TranslatorInterface $translator,
|
||||||
) {
|
) {
|
||||||
$this->defaultDateTimeZone = (new \DateTimeImmutable())->getTimezone();
|
$this->defaultDateTimeZone = (new \DateTimeImmutable())->getTimezone();
|
||||||
$this->remoteDateTimeZone = self::getRemoteTimeZone();
|
$this->remoteDateTimeZone = self::getRemoteTimeZone();
|
||||||
|
@@ -351,7 +351,7 @@ class MSGraphRemoteCalendarConnector implements RemoteCalendarConnectorInterface
|
|||||||
[
|
[
|
||||||
'id' => $id,
|
'id' => $id,
|
||||||
'lastModifiedDateTime' => $lastModified,
|
'lastModifiedDateTime' => $lastModified,
|
||||||
'changeKey' => $changeKey
|
'changeKey' => $changeKey,
|
||||||
] = $this->createOnRemote($eventData, $calendar->getMainUser(), 'calendar_'.$calendar->getId());
|
] = $this->createOnRemote($eventData, $calendar->getMainUser(), 'calendar_'.$calendar->getId());
|
||||||
|
|
||||||
if (null === $id) {
|
if (null === $id) {
|
||||||
@@ -427,7 +427,7 @@ class MSGraphRemoteCalendarConnector implements RemoteCalendarConnectorInterface
|
|||||||
[
|
[
|
||||||
'id' => $id,
|
'id' => $id,
|
||||||
'lastModifiedDateTime' => $lastModified,
|
'lastModifiedDateTime' => $lastModified,
|
||||||
'changeKey' => $changeKey
|
'changeKey' => $changeKey,
|
||||||
] = $this->createOnRemote(
|
] = $this->createOnRemote(
|
||||||
$eventData,
|
$eventData,
|
||||||
$calendarRange->getUser(),
|
$calendarRange->getUser(),
|
||||||
@@ -564,7 +564,7 @@ class MSGraphRemoteCalendarConnector implements RemoteCalendarConnectorInterface
|
|||||||
[
|
[
|
||||||
'id' => $id,
|
'id' => $id,
|
||||||
'lastModifiedDateTime' => $lastModified,
|
'lastModifiedDateTime' => $lastModified,
|
||||||
'changeKey' => $changeKey
|
'changeKey' => $changeKey,
|
||||||
] = $this->patchOnRemote(
|
] = $this->patchOnRemote(
|
||||||
$calendar->getRemoteId(),
|
$calendar->getRemoteId(),
|
||||||
$eventData,
|
$eventData,
|
||||||
|
@@ -33,6 +33,6 @@ class RemoteEvent
|
|||||||
#[Serializer\Groups(['read'])]
|
#[Serializer\Groups(['read'])]
|
||||||
public \DateTimeImmutable $endDate,
|
public \DateTimeImmutable $endDate,
|
||||||
#[Serializer\Groups(['read'])]
|
#[Serializer\Groups(['read'])]
|
||||||
public bool $isAllDay = false
|
public bool $isAllDay = false,
|
||||||
) {}
|
) {}
|
||||||
}
|
}
|
||||||
|
@@ -65,7 +65,7 @@ class CalendarRangeRepository implements ObjectRepository
|
|||||||
\DateTimeImmutable $from,
|
\DateTimeImmutable $from,
|
||||||
\DateTimeImmutable $to,
|
\DateTimeImmutable $to,
|
||||||
?int $limit = null,
|
?int $limit = null,
|
||||||
?int $offset = null
|
?int $offset = null,
|
||||||
): array {
|
): array {
|
||||||
$qb = $this->buildQueryAvailableRangesForUser($user, $from, $to);
|
$qb = $this->buildQueryAvailableRangesForUser($user, $from, $to);
|
||||||
|
|
||||||
|
@@ -1 +1,2 @@
|
|||||||
import './scss/badge.scss';
|
import './scss/badge.scss';
|
||||||
|
import './scss/calendar-list.scss';
|
||||||
|
@@ -0,0 +1,26 @@
|
|||||||
|
ul.calendar-list {
|
||||||
|
list-style-type: none;
|
||||||
|
padding: 0;
|
||||||
|
& > li {
|
||||||
|
display: inline-block;
|
||||||
|
}
|
||||||
|
& > li:nth-child(n+2) {
|
||||||
|
margin-left: 0.25rem;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
div.calendar-list {
|
||||||
|
|
||||||
|
ul.calendar-list {
|
||||||
|
display: inline-block;
|
||||||
|
}
|
||||||
|
|
||||||
|
& > a.calendar-list__global {
|
||||||
|
display: inline-block;;
|
||||||
|
padding: 0.2rem;
|
||||||
|
min-width: 2rem;
|
||||||
|
border: 1px solid var(--bs-chill-blue);
|
||||||
|
border-radius: 0.25rem;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
}
|
@@ -55,7 +55,7 @@
|
|||||||
<div class="item-col">
|
<div class="item-col">
|
||||||
<ul class="list-content">
|
<ul class="list-content">
|
||||||
{% if calendar.mainUser is not empty %}
|
{% if calendar.mainUser is not empty %}
|
||||||
<span class="badge-user">{{ calendar.mainUser|chill_entity_render_box }}</span>
|
<span class="badge-user">{{ calendar.mainUser|chill_entity_render_box({'at_date': calendar.startDate}) }}</span>
|
||||||
{% endif %}
|
{% endif %}
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
@@ -132,7 +132,7 @@
|
|||||||
<li class="cancel">
|
<li class="cancel">
|
||||||
<span class="createdBy">
|
<span class="createdBy">
|
||||||
{{ 'Created by'|trans }}
|
{{ 'Created by'|trans }}
|
||||||
<b>{{ calendar.activity.createdBy|chill_entity_render_string }}</b>, {{ 'on'|trans }} {{ calendar.activity.createdAt|format_datetime('short', 'short') }}
|
<b>{{ calendar.activity.createdBy|chill_entity_render_string({'at_date': calendar.activity.createdAt}) }}</b>, {{ 'on'|trans }} {{ calendar.activity.createdAt|format_datetime('short', 'short') }}
|
||||||
</span>
|
</span>
|
||||||
</li>
|
</li>
|
||||||
{% if is_granted('CHILL_ACTIVITY_SEE', calendar.activity) %}
|
{% if is_granted('CHILL_ACTIVITY_SEE', calendar.activity) %}
|
||||||
|
@@ -89,7 +89,7 @@ class CalendarVoter extends AbstractChillVoter implements ProvideRoleHierarchyIn
|
|||||||
switch ($attribute) {
|
switch ($attribute) {
|
||||||
case self::SEE:
|
case self::SEE:
|
||||||
case self::CREATE:
|
case self::CREATE:
|
||||||
if (AccompanyingPeriod::STEP_DRAFT === $subject->getStep()) {
|
if (AccompanyingPeriod::STEP_DRAFT === $subject->getStep() || AccompanyingPeriod::STEP_CLOSED === $subject->getStep()) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -40,7 +40,7 @@ final readonly class CalendarContext implements CalendarContextInterface
|
|||||||
private PersonRepository $personRepository,
|
private PersonRepository $personRepository,
|
||||||
private ThirdPartyRender $thirdPartyRender,
|
private ThirdPartyRender $thirdPartyRender,
|
||||||
private ThirdPartyRepository $thirdPartyRepository,
|
private ThirdPartyRepository $thirdPartyRepository,
|
||||||
private TranslatableStringHelperInterface $translatableStringHelper
|
private TranslatableStringHelperInterface $translatableStringHelper,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
public function adminFormReverseTransform(array $data): array
|
public function adminFormReverseTransform(array $data): array
|
||||||
|
@@ -37,7 +37,7 @@ final readonly class AccompanyingPeriodCalendarGenericDocProvider implements Gen
|
|||||||
|
|
||||||
public function __construct(
|
public function __construct(
|
||||||
private Security $security,
|
private Security $security,
|
||||||
private EntityManagerInterface $em
|
private EntityManagerInterface $em,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@@ -36,7 +36,7 @@ final readonly class PersonCalendarGenericDocProvider implements GenericDocForPe
|
|||||||
|
|
||||||
public function __construct(
|
public function __construct(
|
||||||
private Security $security,
|
private Security $security,
|
||||||
private EntityManagerInterface $em
|
private EntityManagerInterface $em,
|
||||||
) {}
|
) {}
|
||||||
|
|
||||||
private function addWhereClausesToQuery(FetchQuery $query, ?\DateTimeImmutable $startDate = null, ?\DateTimeImmutable $endDate = null, ?string $content = null): FetchQuery
|
private function addWhereClausesToQuery(FetchQuery $query, ?\DateTimeImmutable $startDate = null, ?\DateTimeImmutable $endDate = null, ?string $content = null): FetchQuery
|
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user