Displaying 1 result from an estimated 1 matches for "has_credit_card".
2006 Aug 17
2
validates_associated bug?
...eate
@user = User.new(params[:user])
@business_user = BusinessUser.new(params[:business_user])
@business_user.user = @user
@organization = Organization.new(params[:organization])
@organization.primary_user = @business_user
@credit_card = CreditCard.new
credit_card_validated = true
has_credit_card = params[:has_credit_card] == ''true''
if has_credit_card
@credit_card = CreditCard.new(params[:credit_card])
credit_card_validated = @credit_card.save
@organization.credit_card = @credit_card
end
begin
User.transaction do
if @user.save! and
#(...