[openstreetmap/openstreetmap-website] Split changeset comment handling into its own controller (#2050)
Andy Allan
notifications at github.com
Wed Nov 7 10:30:29 UTC 2018
This PR refactors changeset comment handling into its own controller, and renames the controller methods accordingly. It doesn't change the API - that can wait for a future API version.
@Nikerabbit this PR contains translation key renaming:
* `changeset.rss.title_all` -> `changeset_comments.index.title_all`
* `changeset.rss.title_particular` -> `changeset_comments.index.title_particular`
* `changeset.rss.comment` -> `changeset_comments.comment.comment` and also `changeset_comments.comments.comment`
* `changeset.rss.commented_at_by_html` -> `changeset_comments.comment.commented_at_by_html`
For clarity, `changeset.rss.commented_at_html` and `changeset.rss.full` are removed as they were unused.
You can view, comment on, or merge this pull request online at:
https://github.com/openstreetmap/openstreetmap-website/pull/2050
-- Commit Summary --
* Split changeset comment handling into a changeset_comments controller
* Rename comment to create
* Rename comments_feed to index
* Rename hide_comment and unhide_comment to destroy and restore
* Use relative translations for changeset comments
* Reduce the max class length after splitting the changeset comments controller tests out
-- File Changes --
M .rubocop_todo.yml (2)
A app/controllers/changeset_comments_controller.rb (125)
M app/controllers/changeset_controller.rb (132)
R app/views/changeset_comments/_comment.html.erb (4)
R app/views/changeset_comments/_comments.rss.builder (2)
R app/views/changeset_comments/index.rss.builder (4)
A app/views/changeset_comments/timeout.atom.builder (12)
A app/views/changeset_comments/timeout.html.erb (1)
M config/locales/en.yml (14)
M config/routes.rb (10)
A test/controllers/changeset_comments_controller_test.rb (251)
M test/controllers/changeset_controller_test.rb (243)
-- Patch Links --
https://github.com/openstreetmap/openstreetmap-website/pull/2050.patch
https://github.com/openstreetmap/openstreetmap-website/pull/2050.diff
--
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/openstreetmap/openstreetmap-website/pull/2050
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstreetmap.org/pipermail/rails-dev/attachments/20181107/aad0c384/attachment.html>
More information about the rails-dev
mailing list