Sha256: e32559c59b68fdea5b38f9131f3807b563534bdc8fbdbf9558379d8649d01ffb
Contents?: true
Size: 449 Bytes
Versions: 2
Compression:
Stored size: 449 Bytes
Contents
module Admin::ApplicationHelper include Pagy::Frontend def title content_for(:title) || Rails.application.class.to_s.split("::").first end def active_nav_item(controller, actions = %w(index show new edit create update)) active_actions?(controller, actions) ? "active" : "" end private def active_actions?(controller, actions) params[:controller].include?(controller) && actions.include?(params[:action]) end end
Version data entries
2 entries across 2 versions & 1 rubygems