search for: commentcontroller

Displaying 5 results from an estimated 5 matches for "commentcontroller".

Did you mean: commentscontroller
2007 Mar 19
0
action_web_services error with rspec_on_rails
...t/local/bin/spec:16 I''m not using webservices at all: So can someone clue me into what is going on or point me in the right direction? Here are the two specs: #spec one require File.dirname(__FILE__) + ''/../spec_helper'' def one_join_model_setup unless defined? CommentController Object.const_set("CommentController", Class.new (CrudResourceController)) end #CommentController.class_eval { join_models :post } controller_name ''comment'' end context "join_model" do one_join_model_setup end ## spec two require File.dirna...
2013 Feb 28
2
Create polymorphic resources
Hi I have created a polymorphic association for comments since I need commenting functionality on several models. The issue is that when I create the comment in my Commets#create action, I really don''t know what type the parent is of. So, let''s say I have Foo, Bar and Comment. Comment have this: belongs_to :commentable, polymorphic: true And Foo and Bar both have:
2007 Aug 09
7
Integrating polymorphic models into controllers views? how?
I''m having trouble trying to get this to work. How the heck do you get a polymorphic controller to work? Especially integrating it with a view? Let''s say that we have shows, and episodes, then comments. A show has many episodes, an episode has many comments. the route is /shows/1/episodes/1/ Now to add a comment to that episode, how would I do it? Let''s say that the
2008 Sep 29
4
RJS is not loaded
Hello, I have here an issue which is really critical for me (it for my university work and I would like to not delete this feature). It based on a Rails 1.x tutorial which I use now under Rails 2.x. It contains the refreshment (adding content or records) of an div via RJS/JS. I access the RJS via (Controller): respond_to do |format| format.html { redirect_to :controller =>
2006 Aug 13
5
Newbie question: scaffold not working
I went through a tutorial at http://www.onlamp.com/pub/a/onlamp/2005/01/20/rails.html?page=1 to get started with RoR. I really like the idea of the scaffold construct, but I can''t seem to get it to work the way it was described in the tutorial. I''ve got a mysql database that is properly configured, and a table called ''quotes'' with a column called