search for: crumley

Displaying 3 results from an estimated 3 matches for "crumley".

Did you mean: brumley
2010 Apr 13
5
How to check if a parent has children?
What is the new way to check if a parent has child items? In rails 1.2.6 I did this: if @client.has_line_items? Client being the parent and line_items the children. Now that I have upgraded to rails 2.0.1 (on my way to current :-) ) I am getting this message: undefined method `has_line_items?'' for #<Client:0x7f3b093b01a0> How should I format the query now? Regards, Paul
2010 Apr 10
5
Rendering a Partial as an Alternative
Suppose that I want to have a block of default content within a template that is replaced with the content of a specific partial only if that partial exists. Obviously there is the brute force approach of simply rendering the default content unless the relevant partial file exists in which case the relevant partial is rendered instead. I suspect that there may be a more elegant way to skin this
2010 Apr 09
9
gem install rails (Errno::ENOENT) No such file or directory
I have two PCs, one with Windows XP and another with Windows Vista. I''m working as an administrator in both computers. I''m using Ruby 1.8.7 and Rubygems 1.3.6. When I try to install Rails I get this error: C:\>gem install rails ERROR: While executing gem ... (Errno::ENOENT) No such file or directory - C:/Users/Jesús Dugarte I have installed Rails several times before