Skip to content

[FND-188] Implement services / dialog to preview changes when switching variants - #24589

Draft
dfriquet wants to merge 6 commits into
implementation/fnd-187-run-the-type-switch-in-a-background-jobfrom
implementation/fnd-188-preview-changes-when-switching-variants
Draft

[FND-188] Implement services / dialog to preview changes when switching variants#24589
dfriquet wants to merge 6 commits into
implementation/fnd-187-run-the-type-switch-in-a-background-jobfrom
implementation/fnd-188-preview-changes-when-switching-variants

Conversation

@dfriquet

@dfriquet dfriquet commented Aug 4, 2026

Copy link
Copy Markdown
Contributor

Ticket

https://community.openproject.org/wp/FND-188

What are you trying to accomplish?

Tells the administrator what switching a project's type variant will do, before they apply it.

  • The switch dialog gains a live report: how many work packages are re-typed, which fields stop being shown and how much data sits behind them, which fields become available, and which statuses in use are absent from the target's workflow.

Stacked on the FND-198 branch. Base it back to dev once that merges.

Screenshots

Fresh dialog Refreshed dialog collapsed with counters Refreshed dialog expanded with counters

What approach did you choose and why?

  • Three sections, all collapsed, each headed by a counter. Custom fields carry a value count; built-ins and embedded tables don't, because only custom fields hold data the switch hides.
  • Until a different variant is chosen the report is a single line, and no queries run.
  • Projects::Types::Switch::Impact is a plain query object, not a service: nothing mutates, so validation, on_success/on_failure and a persist step would all go unused. Five queries, independent of work package count.
  • Nothing here knows whether it lives in a dialog or on a page. Still open with the designer, so the dialog's content moved into a chrome-free SwitchFieldsComponent.

Merge checklist

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

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.

1 participant