acts-as-taggable-on

Vestal_versions and acts_as_taggable_on

Hi, Does anybody successfully integrated vestal versions and acts_as_taggable_on plugins? I've added to my app, that using acts_as_taggable_on following line to environment.rb config.gem 'vestal_versions' and on any rake task or generator script call i see $ ./script/generate /opt/local/lib/ruby/gems/1.8/gems/rails-2.3.5/lib/rails/...

Finding related tags using acts-as-taggable-on

In tag#show I list all entries with that tag. At the bottom of the page I'd like to have something like: "Related Tags: linked, list, of, related tags" My view looks like: <h2><%= link_to 'Tag', tags_path %>: <%= @tag.name.titleize %></h2> <% @entries.each do |entry| %> <h2><%= link_to h(entry.name), entry %></h2> <%- unless entry...

Relationship among models[Rails]

Hi I am Having 3 Models Category / Issue / Article Where Article is taggable_on :topics and :sub_topics Using [acts_as_taggable_on plugin] So what kind of relationship we have to maintain among these model and how we can retrieve category topics,sub_topics / issues topics and sub_topics Thanks in advance ...

acts_as_taggable_on with finders...

I would like to use acts_as_taggable_on to do a auto suggest style tagging similar to stackoverflow below... that or facebook. But I'm unsure looking thru the rdocs what methods to use to pull all the various tags from a giving model. Article.tag_counts_on(:tags) That gives me all the tags... but i'd like to do something more advance...

Rails Tagging using Acts_As_Taggable_On: Finding All Tags in a Context

In a blog system I'm working on, I want to use tags as a mechanism for deciding where a particular post shows up. I'm using acts_as_taggable_on to set up two contexts, the normal :tags context and then the :audience context. I'm using an account model to tag the post model like so: account.tag(post, :with => "cat1, cat2", :on => :au...

weird behavior with acts_as_taggable_on

Edit The instructions on Github instruct you to use the gemcutter source for the gem. Currently, this installs version 2.0.5 which includes the bug I've detailed below. @Vlad Zloteanu demonstrates that 1.0.5 does not include the bug. I have also tried with 1.0.5 and confirm that the bug does not exist in this version. People struggling...

acts-as-taggable-on: find tags with name LIKE, sort by tag_counts?

Hi I'm using the rails plugin acts-as-taggable-onand I'm trying to find the top 5 most used tags whose names match and partially match a given query. When I do User.skill_counts.order('count DESC').limit(5).where('name LIKE ?', params[:query]) This return the following error: ActiveRecord::StatementInvalid: SQLite3::SQLException: amb...

Finding a specified taggable_type with acts-as-taggable-on

So in another controller, I use a find like this: @entries = Entry.find(:all, :conditions => ['live = ?', false]) to find all the entries with a false 'live' column. In my project I'm using two different taggable types, one for entries (Entry), and one for messages (Message). After looking at my tried and true code above you would th...

Remove a tag type from the view (involves alphabetical pagination)

I have an index view that lists all of the tags for my Entry and Message models. I would like to only show the tags for Entries in this view. I'm using acts-as-taggable-on. Tags Controller: def index @letter = params[:letter].blank? ? 'a' : params[:letter] @tagged_entries = Tagging.find_all_by_taggable_type('Entry').map(&:taggable)...

acts_as_taggable_on and auto_complete returning no results

I'm using acts_as_taggable_on in a model, and am trying to implement the auto_complete plugin. It seems as though I have everything hooked up correctly, but the search isn't returning any results. Here's what I have so far: In the view: <%= text_field_with_auto_complete(:link, :tag_list, {}, {:tokens => ','}) %> In the controller: ...

Suggestions on how to track tag count for a particular object

Hi, I'm looking for suggestions on how to track the number of tags associated with a particular object in Rails. I'm using acts_as_taggable_on and it's working fine. What I would like to be able to do is search for all objects that have no tags, preferably through a scope i.e. Object.untagged.all My first thought was to use an after_sa...

Find tag by id using acts_as_taggable_on

I'm using Ruby on rails 2.3.8 and acts_as_taggable_on plugin. This plugin generates three tables: tags(which has the id and name of each tag) and taggings(relates tag_ids which the items that are tagged). Now, I'd like to get all the items tagged with a certain tag_id. So, I go to my Announcement model(the announcements are the tagged i...

Is it possible to make a relationship between an ActiveRecord model and a plugin's model?

I'm using ruby on rails 2.3.8, and I've installed the acts_as_taggable_on plugin for tagging announcements and everything was fine until I discovered I had no easy and neat way of getting all the announcements tagged with a certain id(the only method I found was Tag.tagged_with(tag_name)). So, I just wanted to relate the Tag model of th...

acts_as_taggable_on: query for users tagged with any of these tags

I'm using acts_as_taggable_on and I'm trying to query for all users tagged with any of the tags in the collection tags Right now I'm doing: tags.map(&:name).each { |name| @result.push User.tagged_with(name) } Is there a way that I can do this in one query, and not tags.size queries? I'd appreciate any help. ...

acts_as_taggable undefined method 'each' error

I am trying to use acts_as_taggable plugin to include tag functionality in my ruby on rails application. I have attached the code. I have installed the plugin and also run the migrations.I am getting the following error. undefined method `each' for "value of the parameter":String Code location.rb - location table has name, tags(this ...

How can I force rails to recognize a method's location

I'm having trouble in my application where a controller is calling a method and the server is reporting that the method doesn't exist. This is the method call. The method not working is tag.related_tags @related_tags = @tags.collect { |tag| tag.related_tags }.flatten.uniq The Tag model is originally defined in an plugin acts-as-tagga...

Rails 3, Ruby 1.9.2 and acts_as_taggable_on not playing nicely

I'm rewriting my rails application to work with rails 3 and when I migrate the acts_as_taggable_on migration I get this error: == CreatePosts: migrating ==================================================== -- create_table(:posts) rake aborted! An error has occurred, this and all later migrations canceled: SQLite3::SQLException: table ...

Uninitialized Tag constant in Rails 3 with Acts_As_Taggable_On

This controller action worked perfectly in Rails 2.3.x: def show @title = Tag.find(params[:id]).name @tag = Tag.find(params[:id]) @messages = Post.paginate(Post.find_tagged_with(@tag), :page => params[:page], :per_page => 10, :order => "updated_at DESC") @related_tags = @related_entries.collect{|x|x.tags}.flatten....

Merging tags with acts_as_taggable_on Rails gem

I'm using acts_as_taggable_on in my Rails app, and I'd like advice on the best way to merge two tags. For example, if I've got a list of Food records, and some are tagged "cheese" and some are tagged "milk," what's the best way to combine these tags into a single "dairy" tag. Should I just find all records tagged with "cheese" and/or ...

Acts As Taggable On: translate tags

I'm working with RoR and I was wondering how can I translate Acts As Taggable On tags without having to manually insert it every time I use a tag again? Example: I have a Post (title and body in English) and I create it with tags "shoes, dress, beauty". I've title and body translated to Japanese in a text file, so I just need to copy/pa...