Sha256: a28509e1d098a2510daf17e04a5a55ecc8a31caf63c605835ee1558f3efb016b
Contents?: true
Size: 634 Bytes
Versions: 3
Compression:
Stored size: 634 Bytes
Contents
class Manage::<%= controller_class_name %>Controller < Manage::BaseController inherit_resources load_and_authorize_resource :class => <%= class_name %> has_scope :with_title, :as => :title, :only => :index order_by :created_at, :updated_at def create create!{ manage_<%= plural_name %>_path } end def update update!{ manage_<%= plural_name %>_path } end def destroy destroy!{ manage_<%= plural_name %>_path } end protected def collection @<%= plural_name %> = (@<%= plural_name %> || end_of_association_chain).order(search_filter.order).page(params[:page]) end end
Version data entries
3 entries across 3 versions & 1 rubygems