Sha256: b38717bbdc8c02da21aa8de00d70a1dd1dd50b4e995a765b5e6fb82d6c2cbfd2

Contents?: true

Size: 435 Bytes

Versions: 1

Compression:

Stored size: 435 Bytes

Contents

class InvoicesController < AuthorizedController
  # States
  has_scope :by_state, :default => 'booked', :only => :index
  has_scope :by_text
  has_scope :overdue, :type => :boolean

  respond_to :html, :pdf

  # Actions
  def new
    invoice_params = params[:invoice] || {}
    invoice_params.merge!(:company_id => current_tenant.company.id)
    @invoice = Invoice.new(invoice_params)

    new!
  end

  def letter
    show!
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
bookyt-0.0.1 app/controllers/invoices_controller.rb