has-many-polymorphs

has_many_polymorphs tagging - works on development machine, not on production!

I'm having a weird problem, where tagging works fine on my development machine, but when I deploy to the production server, I get this error in the log: ActionView::TemplateError (undefined method `tags' for #<Person:0x98bb9d4>) on line... There is an entry in the production.log file that states that has_many_polymorphs is loaded, so ...

Rails has_many_polymorphs in reverse?

So I have some models set up that can each have a comment. I have it set up using has_many_polymorphs, but I'm starting to run into some issues where it's not working how I think it should. For example: class Project < ActiveRecord::Base end class Message < ActiveRecord::Base has_many_polymorphs :consumers, :from => [:projects,...

Multiple has_many_polymorphs in one model

I'm trying to define multiple polymorphic relations (has_many_polymorphs plugin) from a single parent to same children. Note has many viewers Note has many editors Viewers could be either Users or Groups Editors could be either Users or Groups Permission is the association model with note_id, viewer_id, viewer_type, editor_id, editor_ty...

versioning has_many_polymorphs associations

I've done a research on rails versioning support and found plugins like acts_as_versioned, acts_as_versioned_association (this one have a really serious lack of documentation), simply_versioned and acts_subversive. Some of these support versioning of associations but haven't power enough to go smoothly with polymorphics ones. I'm wonde...

What does has_many_polymorphs mean by "Referential integrity violation"?

I have a has_many_polymorphs relationship between a Candidate and many events of various type. In particular, a Candidate creates a Created event when it is created. class Candidate < ActiveRecord::Base has_many_polymorphs :events, :through => :candidate_events, :from => Event::Base.included_in_classes.m...

has_many_polymorphs post install issue

hi all, immediately after has_many_polymorphs install with ruby script/plugin install git://github.com/fauna/has_many_polymorphs.git i start getting following error whenever i try to execute smth like script/generate or script/server => Rails 2.3.2 application starting on http://0.0.0.0:3000 /test/vendor/plugins/has_many_polymorphs/...

rails: has_many :through validation?

Rails 2.1.0 (Cannot upgrade for now due to several constraints) I am trying to achieve this. Any hints? A project has many users through join model A user has many projects through join model Admin class inherits User class. It also has some Admin specific stuff. Admin like inheritance for Supervisor and Operator Project has one Admin,...

has_many_polymorphs problem

Hi, i have problem with has_many_polymorphs, maybe you can help me. I have some models class Issue < ActiveRecord::Base has_many_polymorphs :things, :from => [:applications], :through => :relations ene class NewsArticle < ActiveRecord::Base has_many_polymorphs :things, :from => [:applications], :through => :relations end class Ap...

has_many_polymorphs uniq option only works one way

hi all I have a has_many_polymorphs relationship that involves the following classes: class DigilearningModule < ActiveRecord::Base has_many_polymorphs :members, :from => [:digilearning_titles, :lesson_categories, :lesson_category_groups], :through => :digilearning_module_memberships, :dependent => :destroy, :uniq => true...

has_many_polymorphs & Forms

The way this program needs to work is like this: A person can view an event and then choose to either register directly for an event or for a team (which is registered for an event). class Event has_many_polymorphs :registrants, :from => [:users, :teams], :through => :registrations end class Team belongs_to :registrant, :polymorphi...

acts_as_list postgres error on heroku.

We are using has_many_polymorphs along with acts_as_list. Everything works fine locally, but on heroku, we get an error everytime a couple of acts_as_list methods are called. Namely those that update a number of records with new positions because of an addition or a deletion of an item in the list. Example of acts_as_list method: def ...

(Rails) How to implement search when all metadata is found in has_many_polymorphs models

Hello, I have a Page model. The Page model consists mainly of just the page name, however the actual page content is made up by many page components using has_many_polymorphs. Each of these page components also has a name and the linked component may contain more data, such as date values, textual content, images or other files. This h...