Class: ActiveRecord::Generators::HttpUtilitiesGenerator
Instance Method Summary
collapse
#model_exists?, #model_path
Instance Method Details
#copy_proxy_migration ⇒ Object
11
12
13
|
# File 'lib/generators/active_record/http_utilities_generator.rb', line 11
def copy_proxy_migration
migration_template "migration.rb", "db/migrate/create_proxies" unless model_exists?('proxy') && behavior == :invoke
end
|
#copy_proxy_model ⇒ Object
15
16
17
|
# File 'lib/generators/active_record/http_utilities_generator.rb', line 15
def copy_proxy_model
template "proxy.rb", "app/models/proxy.rb" unless model_exists?('proxy') && behavior == :invoke
end
|