2009/9/25 rtacconi <rtacc...@gmail.com>: > > Thanks for your help. > > On Sep 25, 9:44 am, Colin Law <clan...@googlemail.com> wrote: >> 2009/9/25 rtacconi <rtacc...@gmail.com>: >> >> >> >> > This is my first message, so hello to everybody! >> >> > I would like to have a simple intranet with categories and articles >> > management. I think to use act_as_tree for the categories and >> > act_as_list for the articles, but any article should be connected to >> > one category. So in any category I can have one or more articles in a >> > list. Do I have to declare a Category class as parent of the list of >> > the articles? As you might guess I am a Ruby and Rails rookie. >> >> > I would like to know if there is a plug-in with this features, where I >> > can manage categories and articles. >> >> Apologies if you have already done this but I recommend newcommers to >> look at the rails guides athttp://guides.rubyonrails.org/ >> particularly Getting Started and ActiveRecord Associations. These may >> answer some of your questions. >> > I had a look and I wll start soon to read migrations and ActiveRecord > chapters in "Agile Web Development in Rails" >> Are you sure you need a _list_ of articles as opposed to just a >> collection of them such as would be provided by the normal has_many, >> belongs_to relationship? > > Let's say you have some articles and the administrator wants to order > the articles display. Showing the articles using act_as_list is > perfect, since I want to show the articles as and ordered list.
If the articles have a definite intrinsic sequence that is not determined by date or other property of the article then acts_as_list may indeed be appropriate. Note that acts_as_list is about how the data is stored in the database rather than just an order of viewing at some instant. Colin --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---