similar to: simple scaffold question

Displaying 20 results from an estimated 5000 matches similar to: "simple scaffold question"

2005 Dec 25
2
HOW TO DO AN APPLIFECYCLE LISTENER IN RAILS???
In jsp, we have applifecycle listeners. For each user that logs on, and when the app is started, and when session variable is changed, you can specify a function to run. Is there something like this in Rails and any example code??? _______________________________________________ Rails mailing list Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org
2006 Jan 23
2
scaffolding generators and pluralization rules
I''ve been working through the "Rolling with Ruby on Rails" tutorial and have come up against something I''m hoping someone here can help me understand. In part two of the tutorial, Curt introduces the "ruby script\generate scaffold re -------------- next part -------------- An HTML attachment was scrubbed... URL:
2006 Feb 28
10
Scaffold command, how and what may be wrong?
hi everyone. I am learning RoR and just recently purchase the agile wed dev on rails. i am still at the beginning of the book trying to create the scaffold for the depot_development database. Everytime i run the generate scaffold products admin, i recieve the "before building the scaffold, try to create a table for model products" etc... a few questions: 1. How does ruby know that
2006 Jan 12
8
Scaffolding support for many-to-many editing (habtm)?
Like with simple table editing, there are also typical ways of how a user usually interacts with one-to-many or many-to-many relations. For example, one would show the fields of one row of table1 in the screen and below a line-by-line view of all associated entries in table2. Then, one could press an "Edit" button and add or delete rows from table2 to this entry of table1,
2005 Aug 08
68
Pluralized Controller Names?
If I do: script/generate controller Photo I get a controller named photo_controller. OTOH, if I do: script/generate scaffold Photo I get a controller named photos_controller. (Note that the controller name is pluralized). I realize that I''m specifying the controller name explicitly in the first case, but it seems odd to me that the scaffold command generates a pluralized
2006 Mar 29
4
Scaffold generator: create vs. new
Can anyone supply me with a simple, succinct explanation of what the difference is between the "new" controller and the "create" controller that the scaffold generator produces? I run: > script/generate scaffold modelname controllername And now I need to do some work inside the controllername.rb file. For example, pulling a list from another database table to supply
2006 Jun 20
1
Templates in scaffold
How can I make my own or modify templates in scaffold? -- Posted via http://www.ruby-forum.com/.
2005 Aug 08
7
Problems with ./scripts/generate scaffold
Hi all, I''m new to rails after having used perl for most of these things, and am trying to get my head around the generate script for a project playing around with. If I do: ./scripts/generate controller Device I get app/controllers/device_controller.rb where I can then add: scaffold :device However, if I want to actually generate the scaffolding so I can make some changes:
2006 Apr 05
13
scaffold misuse?
Running ruby script/generate scaffold Product Admin is a wonderful way to set up well, exactly what it says, a scaffold. My problem is that I have several other tables that are linked, through foreign keys, to the Product table. Say an "authors" table. Now when I go enter a new product, a book, I want the application to provide a drop down list of authors generated from the records in
2009 Jul 19
9
Equipment_URL Failed to Generate (new_equipment_path)
I''m trying to use new_equipment_path, which creates the appropriate link. But, when trying to evaluate "equipment/new" I get the error below. I''ve included my routes (rake route). Equipment is one of those words that pluralizes to "equipment", so the singular is right (from what I know from this forum. Any help would be appreciated. Error: equipment_url
2006 Apr 20
8
Whats the best way to do this?
I have an archive that can have 0 or more extra files associated with it. I would like to be able to edit the associated files info on the same page as the archive info. Listing the extra files info to the edit form is simple enough, but How do I form the text input fields for easy (or automatic) pick-up in the update? Or am I barking up the wrong tree here? -- Posted via
2006 Jan 08
4
Rails table pluralizing Issue
Hi, I am working on a table with name "addresses". However when I do a ruby script/generate scaffold Address, I am not able to access http://localhost:3000/addresses. I am getting the following error. uninitialized constant Addres This error occured while loading the following files: addres.rb How do I resolve this issue. Thanks Silvy MAthews
2006 Jan 15
2
scaffold suddenly pluralizing names
I haven''t updated rails today and all of a sudden scaffold is pluralizing my names ruby script/generate scaffold Admin::Category produces class Admin::CategoriesController < ApplicationController Do I really want "CategoriesController" instead of "CategoryController"? Thanks, Peter
2008 Feb 21
1
Creating incorrect plurals when generating scaffold
Preface: I''m trying to find my way through the "Build Your Own Ruby on Rails Web Application" book. I''m completely new to programming and am having a hard time figuring out the differences between rails 2.0.2 and what''s in the book so please forgive me if this is a stupid question. I''m confused because I finally thought I''d figured out the
2006 Nov 03
10
[PLUGIN] rspec_resource_generator - RESTful scaffold generator with RSpec specifications
rspec_resource_generator ======================== By Pat Maddox Use this generator to generate RESTful scaffolding with RSpec specifications. Syntax is exactly the same as the scaffold_resource generator: ./script/generate rspec_resource ModelName [field:type field:type] When you run this generator, it will create a migration, model, and model spec file. In addition, it gives you a RESTful
2006 Mar 17
4
Noob question about the "show" function
i''ve got a cool app going and it''s getting bigger and bigger, but now i''m trying to customize the show function. i''m using the scaffold code as a base but can''t seem to get anything to look right. i guess i''m confused about how exactly the scaffold code works for the "show" function. any help would be awesome! thanks. jon --
2006 Jun 07
2
script/generate scaffold pluralizes class names
Hi everyone, I''m a rails & ruby nuby, and this is my first post to the list. Here''s my environment in case it helps diagnose my problem: Ruby version 1.8.4 (powerpc-darwin8.6.0) RubyGems version 0.8.11 Rails version 1.1.2 Active Record version 1.14.2 Action Pack version 1.12.1 Action Web Service version 1.1.2 Action Mailer version 1.2.1 Active Support version 1.3.1 I did
2005 Aug 18
10
Scaffolding, DRY and RHTML
Hello all, I''m working on a couple of Rails projects at the moment and have noticed something that seems to go against the DRY principal. Why, when scaffolding, are individual CRUD rhtml files created instead of using one as a partial and having the others use that single partial? This especially applies to the list rhtml. I am about to get to the other operations and see how feasible
2006 Jan 15
5
SEO friendly and validation?
Hello everyone! I am new to Ruby on Rails. These are my questions: - is Ruby on Rails SEO friendly? - can validation result be in another language then english? thanks! -- Posted via http://www.ruby-forum.com/.
2006 Jan 25
4
html special char conversion
I''ve stucked to such problem: I have html entities in database, after using scaffold I''ve got these chars not converted (I have strictly " and & in page source). It is what I need, but after making ./script/generate scaffold modelname controllername (recreating controller) I''ve got all special chars converted into entities like (&quot and others). How can