Class: Admin::CustomersController

Inherits:
ApplicationController
  • Object
show all
Defined in:
app/controllers/admin/customers_controller.rb

Instance Method Summary collapse

Instance Method Details

#indexObject



7
8
9
10
11
12
13
14
# File 'app/controllers/admin/customers_controller.rb', line 7

def index
  @datatable = EffectiveCustomersDatatable.new(self)

  @page_title = 'Customers'

  EffectiveOrders.authorize!(self, :admin, :effective_orders)
  EffectiveOrders.authorize!(self, :index, Effective::Customer)
end

#showObject



16
17
18
19
20
21
# File 'app/controllers/admin/customers_controller.rb', line 16

def show
  @customer = Effective::Customer.find(params[:id])

  @page_title ||= @customer.to_s
  EffectiveOrders.authorize!(self, :show, Effective::Customer)
end