Class: Mizugumo::ErbGenerator
- Inherits:
-
ViewGenerator
- Object
- Rails::Generators::NamedBase
- ViewGenerator
- Mizugumo::ErbGenerator
- Includes:
- Rails::Generators::ResourceHelpers
- Defined in:
- lib/generators/rails/mizugumo/erb_generator.rb
Constant Summary
Constants inherited from ViewGenerator
ViewGenerator::HTML_VIEWS, ViewGenerator::JS_VIEWS
Instance Method Summary collapse
Methods inherited from ViewGenerator
#add_javascript, #copy_js_files, #create_root_folder
Instance Method Details
#copy_html_view_files ⇒ Object
11 12 13 14 15 16 17 18 |
# File 'lib/generators/rails/mizugumo/erb_generator.rb', line 11 def copy_html_view_files HTML_VIEWS.each do |view| filename = "#{view}.html.erb" template filename, File.join("app/views", controller_file_path, filename) end filename = "_#{singular_table_name}.html.erb" template "_row.html.erb", File.join("app/views", controller_file_path, filename) end |