Class: Sluggi::Slug
- Inherits:
-
ActiveRecord::Base
- Object
- ActiveRecord::Base
- Sluggi::Slug
- Defined in:
- lib/sluggi/slug.rb
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.find_type(slug, sluggable_type) ⇒ Object
12 13 14 |
# File 'lib/sluggi/slug.rb', line 12 def find_type(slug, sluggable_type) where(slug: slug, sluggable_type: sluggable_type).order(id: :desc) end |
Instance Method Details
#to_param ⇒ Object
17 18 19 |
# File 'lib/sluggi/slug.rb', line 17 def to_param slug end |