similar to: No comprendo - scaffold producing strange results

Displaying 20 results from an estimated 4000 matches similar to: "No comprendo - scaffold producing strange results"

2006 Jan 05
7
repost - Can one edit the file that generates the scaffolding.css?
I am reposting this because not only am I VERY interested in the answer but because I think it would also be useful to many, many people. We kind of have a house-style here, so it would be nice if the generated scaffold.css would accommodate that. My questions are? Is it possible? Is it safe? How? bruce
2006 Jan 29
16
counting rows via associations
Hi: I have a table called clients and each client has many lists (a has_many and belongs_to has been created in the class. What I need to do is get a count of the rows in each list for each client. I was hoping I could do something like client.lists.count but it does not seem to work. Any suggestions? bruce
2006 Jan 04
10
Is Webrick good enough?
Hi all, On the rails list I''ve seen that it''s hard to integrate Rails with Apache (especially apache2), that it''s hard to change the default port (3000), and that Apache runs Rails stuff slowly. Is it reasonable to run Rails stuff on Webrick while simultaneously running other stuff on Apache? How does one simultaneously run two rails applications on Webrick, when
2006 Jan 06
8
How do I write a generator?
I''d like to take some advice and write a generator to change the scaffold.css. How do I do that? I looked on the wiki and googled it but have not found anything yet. Any help would be much appreciated. bruce
2006 Jan 03
4
Would someone like to tell me why this code will not solve my problem? (it''s short)
I am building an invoicing system but cannot use the auto_increment field to determine the invoice number (because they are running 3 different companies off the one system. I need to find the last invoice number from any given company and then add 1 to it to get the next invoice number. BUT, there is a unique case on the very first invoice produced because there is no earlier invoice
2006 Jan 04
1
I''d like to edit the scaffolding file - is it possible?
I notice that I begin each project with a standard css file which is the one produced by scaffolding PLUS some other stuff. I could cut and paste a copy from an old project but I thought it would be "cooler" amongst other things (like more efficient) to just have the scaffold.css file be created for me. Is it possible? Is it safe(ish), What would I have to do? Thanks in
2005 Dec 31
6
I don''t even know how to ask the question (4 lines of code)
I create a hash using this line of code @x = Account.find(:all) I then want to go through each element in turn and add a key value pair to the end of it. I thought this would work, but it does not. @x.each do |a| a.merge({"balance"=>50} I used merge because I thought ''a'' would be a hash (how do you find out the type of an object?) I then guess it was
2006 Jan 19
3
A book we may wish to buy
Hi: Some French fellow posted a notice yesterday about a book that had come out. It''s called "Ruby on Rails" and is apparently by DHH & David Thomas. Is this a scam? If not, does anyone know where I can buy this book in English? I''ve searched the usual places but can''t turn anything up. Bruce
2006 Jan 22
3
dumping out mysql data only (no structure)
Is it possible? It is mentioned in AWDWR but I cannot find that option in the MySQL documentation. I can dump the whole db or just the structure, but I''d like to be able to dump just the contents. bruce
2005 Dec 24
2
Trying to grasp the difference between local variables and instance variables/
Hi: Would it be fair to say (or completely out to lunch) that a local variable is local to a method and an instance variable is local to an object. Thus an instance variable is a sort of limited global variable or super-powered local variable. Its scope is larger than a local but smaller than a global. Or that it is a global within a limited domain (the object). or is it a whole lot
2006 Jan 02
5
How can one use GRUFF with locomotive ( I guess there is a wider question here, also)
Hi: I love Locomotive and use it exclusively for my rails projects. I''d like to install GRUFF and give it a try (a graph image creation package). I know I can do sudo gem install gruff from the command line for normal ruby and rails. How do I make gems available to Locomotive? bruce
2006 Jan 01
11
Can rails make use of accesskeys?
I added :accesskey=>"D" to the html options hash of my link_to tag but nothing happened. Should I keep trying or is this not an option yet? bruce
2007 Jul 23
1
Pfr tmp files, FreeBSD and Linux
I currently have 2 samba servers (3.0.25a) one running FreeBSD 6.2 and the other running CentOS 5. Both are setup the same and using the same smb.conf. The FreeBSD server works great, no problems. The linux server works great too except on logout. When a user goes to logout, windows errors with "Windows was unable to save all the data for the file prf*.tmp. The data has been lost. This error
2009 Sep 26
1
Looking for a textbook that is more concise than Applied Linear Statistical Models (2004 version)
Hi, I know this is a little bit offtopic on this list. But I can't find a more appropriate forum that I can ask. If there is a high quality forum on statistics textbook discussion, please let me know. I am reading Applied Linear Statistical Models. One drawback that I feel about this book is that it discuss many examples, which is to distracting. Numbers are give in those examples. Comments
2010 Oct 28
3
Xen on Centos 5.5 vs 5.3 and stability issues
I've recently upgraded a Centos 5.3 machine to Centos 5.5. The hardware isn't HVM capabile so I'm only running para-virt guests. Using a vanilla i386 kernel boots without, but the newer kernel-xen locks up the Dom0 after a couple of minute. I'm only booting into single user mode for these tests so no VMs are active. *kernel-xen-2.6.18-128.1.10.el5 - no issues
2006 Jan 03
3
What am I doing wrong!!!
Hi: @x = Invoice.find(:first) if @x do one thing else do another end This ought to work but does not. I think that @x is nil but if I test for existance or @x != nil or @x.attribute != nil - my code does not respond correctly. What is the value of @x if there are no records yet in the invoices table? Thanks in advance. bruce
2010 Aug 03
2
Strange error message when rendering the scaffold form
Hello everyone, I am developing my application and I created a scaffold called listas, but when I acess /listas/new I get this error message: NoMethodError in Listas#new Showing /home/rodrigo3n/code/listeiroo/app/views/listas/_form.html.erb where line #15 raised: undefined method `deep_symbolize_keys'' for nil:NilClass Extracted source (around line #15): 12: <% end %> 13: 14:
2006 Sep 06
1
Changing Scaffold
Hi, I am starting a project in rails and I wish to change scaffolding. I''ve already done some changes like prepare all texts for locale. Now I am wishing to change the way it generates the _form partial. Could someone give some guideline so I can study such thing? I saw "template_for_inclusion" in form.rhtml but couldn''t find out how to change it. Being more
2005 Oct 25
2
generate scaffold ignores controller parameter
Since I upgraded from Rails 0.13.1 to 0.14.1 "generate scaffold <Model> <Controller>" doesn''t take any notice of the controller parameter. Anyone else suffering from this? E.g.: C:\Ruby\work\test>ruby script\generate scaffold User Admin exists app/controllers/ exists app/helpers/ create app/views/users exists test/functional/
2006 Feb 04
1
Can I reset the cycle helper?
Hi: I have lines in a table I wish to stripe BUT, every now and then there is another type of line, a section header line. I''d like to be able to start the line after a section heading always as one of the two classes the cycle helper is cycling between. Is it possible? If so, how? bruce PS. I realise I could do this with ''odd_or_even'' or the %2 method (mod