Class: ActionDispatch::Routing::Mapper::TastefulResources::TastefulResource

Inherits:
Resource
  • Object
show all
Defined in:
lib/tasteful_routes/mapper.rb

Instance Method Summary collapse

Instance Method Details

#member_scopeObject



5
6
7
# File 'lib/tasteful_routes/mapper.rb', line 5

def member_scope
  "#{path.singularize}/:id"
end

#nested_scopeObject



13
14
15
# File 'lib/tasteful_routes/mapper.rb', line 13

def nested_scope
  "#{path.singularize}/:#{singular}_id"
end

#new_scope(new_path) ⇒ Object



9
10
11
# File 'lib/tasteful_routes/mapper.rb', line 9

def new_scope(new_path)
  "#{path.singularize}/#{new_path}"
end