Module: Taggable::Asset::InstanceMethods

Defined in:
lib/taggable/asset.rb

Instance Method Summary collapse

Instance Method Details

#keywordsObject

just keeping compatibility with page tags so as to present the same interface



23
24
25
# File 'lib/taggable/asset.rb', line 23

def keywords 
  self.attached_tags.map {|t| t.title}.join(', ')
end

#keywords=(somewords = "") ⇒ Object



27
28
29
# File 'lib/taggable/asset.rb', line 27

def keywords=(somewords="")
  self.attached_tags = Tag.from_list(somewords) || []
end

#keywords_before_type_castObject

called by form_helper



31
32
33
# File 'lib/taggable/asset.rb', line 31

def keywords_before_type_cast   # called by form_helper
  keywords
end