Commit graph

271 commits

Author SHA1 Message Date
seb-by-ouidou
9b26bf911c fix: fixes after tchak s review 2023-10-03 13:51:57 +02:00
seb-by-ouidou
44b4b5d0ab feat: rename admins_group_manager to gestionnaire 2023-10-03 13:51:57 +02:00
seb-by-ouidou
e2f792b44b FEAT: init admins group 2023-10-03 13:51:57 +02:00
Christophe Robillard
20d70d2b1c notify admin with service without siret 2023-09-29 11:37:34 +02:00
Martin
bf6b5ea963 amelioration(mailer.logo): utilise procedure_logo_url pour afficher le logo dans les mails 2023-08-14 13:09:05 +02:00
Martin
a3c6a2c46f correctif(dolist): utilise des liens vers les logos des procedures plutôt que des attachements.inlined 2023-08-14 13:09:05 +02:00
Martin
ce9dbed663 amelioration(NotificationMailer): sort la creation des commentaire sur la messagerie du mailer [trop de prob possible sinon: au retry on dupliquait les commenaitres, si le mail foirait, on commentait pas etc...] 2023-07-11 15:11:40 +02:00
Martin
23fb7e812e amelioration(a11y): utilise une balise <p> pour passer a la ligne avec un espace supplémentaire plutôt que deux <br> 2023-07-11 15:11:40 +02:00
Colin Darie
e1b21f980f
feat(sva): pending correction email mention sva/svr 2023-07-11 10:02:47 +02:00
Colin Darie
18096a709b chore(email): tag sentry mailers 2023-06-26 17:28:27 +02:00
Paul Chavard
e509ff1717 fix(dossier): do not send notifcations to deleted users 2023-06-21 09:52:38 +01:00
Martin
9b2d05b8a1 amelioration(email_event): re-lever une erreur dans un rescue_from ne la fait pas remonter. change de stratégie pour savoir si oui ou non un mail a ete envoye avec success. 2023-06-20 13:39:29 +02:00
Colin Darie
9565267170
feat(dossier): notify user by email about pending corrections 2023-06-02 16:16:13 +02:00
Martin
534ce34f87 amelioration(Dolist::ApiSender): lève une Dolist::IgnorableError afin de l'inscrire dans l'historique des EmailEvent 2023-04-19 11:22:13 +02:00
Lisa Durand
e1260a3df8 fix wrong encoding of special character in email notification subject 2023-03-31 16:58:41 +02:00
simon lehericey
ca63cc34ab feat(token depreciation): add mail alert 2023-03-16 16:16:45 +01:00
Eric Leroy-Terquem
f6c4986e86 feat(groupe instructeur mailer): do not notify group when instructeurs removed 2023-03-02 09:46:58 +01:00
Eric Leroy-Terquem
343cb5fce6 feat(groupe instructeur mailer): add emailing to added instructeurs 2023-02-20 15:41:19 +01:00
Eric Leroy-Terquem
a46faf8cdf feat(groupe instructeur mailer): make two kind of notifications for removed instructeur 2023-02-16 10:37:04 +01:00
Eric Leroy-Terquem
5be58c8223 refactor(groupe instructeur mailer): rename mailer methods 2023-02-16 10:37:04 +01:00
Eric Leroy-Terquem
cbf072961c feat(groupe instructeur mailer): add emailing to removed instructeurs 2023-02-16 10:37:04 +01:00
Colin Darie
5526cb5173 fix(mail): limit generated subjects to 100 characters 2023-02-09 17:39:56 +01:00
Colin Darie
8a859402ad chore(mailer): setup Services Publics+ by env var so instances can have their owns 2023-02-09 10:47:53 +01:00
Colin Darie
d78c75620a chore(mailer): services publics + only for Termine "states" 2023-02-09 10:47:53 +01:00
Eric Leroy-Terquem
0e60d6bb11 clean(groupe instructeurs): remove unused method 2023-02-08 10:36:42 +01:00
Eric Leroy-Terquem
6cbc514d56 feat(groupe instructeurs): remove mailing when add instructeurs 2023-02-08 10:36:42 +01:00
Martin
1ee67d511d amelioration(mails): permet a nos mails d'inclure des balises <a> pour faciliter l'usage des mail envoyés 2023-02-06 11:01:28 +01:00
Martin
4990c448b1 amelioration(mail.prioritaire): en plus des mails de device, ajoute la gestion du routage des autres mails critique 2023-01-24 11:49:53 +01:00
Colin Darie
784b0458fe feat(dolist): consolidate dispatched events with delivered emails 2023-01-18 09:56:40 +01:00
Colin Darie
6615165b2e refactor(mailer): extract dolist logic into its concern 2023-01-17 14:26:11 +01:00
Colin Darie
ce7e674159 feat(mailer): make errors interceptable by jobs so they will retry
Comme on intercepte chaque `StandardError` pour le monitoring des mails
en erreur, l'erreur n'était plus visible par le job, et les emails
étaient perdus.

