Sha256: f17d05832e0d6edd29befcbb8a2f709c7ba5775b019ce18e45de49445454741e
Contents?: true
Size: 315 Bytes
Versions: 4
Compression:
Stored size: 315 Bytes
Contents
class Tag < ActiveRecord::Base attr_accessible :name validates_presence_of :name has_many :taggings has_many :posts, :through => :taggings, :source_type => "Post", :source => :taggable autocomplete :name private def format_label_for_autocomplete "#{name}: #{taggings.count}" end end
Version data entries
4 entries across 4 versions & 2 rubygems