Advice on rating system

0 views
Skip to first unread message

Greg Ma

unread,
Aug 26, 2010, 3:29:28 AM8/26/10
to rubyonra...@googlegroups.com
Hi,
I'm doing a simple rating system, but I need and advice on the
controllers. My system rates article.

Should I add an action rate in the article controller or should I create
a rate controller and add the action create?
What's the cleanest way?

Greg
--
Posted via http://www.ruby-forum.com/.

clanlaw

unread,
Aug 26, 2010, 6:30:47 AM8/26/10
to rubyonra...@googlegroups.com
On 26 August 2010 08:29, Greg Ma <li...@ruby-forum.com> wrote:
> Hi,
> I'm doing a simple rating system, but I need and advice on the
> controllers. My system rates article.
>
> Should I add an action rate in the article controller or should I create
> a rate controller and add the action create?
> What's the cleanest way?

What models and relationships do you have? I ask because it is not
clear whether a rating is just an attribute of an article or whether
an article has many ratings, so that a Rating is a model in it's own
right.

Colin

Reply all
Reply to author
Forward
0 new messages