lets rails

This commit is contained in:
ablwr
2014-07-08 10:51:25 -04:00
parent 76cc98e6a1
commit d2797a77c5
97 changed files with 2756 additions and 2498 deletions

View File

@ -1,5 +0,0 @@
class ApplicationController < Sinatra::Base
register Sinatra::ActiveRecordExtension
set :session_secret, "my_application_secret"
set :views, Proc.new { File.join(root, "../views/") }
end

View File

@ -1,23 +0,0 @@
class GenerateController < ApplicationController
enable :sessions
get '/' do
erb :'index'
end
post '/' do
@input = params[:input]
# @output = params[:input][:video_format]
# session['generate'] = params[:input]
# @output = Generate.new(session['generate'])
@middle = Generate.new(@input)
@output = @middle.output
erb :'generate'
end
get '/generate' do
erb :'index'
end
end

View File

@ -0,0 +1,13 @@
class ApplicationController < ActionController::Base
# Prevent CSRF attacks by raising an exception.
# For APIs, you may want to use :null_session instead.
# protect_from_forgery with: :exception
def welcome
"test"
end
end

View File

View File

@ -0,0 +1,7 @@
class GenerateController < ApplicationController
def generate
end
end