Sha256: 68fe934cc7a5cc3a138093aee45281ac48259219f9bd118f468dd0e71e03b211

Contents?: true

Size: 1.24 KB

Versions: 47

Compression:

Stored size: 1.24 KB

Contents

class ::IshManager::IroWatchesController < IshManager::ApplicationController

  before_action :set_lists

  def index
    # authorize! :index, Ish::Invoice
    # @invoices = Ish::Invoice.all.includes( :payments )
    raise 'not implemented'
  end

  # def new
  #   authorize! :new, @invoice
  # end

  # def create
  #   @invoice = Ish::Invoice.new params[:invoice].permit!
  #   authorize! :create, @invoice
  #   if @invoice.save
  #     flash[:notice] = "created invoice"
  #   else
  #     flash[:alert] = "Cannot create invoice: #{@invoice.errors.messages}"
  #   end
  #   redirect_to :action => 'index'
  # end

  # def update
  #   @invoice = Ish::Invoice.find params[:id]
  #   authorize! :update, @invoice
  #   if @invoice.update_attributes params[:invoice].permit!
  #     flash[:notice] = 'Success'
  #     redirect_to :action => 'index'
  #   else
  #     flash[:alert] = "Cannot update invoice: #{@invoice.errors.messages}"
  #   end
  #   redirect_to :action => 'index'
  # end

  #
  # private
  #
  private

  def set_lists
    # @invoice_number = Ish::Invoice.order_by( :number => :desc ).first
    # @invoice_number = @invoice_number ? @invoice_number.number + 1 : 1
    # @new_invoice = Ish::Invoice.new :number => @invoice_number
  end

end

Version data entries

47 entries across 47 versions & 1 rubygems

Version Path
ish_manager-0.1.8.399 app/controllers/ish_manager/iro_watches_controller.rb
ish_manager-0.1.8.397 app/controllers/ish_manager/iro_watches_controller.rb
ish_manager-0.1.8.396 app/controllers/ish_manager/iro_watches_controller.rb
ish_manager-0.1.8.395 app/controllers/ish_manager/iro_watches_controller.rb
ish_manager-0.1.8.394 app/controllers/ish_manager/iro_watches_controller.rb
ish_manager-0.1.8.393 app/controllers/ish_manager/iro_watches_controller.rb
ish_manager-0.1.8.392 app/controllers/ish_manager/iro_watches_controller.rb
ish_manager-0.1.8.391 app/controllers/ish_manager/iro_watches_controller.rb
ish_manager-0.1.8.390 app/controllers/ish_manager/iro_watches_controller.rb
ish_manager-0.1.8.389 app/controllers/ish_manager/iro_watches_controller.rb
ish_manager-0.1.8.388 app/controllers/ish_manager/iro_watches_controller.rb
ish_manager-0.1.8.387 app/controllers/ish_manager/iro_watches_controller.rb
ish_manager-0.1.8.386 app/controllers/ish_manager/iro_watches_controller.rb
ish_manager-0.1.8.385 app/controllers/ish_manager/iro_watches_controller.rb
ish_manager-0.1.8.384 app/controllers/ish_manager/iro_watches_controller.rb
ish_manager-0.1.8.383 app/controllers/ish_manager/iro_watches_controller.rb
ish_manager-0.1.8.382 app/controllers/ish_manager/iro_watches_controller.rb
ish_manager-0.1.8.381 app/controllers/ish_manager/iro_watches_controller.rb
ish_manager-0.1.8.380 app/controllers/ish_manager/iro_watches_controller.rb
ish_manager-0.1.8.379 app/controllers/ish_manager/iro_watches_controller.rb