|
|
@ -308,6 +308,7 @@ class ChallengesController < ApplicationController
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
def challenge_params
|
|
|
|
def challenge_params
|
|
|
|
|
|
|
|
tip_exception("评测时间不能超过300秒") if params[:challenge][:exec_time].to_i > 300
|
|
|
|
params.require(:challenge).permit(:subject, :task_pass, :difficulty, :score, :st, :modify_time, :test_set_average,
|
|
|
|
params.require(:challenge).permit(:subject, :task_pass, :difficulty, :score, :st, :modify_time, :test_set_average,
|
|
|
|
:path, :exec_path, :show_type, :original_picture_path, :test_set_score,
|
|
|
|
:path, :exec_path, :show_type, :original_picture_path, :test_set_score,
|
|
|
|
:expect_picture_path, :picture_path, :web_route, :answer, :exec_time)
|
|
|
|
:expect_picture_path, :picture_path, :web_route, :answer, :exec_time)
|
|
|
|