Module: Storytime::Dashboard::SitesHelper

Defined in:
app/helpers/storytime/dashboard/sites_helper.rb

Instance Method Summary collapse

Instance Method Details

#application_layoutsObject



13
14
15
# File 'app/helpers/storytime/dashboard/sites_helper.rb', line 13

def application_layouts
  Dir.glob(Rails.root.join("app", "views", "layouts", "**/*")).map{|layout| layout.split("/").last.split(".")[0]}
end

#post_slug_style_optionsObject



4
5
6
7
8
9
10
11
# File 'app/helpers/storytime/dashboard/sites_helper.rb', line 4

def post_slug_style_options
  [
    ["Default - e.g. /posts/post-title", :default],
    ["Day and Name - e.g. /1985/06/09/post-title", :day_and_name], 
    ["Month and Name - e.g. /1985/06/post-title", :month_and_name], 
    ["Post ID - e.g. /posts/123", :post_id], 
  ]
end