thoughtbot / thoughtbot/administrate

incorrect files location when generated dashboard/controller for namespaced models

Open
#1,124 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug generators
Dominant language
JavaScript
Stars
6k
Forks
1.1k
PR merge metrics
No merged PRs in 30d

Description

rails g administrate:dashboard Name/Model

actual

      create  app/dashboards/model_dashboard.rb
      create  app/controllers/admin/model_controller.rb

expected

      create  app/dashboards/name/model_dashboard.rb
      create  app/controllers/admin/name/model_controller.rb

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Run rails g administrate:dashboard Name/Model and trace the dashboard and controller generator entry points that produce the reported paths. Done means the generated files are placed under app/dashboards/name/ and app/controllers/admin/name/ for a namespaced model, with the existing generator behavior preserved for unnamespaced models.

Written by the indexing model from the issue text.

Assessment

Tech stack
rails, ruby
Domain
backend, tooling
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Clearly specified
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.