Sha256: 116b7307b247f0e06e9e143c086a81893c8d56ead452ceb14f4902da864ee441
Contents?: true
Size: 953 Bytes
Versions: 13
Compression:
Stored size: 953 Bytes
Contents
module Refinery module Pages module Admin module InstanceMethods def error_404(exception=nil) if (@page = ::Refinery::Page.where(:menu_match => "^/404$").includes(:parts).first).present? params[:action] = 'error_404' # change any links in the copy to the refinery_admin_root_path # and any references to "home page" to "Dashboard" # TODO =begin part_symbol = Refinery::Pages.default_parts.first.to_sym @page.content_for(part_symbol) = @page.content_for(part_symbol).to_s.gsub( /href=(\'|\")\/(\'|\")/, "href='#{refinery_admin_root_path}'" ).gsub("home page", "Dashboard") =end render :template => "/refinery/pages/show", :layout => layout?, :status => 404 return false else super end end end end end end
Version data entries
13 entries across 13 versions & 1 rubygems