Show More
Commit Description:
add enabled option for user
Commit Description:
add enabled option for user
References:
File last commit:
Show/Diff file:
Action:
app/views/problems/import.html.haml
| 71 lines
| 2.1 KiB
| text/x-haml
| HamlLexer
|
|
r204 | - content_for :head do | ||
= stylesheet_link_tag 'problems' | ||||
%h1 Import problems | ||||
r589 | %p= link_to '[Back to problem list]', problems_path | |||
|
r204 | |||
- if @problem and @problem.errors | ||||
=error_messages_for 'problem' | ||||
|
r321 | = form_tag({:action => 'do_import'}, :multipart => true) do | ||
|
r204 | .submitbox | ||
%table | ||||
%tr | ||||
%td Name: | ||||
%td= text_field_tag 'name' | ||||
%tr | ||||
%td Full name: | ||||
%td | ||||
= text_field_tag 'full_name' | ||||
%span{:class => 'help'} Leave blank to use the same value as the name above. | ||||
%tr | ||||
%td Testdata file: | ||||
|
r211 | %td= file_field_tag 'file' | ||
%tr | ||||
|
r210 | %td | ||
|
r211 | %td | ||
%span{:class => 'help'} | ||||
In .zip, .tgz, tar.gz, .tar format. | ||||
It should includes inputs (e.g., 1.in, 2a.in, 2b.in) | ||||
and solutions (e.g., 1.sol, 2a.sol, 2b.sol). | ||||
%br/ | ||||
You may put task description in *.html for raw html | ||||
and *.md or *.markdown for markdown. | ||||
r402 | %br/ | |||
You may also put a pdf file for the task description | ||||
%tr | ||||
%td Checker: | ||||
%td= select_tag 'checker', options_for_select([['Text checker','text'],['Float checker','float']], 'text') | ||||
%tr | ||||
%td | ||||
%td | ||||
%span{:class => 'help'} | ||||
"Text" checker checks if the text (including numbers) is the same, ignoring any whitespace | ||||
%br/ | ||||
"Float" checker checks if all numbers is within EPSILON error using formula |a-b| < EPSILON * max(|a|,|b|) | ||||
|
r212 | - if @allow_test_pair_import | ||
%tr | ||||
%td | ||||
%td | ||||
= check_box_tag 'import_to_db' | ||||
Import test data to database (for a test-pair task) | ||||
|
r204 | %tr | ||
%td Time limit: | ||||
%td | ||||
= text_field_tag 'time_limit' | ||||
%span{:class => 'help'} In seconds. Leave blank to use 1 sec. | ||||
%tr | ||||
%td Memory limit: | ||||
%td | ||||
= text_field_tag 'memory_limit' | ||||
%span{:class => 'help'} In MB. Leave blank to use 32MB. | ||||
%tr | ||||
%td | ||||
%td= submit_tag 'Import problem' | ||||
- if @log | ||||
%h3 Import log | ||||
%pre.import-log | ||||
= @log | ||||