Displaying 1 result from an estimated 1 matches for "on_unique".
Did you mean:
bb_unique
2006 May 19
0
Works in model but not in mixin
...ever, the
following method:
def add_tags(list)
Tag.transaction do
Tag.parse(list).each do |name|
if acts_as_taggable_options[:from]
send(acts_as_taggable_options[:from]).tags.find_or_create_by_name(name).on(self)
else
Tag.find_or_create_by_name(name).on_unique(self)
end
end
end
end
Only works if placed in my model (that has the acts_as_taggable helper)
or in a controller. If I place it in the acts_as_taggable.rb instance
methods it doesn''t work. Even though it''s nearly identical to the
existing TAG_WITH method (see...