I have been using https://github.com/ryanto/acts_as_votable gem as a Save button for Posts. It has been all good so far.
However now I created a separate scaffold (Articles) and wanted to add the same Save button. So users can save Posts and Articles, then view in their profiles.
Now I got problem as some Article records has same id as Post records. Plus how do I even display Saved records now as I dont know what id comes from Article or Post.
Is there any way to solve this with Acts As Votable Gem?
Thank you!
The current version (0.12.0) of acts_as_voteable does this out of the box. The Vote model has a column votable_type which can be a reference to multiple models.
To display saved records you can use a scope like
I hope this answers your question.