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

PDF export for time sheets #17316

Merged
merged 58 commits into from
Dec 11, 2024
Merged

Conversation

as-op
Copy link
Contributor

@as-op as-op commented Dec 2, 2024

Ticket

https://community.openproject.org/projects/stream-time-and-costs/work_packages/59824

What are you trying to accomplish?

Export logged time as PDF time sheets

Screenshots

button Button (in Figma this is in a drop down menu, should be done in a separate PR, here menu is out of scope)
worker File is created in the background worker
pdf The PDF

What approach did you choose and why?

  • Adapting from the XLS export for a cost query
  • Reusing of existing PDF code (e.g. for the cover page)

Merge checklist

  • Export skeleton PDF via the background worker and a button in the cost report view
  • Don't navigate to .../job_statuses/xyz, use the "inline" progress dialog
  • Apply styling
  • Ellipse text in wp subject cell (missing prawn table support)
  • Table splitting on page breaks with merged rows (missing prawn-table support for splitting)
  • Use cost report query filter & data
  • Use new start_time and time_zone for time on "time" column
  • If an entry has its end time on a different day than the start date, it is indicated by a (+days), e.g. "23:00 - 04:00 (+1d)"
  • Verify used values for header/footer/cover page vs wireframes
  • Verify column widths with translations
  • Added/updated tests
  • Added/updated documentation in Lookbook (patterns, previews, etc)
  • Tested major browsers (Chrome, Firefox, Edge, ...)

as-op and others added 27 commits November 25, 2024 10:17
…heets' into epic/26180-pdf-export-for-time-sheets
…heets' into epic/26180-pdf-export-for-time-sheets
@as-op as-op marked this pull request as ready for review December 9, 2024 11:35
Copy link
Contributor

@klaustopher klaustopher left a comment

Choose a reason for hiding this comment

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

Great job 👏

I left some comments inline. We seem to work under the assumption that the Timesheet is the only PDF export we will ever generate for reports. I think it will be easy enough to add another parameter that tells us what type of PDF we want to generate, so that there is no need to do anything right now.

All in all, awesome work. Especially the edge case handling for weird PDF behavior.

@as-op as-op merged commit 3fc1250 into dev Dec 11, 2024
14 checks passed
@as-op as-op deleted the feature/59824-export-cost-report-as-timesheet-pdf branch December 11, 2024 07:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants