customers_helper.rb 315 B

123456789
  1. module CustomersHelper
  2. def setup_customer(customer)
  3. customer.build_billing_information if customer.billing_information.blank?
  4. customer.build_contact if customer.contact.blank?
  5. # customer.billing_information ||= customer.build_billing_information
  6. # customer.contact ||= Contact.new
  7. customer
  8. end
  9. end