Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Email notification of files that are about to expire #336

Merged
merged 7 commits into from
Dec 5, 2022

Conversation

Merkur39
Copy link
Member

@Merkur39 Merkur39 commented Dec 5, 2022

Cette PR ajoute tout le code nécessaire pour l'envoi d'un email lorsque des fichiers arrivent bientôt à expiration (délai de prévenance).
Après merge de cozy/cozy-client#1274 et #330 nous pourrons mettre à jour le fichier le manifest pour activer le service en /dev

### ✨ Features

* Add email notification when files are about to expire.

### 🔧 Tech

* Add configuration for email notifications

@Merkur39 Merkur39 force-pushed the feat/notif-webpack branch 2 times, most recently from ecae45a to f6dedd9 Compare December 5, 2022 11:31
@bundlemon
Copy link

bundlemon bot commented Dec 5, 2022

BundleMon

Files updated (1)
Status Path Size Limits
app/mespapiers.(hash).js
10.07KB (+433B +4.38%) -
Unchanged files (24)
Status Path Size Limits
vendors/mespapiers.(hash).js
2.91MB -
img/IlluPassportDate.(hash).png
38.4KB -
img/IlluPassportNumber.(hash).png
37.98KB -
img/IlluPassport.(hash).png
37.87KB -
vendors-mespapiers.(hash).(hash).min.css
35.15KB -
img/IlluIdCardNumberHelp.(hash).png
13KB -
img/IlluDriverLicenseBack.(hash).png
12.72KB -
img/IlluIdCardFront.(hash).png
12.58KB -
img/IlluIdCardBack.(hash).png
12.43KB -
img/IlluResidencePermitExpirationDateHelp.(ha
sh).png
12.17KB -
img/IlluResidencePermitNumberHelp.(hash).png
12.16KB -
img/IlluIdCardExpirationDateHelp.(hash).png
12.09KB -
img/IlluResidencePermitFront.(hash).png
12.08KB -
img/IlluDriverLicenseNumberHelp.(hash).png
11.93KB -
img/IlluDriverLicenseFront.(hash).png
11.85KB -
img/IlluDriverLicenseObtentionDateHelp.(hash)
.png
11.74KB -
img/IlluResidencePermitBack.(hash).png
11.01KB -
img/IlluVehicleRegistration.(hash).png
8.92KB -
img/IlluDiploma.(hash).png
5.59KB -
img/IlluIBAN.(hash).png
3.81KB -
img/IlluCovidVaccineCertificate.(hash).png
2.96KB -
img/IlluInvoice.(hash).png
2.33KB -
img/icon.(hash).svg
977B -
app-mespapiers.(hash).min.css
219B -

Total files change +433B +0.01%

Groups updated (1)
Status Path Size Limits
**/*.js
3.97MB (+744.63KB +22.45%) -
Unchanged groups (2)
Status Path Size Limits
img/.
284.56KB -
**/*.css
35.37KB -

Final result: ✅

View report in BundleMon website ➡️


Current branch size history | Target branch size history

src/helpers/service.spec.js Show resolved Hide resolved
package.json Show resolved Hide resolved
src/notifications/index.js Show resolved Hide resolved
src/notifications/index.js Show resolved Hide resolved
src/constants.js Show resolved Hide resolved
src/targets/services/expiration.js Show resolved Hide resolved
Copy link
Contributor

@JF-Cozy JF-Cozy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

on semble assez aligné sur ce qu'il faut modifier, sous réserve de faire les modifs je valide pour te débloquer si besoin ;)

- Better date management.
- The `getfilesNeedNotified` function now returns
the normalized expiration and notification date,
in addition to the file itself.
Added devDeps handlebars-layouts, mailhog & raw-loader.

Added `uglify-js` resolution, the latter is a sub-dependency
of `handlebars` and `html-minifier`,
and it causes import problems.
One approach is to use `Terser`
(see https://www.npmjs.com/package/terser)
Using the `raw-loader` loader in the webpack config
does not work, except when using the "inline" style, as here.
Updates all notified files so that they are no longer notified
@Merkur39 Merkur39 merged commit 9333a7a into master Dec 5, 2022
@Merkur39 Merkur39 deleted the feat/notif-webpack branch December 5, 2022 16:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants