similar to: scaffold and Migrations

Displaying 20 results from an estimated 10000 matches similar to: "scaffold and Migrations"

2006 Jan 18
3
Documentation for scaffold / views
Apparently a scaffold creates at least one instance variable for views to use, and if I override the scaffold then I must also explicitly create that instance variable for the view. I''d like to know exactly what work is performed by the scaffold so that I can know this when over-riding the view. (OR, is it that the controller makes these variables available by default?..) EXAMPLE:
2006 Apr 24
3
quick q on script/generate scaffold
I want a scaffold to manager both products and users. To get the products scaffold I used script/generate scaffold Product Admin if I use, script/generate scaffold User Admin will it overwrite my product admin controller? Would I be better off doing script/generate scaffold User User_Admin or something? -- Posted via http://www.ruby-forum.com/.
2006 Jun 29
0
Ajax Scaffold for a application started using win32-process module.
Hi, I have an RoR application(parent) which is use to kick off other RoR applications(ajax scaffold based). I use win32-process Open4.popen4() to start the RoR applications. Untill recently I was using normal scaffold feature of Rails, and recently I migrated to Ajax Scaffold; After moving on to Ajax scaffold, when I try to start a RoR from my parent RoR, the application do get started, when I
2009 Apr 12
0
Heroku Garden - reversing or changing a 'generate scaffold' command
In Heroku Garden, is there a way of reversing or changing a ''generate scaffold'' command? I often find I need to make changes to the scaffolded application but I do not know how to. ''script/destroy scaffold Modelname'' from the console doesn''t seem to work. For example, I generated a Product scaffold in Heroku Garden. When I try to destroy it using the
2006 Mar 31
13
validation with in_place_edit_for
i''ve got an in place edit text box for some of my fields. my model has validates_presence_of for the field but nothing happens. it works fine in the scaffold when using the edit page, but nowhere else. anyone have a solution to this? -- Posted via http://www.ruby-forum.com/.
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 Mar 03
0
AR::Base.pluralize_table_names doesnt work with scaffold generator, right?
Hi! The script/generator scaffold for models doesnt respect (source in) this config/environment.rb setup, right? Because I can put in there ActiveRecord::Base.pluralize_table_names = false but when I run a command like ruby script/generate scaffold model Something then it throws an error saying that my database scheme doesnt have a Something. However there is a table called something. If I
2007 Aug 06
0
Problem generating scaffold with a namespace
I''m trying to generate a scaffold based on a model in a namespace and I would like the controller to have a similar namespace. Am I thinking that scaffold should be doing something it doesn''t or is this a bug? rails version: 1.2.3 ruby version: 1.8.5 OS: OS X 10.4.10 Created a model using > script/generate model Foo::Bar creates the model bar.rb in the model/foo directory
2010 Aug 06
0
adding options to erb scaffold generator to include or skip custom views / templates
created a small patch.. looking for feedback / etc.. https://rails.lighthouseapp.com/projects/8994-ruby-on-rails/tickets/5319-adding-options-to-erb-scaffold-generator-to-include-or-skip-custom-views-templates#ticket-5319-2 When I was working on customizing the erb scaffold generator to match the style and design I wanted to use by creating custom templates in / lib/templates/erb/scaffold I found
2006 Jun 21
0
Scaffold error
Hoping someone call tell me what I''ve done wrong. I was attempting to create a "static" scaffold (already have the dynamic one) and received an error message: "error Before updating scaffolding from new DB schema, try creating a table for your model (Company)" I already created a scaffold for Company (class CompanyController). I want to create some better views.
2006 Apr 11
0
Problem using generate/scaffold and FireRuby
Hi to all, I am trying to use "ruby script/generate scaffold product". I always get the message "uninitialized constant CHARACTER_SET". I have a products table in a Firebird database called depot_development.fdb. Here is my config file : > common: &common > adapter: firebird > host: localhost > username: SYSDBA > password: masterkey >
2006 Jun 12
3
Weird problem related I am having with scaffold
i, I have this in expense_controller.rb: class ExpenseController < ApplicationController scaffold :expense end It works fine, but let''s say I want to override scaffold''s list. For some reason, just making list.rhtml in views\expense is enough, and there''s no need to add def list end in expense_controller.rb. However, that''s not my real problem. Now
2006 Jan 26
3
Problems with simple scaffold code
Hi all, I had scaffold generate some code on a brand new app the trace is here: http://rafb.net/paste/results/H87GHC68.html Could you point me to what problem needs to be fixed please as i''ve been banging my head against this for some time now? The table is very simple and its called "user" with id, email, password fields. I''ve set pluralize_table_names to false
2006 Apr 06
3
scaffold question
there are some things on a scaffold that i would like to use without the whole thing. is it better to generate one and then cut it down to only what you''ll use? are all of the things in a scaffold available to just build by hand? for instance, i have a scaffold for my users. in the list action, it has @user_pages, so that you can put @user_pages.current.next or something like that -
2006 Aug 14
0
Converting scaffold to a plugin ??
I''ve modified the standard Rails scaffold code to make it more usefull to me. How can I convert that scaffold to a plugin so that it is more portable? As it is, I have to re-configure scaffold everytime a new Rails version is released. Not very DRY. Could someone point me to a tutorial on the subject? -- Best Regards, -Larry "Work, work, work...there is no satisfactory
2006 Sep 07
0
why scaffold.rhtml?
Hi, I am using a tutorial "Riding the Rails" and it creates a file "scaffold.rhtml". when I run scaffold I don''t find any scaffold.rhtml! Why? Do I not have something. I get the CRUD. Thanks in advance Jim --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk"
2006 Jul 28
2
Scaffold and Undercores in Tablenames
I am attempting to generate scaffolds on legacy tables that have underscores in the name. Scaffold does not see the underscore. I have tried a backslash escape but it no work. I have looked around but i cannot find a way to make it work. It''s like this: c:\railroad>ruby script/generate scaffold FOO_BAR exists app/controllers/ exists app/helpers/ create
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/
2005 Nov 30
2
Missing scaffold features
Hello everyone, First off, I''m trying to generate a discussion here, not provoke an argument or get people upset. Please bear this in mind if/as you read on... To my mind, there''s 3 missing features from scaffolds that would make them a whole lot more useful. These are: - auto-generation of a drop-down list for inputting/updating has_many/belongs_to relationships between
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