class ActiveScaffold::Routing::Basic
Public Class Methods
Source
# File lib/active_scaffold/extensions/routing_mapper.rb, line 46 def initialize(defaults = {}) super() @defaults = defaults end
Calls superclass method
Public Instance Methods
Source
# File lib/active_scaffold/extensions/routing_mapper.rb, line 51 def call(mapper, options = {}) options = @defaults.merge(options) actions = get_actions(ACTIVE_SCAFFOLD_CORE_ROUTING, options) mapper.collection do ActiveScaffold::Routing::ACTIVE_SCAFFOLD_CORE_ROUTING[:collection].each do |name, type| mapper.match(name, via: type) if actions.include? name end end mapper.member do ActiveScaffold::Routing::ACTIVE_SCAFFOLD_CORE_ROUTING[:member].each do |name, type| mapper.match(name, via: type) if actions.include? name end mapper.get 'list', action: :index if mapper.send(:parent_resource).actions.include? :index end super if options[:association] end
Calls superclass method
ActiveScaffold::Routing::Association#call