Class: Docushin::HomeController

Inherits:
ApplicationController show all
Defined in:
app/controllers/docushin/home_controller.rb

Instance Method Summary collapse

Instance Method Details

#indexObject



5
6
7
8
9
10
# File 'app/controllers/docushin/home_controller.rb', line 5

def index
  @routes = Dir["#{File.join(Rails.root, "doc/docushin")}/*.md"].collect do |file|
    @route_set.find(File.basename(file, ".md"))
  end
  @routes = @routes.compact.sort_by(&:updated_at).reverse.take(10)
end