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

Rename 'Work package settings' page as 'General' #16550

Merged
merged 10 commits into from
Sep 13, 2024

Conversation

cbliard
Copy link
Member

@cbliard cbliard commented Aug 29, 2024

Ticket

implementation ticket https://community.openproject.org/wp/57528

What are you trying to accomplish?

In Administration -> Work packages:

  • Rename "Work packages settings" as "General"
  • Add a dedicated section for progress tracking
    • This new page is primerized and behaves like before (display a warning about what happens when changing the progress calculation mode)

A new lookbook pattern page describes how to use forms: http://localhost:3000/lookbook/pages/patterns/forms

Screenshots

Before, progress calculation mode was inside the "Work package settings" administration page:

image

After, the page has been renamed "General" and the progress tracking settings have been put apart and primerized:

image

image

What approach did you choose and why?

I didn't just renamed the page title, I also renamed the menu name, controller name, and route name for consistency.

For primerizing the progress tracking form, some new helpers have been developed to make it easier to define forms when dealing with settings and to also allow mixing them with normal html tags or components. This is all documented in the form patterns page in the lookbook: http://localhost:3000/lookbook/pages/patterns/forms

Merge checklist

  • Added/updated tests
  • Added/updated documentation in Lookbook (patterns, previews, etc)
  • Tested major browsers (Chrome, Firefox, Edge, ...)

@cbliard cbliard force-pushed the impl/57528-dedicated-admin-section-for-progress-tracking branch from 8f9f0f4 to 1affbd5 Compare September 4, 2024 12:21
I did not understand what `require_admin_and_render_template` was
supposed to do. I thought it was creating some initial user and
rendering the template as a before action, but actually it only adds
some examples.

Using RSpec shared examples makes intent clearer.
The warning message is not yet implemented.
There is also a new helper to display HTML content in forms.
@cbliard cbliard force-pushed the impl/57528-dedicated-admin-section-for-progress-tracking branch from 2073a23 to 61d2daa Compare September 11, 2024 16:42
@cbliard cbliard force-pushed the impl/57528-dedicated-admin-section-for-progress-tracking branch from 8ef787b to a88260c Compare September 12, 2024 09:36
This is to display the warning when the user changes the calculation
mode and then reloads the page, or when the user changes the calculation
mode, navigates away and then goes back to the settings page.
@cbliard cbliard marked this pull request as ready for review September 12, 2024 09:52
@aaron-contreras aaron-contreras self-assigned this Sep 12, 2024
@aaron-contreras aaron-contreras self-requested a review September 12, 2024 14:42
Copy link
Contributor

@aaron-contreras aaron-contreras 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! Some updates to the lookbook docs. Everything else looks and feels solid! 🌴

Co-authored-by: Aaron Contreras <[email protected]>
@cbliard
Copy link
Member Author

cbliard commented Sep 13, 2024

@aaron-contreras I addressed all your points. Thanks for the thorough review.

@cbliard cbliard merged commit 0be0d75 into dev Sep 13, 2024
13 checks passed
@cbliard cbliard deleted the impl/57528-dedicated-admin-section-for-progress-tracking branch September 13, 2024 07:17
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.

2 participants