Skip to content

Custom Field Customization (4/4): Admin UI to manage custom fields for projects - #26277

Merged
klaustopher merged 18 commits into
custom-field-customization-frontend-restrictionsfrom
custom-field-customization-admin
Oct 26, 2026
Merged

klaustopher merged 18 commits into
custom-field-customization-frontend-restrictionsfrom
custom-field-customization-admin

Conversation

@klaustopher

Copy link
Copy Markdown
Contributor

Ticket

https://community.openproject.org/projects/AUTOWORK/work_packages/AUTOWORK-303/activity

What are you trying to accomplish?

  • Admin UI to manage custom field values per project

AI involvement

Collaborative – AI generated a substantial part of the code; I reviewed and understand every line.

Merge checklist

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

@klaustopher
klaustopher added this pull request to stack #26278 October 23, 2026 14:07
@github-actions github-actions Bot added the ai: Collaborative 💻 AI generated a substantial part of the code; A human reviewed and understands every line. label Oct 23, 2026
@klaustopher
klaustopher force-pushed the custom-field-customization-admin branch 3 times, most recently from d72b7e5 to e15916a Compare October 26, 2026 10:48
@oliverguenther

Copy link
Copy Markdown
Member

Product feedback:

Would be nice to have a quick filter here for "any values customized". Not sure if you talked about this already.
2026-10-26_11-48-24@2x

@klaustopher
klaustopher force-pushed the custom-field-customization-admin branch from e15916a to b81301c Compare October 26, 2026 10:53
The new Admin::CustomFields::Projects module shadowed the top-level
Projects components inside Admin::CustomFields, breaking the project
attribute mapping page.
@oliverguenther

Copy link
Copy Markdown
Member
2026-10-26_12-33-11.mp4

In the admin UI: Searching for values and then paginating removes the filter text

Comment thread app/components/admin/custom_fields/projects/values_component.rb Outdated
Comment thread app/components/admin/custom_fields/projects/row_component.rb Outdated
Comment thread app/controllers/admin/settings/work_package_custom_fields_controller.rb Outdated

@oliverguenther oliverguenther left a comment •

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Found only the pagination issue and some smaller N+1 issues. Did a smoke test of the main paths for both hierarchy and list fields. The implementation appears to be working fine 👏

The feature is marked as premium, but no enterprise guards exist yet as far as I can tell

Adds an admin-only project filter for project-specific values, which
is not offered in any filter menu. The projects tab of a work package
custom field builds its list from a ProjectQuery with the standard
filters param, so the name filter and the quick filter survive
pagination.
@klaustopher

Copy link
Copy Markdown
Contributor Author

In the admin UI: Searching for values and then paginating removes the filter text

I switched to a proper ProjectQuery with a custom filter. This survives pagination.

Hierarchy item depths on the project values page are derived from the
pre-ordered items instead of the closure table per item, and the
enabled value counts of the projects tab are loaded in one query.
@github-actions

Copy link
Copy Markdown

Warning

Flaky specs

  • rspec ./spec/features/work_packages/table/delete_work_packages_with_descendants_spec.rb[1:2:1]
🤖 Ask Copilot to investigate

Copy the prompt below into a new comment on this PR to delegate the investigation to GitHub Copilot. It will look into the flakiness and open a separate pull request with you as reviewer.

@copilot The following spec(s) are flaky in CI (first seen on PR #26277, linked for reference only):

- `rspec ./spec/features/work_packages/table/delete_work_packages_with_descendants_spec.rb[1:2:1]`

Treat this as a standalone task, unrelated to PR #26277. Create a new branch from origin/dev and open a new pull request targeting dev — do not stack it on PR #26277 or reuse that branch.

Follow the playbook in docs/development/testing/handling-flaky-tests/README.md to find the root cause and fix the underlying race — do not skip, delete, or weaken the spec to make it pass; disabling is a last resort per the playbook, and only with a bug ticket. Verify the fix by running the spec(s) repeatedly (e.g. `script/bulk_run_rspec --run-count 10`).

If you cannot reproduce the flake or are not confident in a fix after reasonable investigation, do not fabricate a change or skip the spec to force CI green. Instead, leave the pull request in draft and document what you tried, the suspected cause, and any leads in its description, then assign @klaustopher to take over.

Once the fix is verified, title the PR after the spec(s) it fixes, and use the PR description to explain the root cause, how the change resolves it, and the before/after results. Label the PR `flaky-spec`, assign @klaustopher, and request a review from @klaustopher.
On every commit, set @klaustopher as the sole co-author with a `Co-authored-by:` trailer (use their GitHub no-reply email so it links to their account), so it is traceable who dispatched the fix.

@klaustopher
klaustopher merged commit ad1f199 into dev Oct 26, 2026
26 checks passed
@klaustopher
klaustopher deleted the custom-field-customization-admin branch October 26, 2026 14:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ai: Collaborative 💻 AI generated a substantial part of the code; A human reviewed and understands every line. needs review

Development

Successfully merging this pull request may close these issues.

2 participants