class AuthorizeNet::Generators::SimGenerator

Public Instance Methods

manifest() click to toggle source
# File lib/generators/authorize_net/sim/sim_generator.rb, line 32
def manifest
  copy_file "README-AuthorizeNet", "README-AuthorizeNet"
  empty_directory "app/views/#{file_name}"
  copy_file "payment.rails3.erb", "app/views/#{file_name}/payment.erb"
  copy_file "thank_you.erb", "app/views/#{file_name}/thank_you.erb"
  copy_file "layout.erb", "app/views/layouts/authorize_net.erb"
  template "config.yml.rails3.erb", "config/authorize_net.yml"
  copy_file "initializer.rb", "config/initializers/authorize_net.rb"
  template "controller.rb.erb", "app/controllers/#{file_name}_controller.rb"
  route "match '/#{plural_name}/thank_you', :to => '#{file_name}#thank_you', :as => '#{singular_name}_thank_you', :via => [:get]"
  route "match '/#{plural_name}/payment', :to => '#{file_name}#payment', :as => '#{singular_name}payment', :via => [:get]"
end