[Rails] Re: has_one/belongs_to relationship failing.

2011-03-25 Thread R. K.
Colin Law wrote in post #989292: > On 25 March 2011 20:24, R. K. wrote: >> belongs_to :ingredient >> t.datetime "created_at" >> t.string "equivalent" >> t.datetime "created_at" >> t.datetime "updated_at" &g

[Rails] has_one/belongs_to relationship failing.

2011-03-25 Thread R. K.
I have an Ingredient which has a Measurement. class Ingredient < ActiveRecord::Base has_one :measurement belongs_to :recipe accepts_nested_attributes_for :measurement end class Measurement < ActiveRecord::Base belongs_to :ingredient end The schemas appear right: create_table "ingred

[Rails] Re: Nested Models are not connecting/connected

2011-03-18 Thread R. K.
Frederick Cheung wrote in post #987930: > So what's not working? The models you posted should be ok as long as > the forms are ok too (there's also a railscast or 2 on this subject) > > Fred Yes Fred and examining my code some more (with the advice I got from here) that's my conclusion as well. I

[Rails] Nested Models are not connecting/connected

2011-03-17 Thread R. K.
I'm attempting to make a basic CRUD/data entry cookbook. I've got a recipe model that is composed of other models. I'm intending of using a single form to create the recipes such that n ingredients and n instructions can be associated to a single recipe. I understand why it's not happening I just

[Rails] Http Rest call and JSON response

2010-05-30 Thread Deepak R k
I am trying to call remote server rest api , the response type of call is json data. plz give me tips how to do this . I am new in rails . -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post