Show More
Commit Description:
add cheat detail
Commit Description:
add cheat detail
References:
File last commit:
Show/Diff file:
Action:
app/controllers/configurations_controller.rb | 28 lines | 664 B | text/x-ruby | RubyLexer |
class ConfigurationsController < ApplicationController
before_filter :authenticate
before_filter { |controller| controller.authorization_by_roles(['admin'])}
def index
@configurations = GraderConfiguration.find(:all,
:order => '`key`')
end
def reload
GraderConfiguration.reload
redirect_to :action => 'index'
end
def update
@config = GraderConfiguration.find(params[:id])
respond_to do |format|
if @config.update_attributes(params[:grader_configuration])
format.json { head :ok }
else
format.json { respond_with_bip(@config) }
end
end
end
end