Class: Liquid::Generators::DropGenerator
- Inherits:
-
Rails::Generators::NamedBase
- Object
- Rails::Generators::NamedBase
- Liquid::Generators::DropGenerator
- Defined in:
- lib/rails/generators/liquid/drop_generator.rb
Instance Method Summary collapse
Instance Method Details
#create_drop ⇒ Object
13 14 15 16 17 18 |
# File 'lib/rails/generators/liquid/drop_generator.rb', line 13 def create_drop @model = file_name.camelize.constantize @attributes = @model.attribute_names @associations = @model.reflect_on_all_associations template "drop.rb", "app/drops/#{file_name}_drop.rb" end |