Sha256: 3ff0f2e5aa469d8e081e9d3994026ae09293d78e9d4e9aedbef1040a578134aa
Contents?: true
Size: 1.17 KB
Versions: 8
Compression:
Stored size: 1.17 KB
Contents
class BillingsController < ApplicationController before_filter :authorize_admin, :except => [:show] layout Saucy::Layouts.to_proc def show end def edit @account = current_account @account.cardholder_name = @account.credit_card.cardholder_name @account.billing_email = @account.customer.email @account.expiration_month = @account.credit_card.expiration_month @account.expiration_year = @account.credit_card.expiration_year if @account.billing_address @account.street_address = @account.billing_address.street_address @account.extended_address = @account.billing_address.extended_address @account.locality = @account.billing_address.locality @account.region = @account.billing_address.region @account.postal_code = @account.billing_address.postal_code @account.country_name = @account.billing_address.country_name end end def update @account = current_account if @account.save_customer_and_subscription!(params[:account]) redirect_to account_billing_path(@account), :notice => t('.update.notice', :default => "Billing information updated successfully") else render :edit end end end
Version data entries
8 entries across 8 versions & 1 rubygems