mirror of
https://github.com/TracksApp/tracks.git
synced 2026-02-10 17:34:22 +01:00
Add Tag#label method
This commit is contained in:
parent
f56fc1945c
commit
95a4ed6e4a
4 changed files with 10 additions and 2 deletions
|
|
@ -26,4 +26,8 @@ class Tag < ActiveRecord::Base
|
|||
taggings.create :taggable => taggable, :user => user
|
||||
end
|
||||
|
||||
def label
|
||||
@label ||= name.gsub(' ', '-')
|
||||
end
|
||||
|
||||
end
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue