Displaying 1 result from an estimated 1 matches for "costpric".
Did you mean:
costprice
2005 Nov 30
8
nested attributes with update_attributes()
...rice expected, got HashWithIndifferentAccess
Here''s the situation (simplified):
class Product < ActiveRecord::Base
belongs_to :productPrice
end
class ProductPrice < ActiveRecord::Base
has_one :product,
:dependent => true
validates_presence_of :costprice, :listprice
end
my parameters look something like this:
params = {
:product => {
:productno => "something",
:description => "something else",
:productPrice => {
:costprice =...