A la place on re-raise une autre erreur pour que le job échoue afin de
retry plus tard. Pour ne pas être "avalée" par le rescue_from,
cette erreur doit héritée d'`Exception` plutôt que `StandardError`.

NB: il faudrait parvenir à écrire un test pour vérifier ce comportement.

Pour être vérifié en dev, il faut activer `raise_delivery_errors`
comme en production.
2023-01-17 14:26:11 +01:00
Colin Darie
01f227e1c7 fix(mailer): dolist header in devise mailer 2023-01-11 18:52:14 +01:00
Martin
3e6b82ed9e amelioration(safe_mailer): ajoute au manager la fonction pour configurer le routage des mails sur un fournisseur unique
Update app/mailers/devise_user_mailer.rb

Co-authored-by: LeSim <mail@simon.lehericey.net>
2023-01-11 17:32:24 +01:00
Martin
d535735155 amelioration(devise_mailer): oriente les mails de devise vers un fournisseur quand cela est configuré 2023-01-11 17:13:05 +01:00
Colin Darie
d911bc02c0 refactor(mailer): set dolist header in DeviseUserMailer 2023-01-10 16:07:35 +01:00
Colin Darie
5ae5de0d9c refactor(email): log event when error occurs before recipients was set 2023-01-10 16:07:35 +01:00
Colin Darie
b9c1799e60 refactor(mailer): shared error concern 2023-01-10 16:07:35 +01:00
Colin Darie
0a22c1d2f0 chore(email): log smtp errors 2023-01-10 16:07:35 +01:00
Sébastien Carceles
20136b7ac8
feat(demarche): create and prefill a dossier with POST request (#8233)
* add base controller for public api

* add dossiers controller with basic checks

* create the dossier

* ensure content-type is json

* prefill dossier with given values

* mark a dossier as prefilled

When a dossier is prefilled, it's allowed not to have a user.

Plus, we add a secure token to the dossier, which we will need later to set a
user after sign in / sign up.

* set user as owner of an orphan prefilled dossier

When a visitor comes from the dossier_url answered by the public api,
the dossier is orphan:
- when the user is already authenticated: they become the owner
- when the user is not authenticated: they can sign in / sign up / france_connect
and then they become the owner

So here is the procedure:
- allow to sign in / sign up / france connect when user is unauthenticated
- set dossier ownership when the dossier is orphan
- check dossier ownership when the dossier is not
- redirect to brouillon path when user is signed in and owner

* mark the dossier as prefilled when it's prefilled
(even with a GET request, because it will be useful later on, for
exmample in order to cleanup the unused prefilled dossiers)

* system spec: prefilling dossier with post request
2023-01-03 14:46:10 +01:00
Paul Chavard
4a4ce67ef6 fix(dossier): explicitly send draft notification email 2022-12-26 22:02:33 +00:00
Paul Chavard
f49a1baeec refactor(groupe_instructeur): remove mailer should take a list of instructeurs 2022-12-06 12:01:54 +01:00
Paul Chavard
e7766694d3 fix(messages): retry stale blobs 2022-11-02 09:19:51 +01:00
simon lehericey
097082afc9 fix(dolist): reduce message name variability 2022-10-20 15:29:56 +02:00
simon lehericey
0e75f9960b fix: send_dossier_decision preview 2022-10-06 17:43:09 +02:00
Kara Diaby
f8d4644f73 models 2022-09-02 16:23:27 +02:00
Martin
2f5528398f feat(manager#outdated_procedure): allow super admin to enable procedure_expires_when_termine_enabled for old procedure
revew(typo): various typo, tx christophe :-)

fix(spec): due to typo fixes
2022-08-24 13:10:48 +02:00
Martin
7fb85c97cb feat(Administrateur::ArchivesControllers): add archives #index and #create for admin 2022-07-04 14:18:46 +02:00
Martin
274b5eab2e feat(invite): wrap invitation with targeted_user_links 2022-06-17 16:44:37 +02:00
Martin
8b487c847b fix(instructeurs/avis#revive): ArgumentError on AvisMailer.avis_invitation 2022-06-14 08:41:09 +02:00
Martin
cb890343ff feat(targeted_user_link): add targeted user link to wrap expert invitation in order to avoid access issue when the expert is connected with another account
feat(user.merge): ensure to merge user.targeted_user_link

Update app/models/targeted_user_link.rb

Co-authored-by: LeSim <mail@simon.lehericey.net>

Update app/models/targeted_user_link.rb

Co-authored-by: LeSim <mail@simon.lehericey.net>

Update app/models/targeted_user_link.rb

Co-authored-by: LeSim <mail@simon.lehericey.net>

feat(db/create_targeted_user_links): ensure not null with fk
2022-05-31 14:50:31 +02:00