Skip to content
This repository has been archived by the owner on Nov 13, 2020. It is now read-only.

Missing nomenclature 'accessoire de cuisine' et 'bureau' #101

Open
julbrs opened this issue Jan 15, 2020 · 2 comments
Open

Missing nomenclature 'accessoire de cuisine' et 'bureau' #101

julbrs opened this issue Jan 15, 2020 · 2 comments
Assignees
Labels
bug Something isn't working

Comments

@julbrs
Copy link
Member

julbrs commented Jan 15, 2020

Describe the bug
Sonia add some nomenclature but she can't see it
To Reproduce
Steps to reproduce the behavior:

  1. go there https://alpha.montessori-ressources.net/nomenclature
  2. search for cuisine
  3. wait for the nomenclaure
  4. very long time to show the little images
  5. cant download the pdf (error max exec time)

Expected behavior

  1. faster time to show the little images
  2. can see the pdf

This is linked to big images.

Screenshots:

image

@julbrs julbrs added the bug Something isn't working label Jan 15, 2020
@julbrs julbrs added this to the RTC - Official Launch milestone Jan 15, 2020
@julbrs julbrs self-assigned this Jan 15, 2020
@julbrs
Copy link
Member Author

julbrs commented Jan 20, 2020

OK worked a bit on this issue:

  • one nomenclature contains 10 image of around 4 Mb each. So we are speaking of generating a pdf file of around 40 Mb. This is way too big.

We need to think about it:

  • Do we really need to generate a pdf of just generate a page then the user will print it ?
  • Do we really want to store the maximum resolution possible or do we want to limit what we store ?
  • If we limit then it is a job to be done by the front end part, the back end can just prevent for big images.

@julbrs
Copy link
Member Author

julbrs commented Jan 21, 2020

Goal is to be able to print at 300dpi max and we know the image size (14cmx14cm). So it represent in pixels around 1650x1650 max.

We can work on the image to resize it to 1650x1650 (keeping aspect ratio)

This lib is doing it https://packagist.org/packages/gumlet/php-image-resize

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant