Sha256: bdc33d59270e848357efaf98ee16ec1aa60f3578f2d5be1516092cc5a2282ab6
Contents?: true
Size: 451 Bytes
Versions: 1
Compression:
Stored size: 451 Bytes
Contents
require 'haml' require 'sinatra/base' module Crono class Web < Sinatra::Base set :root, File.expand_path(File.dirname(__FILE__) + "/../../web") set :public_folder, Proc.new { "#{root}/assets" } set :views, Proc.new { "#{root}/views" } get '/' do @jobs = Crono::CronoJob.all haml :dashboard, format: :html5 end get '/jobs/:id' do @job = Crono::CronoJob.find(params[:id]) haml :job end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
crono-0.7.0 | lib/crono/web.rb |