-
Notifications
You must be signed in to change notification settings - Fork 194
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
Clean up legacy code for document collections #8442
Clean up legacy code for document collections #8442
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just one query on this feature test, are we supposed to remove these feature tests?
or just remove annotations @javascript @design-system-wip?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The deleted tests are for the old "half-way to design system" pages where it was all done with Javascript on a single page. The functionality is covered by the other tests in the file that were added when we updated the flow with extra pages.
I'm not sure if we are planning to remove all files under If that is the case then we should also delete these files at this point:
|
Just a query on the status of this, and one other, PR: is this one based on PR#8415 ("Prepare release for document collections") and can that one therefore be closed? This seems to be an extended duplicate of that work. |
By necessity, this PR had to be branched off of PR#8415 (since we can't cleanup until that work has been merged). The intention is that once that PR is merged this one can be rebased off of the latest main, and so will only contain the "remove" commits. |
It would be nice to remove unnecessary files as and when we go (ultimately leading to the removal of everything under In this case those files are also used by some files under |
Yeah that's fine, as long as it's accounted for somewhere. I traced some of that back to Statistics Announcements as well: it looked like there are some partials in there - that call the JS above - that should be removed but it looks like you have caught those in that ticket. 👍 |
LGTM |
Remove the POST endpoint for adding pages that are not published by Whitehall to a document collection group. Removes the: - route - controller action. There were no controller tests for this action.
Remove the POST endpoint for updating the memberships of a document collection group. Removes the: - route - controller action - controller actions tests.
Rails will render the appropriate view by default, so there's no need to call render from within the controller action method to render the default view. In `confirm_destroy`, the return is unnecessary now that there is no more code after the potential redirect.
01214e3
to
d1c66be
Compare
- Removed redundant views that were only used in the legacy views - Removed redundant destroy endpoint in routes and reorganised the routes config Along with some minor refactorings
163e407
to
2004cdf
Compare
Added further removals to the views, removed an unused route, and fixed the route referrals in the code. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
What
Remove vestigial code that has been left behind after the migration of the document collection pages to the GOV.UK Design System.
Trello
Trello card.
Follow these steps if you are doing a Rails upgrade.