Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

scope tags to specific tagging context #697

Merged
merged 1 commit into from
Nov 11, 2015
Merged

Conversation

zapnap
Copy link
Contributor

@zapnap zapnap commented Nov 5, 2015

I found this to be pretty valuable (no need to subclass for my use case):

ActsAsTaggableOn::Tag.for_context('skills') => # tags applied to 'skills' context, but not 'needs' context

seuros added a commit that referenced this pull request Nov 11, 2015
scope tags to specific tagging context
@seuros seuros merged commit 5d9fa33 into mbleigh:master Nov 11, 2015
@snoblenet
Copy link

I am using acts-as-taggable-on 3.5.0. I have:

class Report < ActiveRecord::Base
  acts_as_taggable_on :categories, :countries
end

Why do I get this?

> ActsAsTaggableOn::Tag.for_context("categories").most_used(10)
NoMethodError: undefined method `for_context' for #<Class:0x007fd6303d30c0>

Many thanks,

Steven

@andrezimpel
Copy link

+1 @snoblenet

tekniklr pushed a commit to tekniklr/acts-as-taggable-on that referenced this pull request Mar 19, 2021
scope tags to specific tagging context
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants