Class: ActiveAdmin::Generators::ResourceGenerator
- Inherits:
-
Rails::Generators::NamedBase
- Object
- Rails::Generators::NamedBase
- ActiveAdmin::Generators::ResourceGenerator
- Defined in:
- lib/generators/active_admin/resource/resource_generator.rb
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.source_root ⇒ Object
6 7 8 |
# File 'lib/generators/active_admin/resource/resource_generator.rb', line 6 def self.source_root @_active_admin_source_root ||= File.("../templates", __FILE__) end |
Instance Method Details
#generate_config_file ⇒ Object
10 11 12 |
# File 'lib/generators/active_admin/resource/resource_generator.rb', line 10 def generate_config_file template "admin.rb", "app/admin/#{file_path.gsub('/', '_').pluralize}.rb" end |