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

Refactor/cleanup activities roster generation #884

Open
theo-o opened this issue Nov 9, 2019 · 2 comments
Open

Refactor/cleanup activities roster generation #884

theo-o opened this issue Nov 9, 2019 · 2 comments

Comments

@theo-o
Copy link
Member

theo-o commented Nov 9, 2019

What needs to be refactored

intranet/apps/eighth/views/attendance.py makes significant use of raw HTML as well as unclear forms of PDF generation.

Rationale

The file makes extensive use of reportlab (https://hg.reportlab.com/hg-public/reportlab). There are certain elements that renders unescaped user entered content. This is not ideal.

We should overhaul this code create a more modern-looking, more extensible, and more secure rendered PDF exports. Since this feature is somewhat long running, we should consider putting this in a Celery task.

@theo-o theo-o added this to the Backlog milestone Nov 9, 2019
@theo-o theo-o changed the title Refactor/cleanup activities report generation Refactor/cleanup activities roster generation Nov 9, 2019
@ghost
Copy link

ghost commented Nov 9, 2019

This might be useful for helping refactor the HTML generation (from discussion in #883): django.utils.html.format_html()

@ghost
Copy link

ghost commented Nov 9, 2019

In addition, I don't think this can be moved into a Celery task easily, since we send the PDFs directly to the user

Furthermore, there are certain changes planned in the way Ion is deployed that would make solutions such as saving the rosters to a file and providing the user with a link to them significantly more difficult.

@Laur04 Laur04 self-assigned this Aug 14, 2020
@Laur04 Laur04 modified the milestones: Backlog, Summer 2021 Apr 20, 2021
@Laur04 Laur04 modified the milestones: Summer 2021, Backlog Dec 23, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants