Files
nairobi/app/controllers/management/budgets_controller.rb
2016-12-01 16:31:05 +01:00

18 lines
410 B
Ruby

class Management::BudgetsController < Management::BaseController
include FeatureFlags
include HasFilters
feature_flag :budgets
has_filters %w{open finished}, only: :index
load_and_authorize_resource
def index
@budgets = @budgets.send(@current_filter).order(created_at: :desc).page(params[:page])
end
def show
@budget = Budget.includes(groups: :headings).find(params[:id])
end
end