Description:
revert simple_form_for to form_tag
Commit status:
[Not Reviewed]
References:
Diff options:
Comments:
0 Commit comments
0 Inline Comments
Unresolved TODOs:
There are no unresolved TODOs
r758:d23edd5adc06 - - 3 files changed: 7 inserted, 26 deleted
@@ -73,49 +73,48 | |||||
|
73 | bootstrap-toggle-rails (2.2.1.0) |
|
73 | bootstrap-toggle-rails (2.2.1.0) |
|
74 | bootstrap3-datetimepicker-rails (4.17.47) |
|
74 | bootstrap3-datetimepicker-rails (4.17.47) |
|
75 | momentjs-rails (>= 2.8.1) |
|
75 | momentjs-rails (>= 2.8.1) |
|
76 | builder (3.2.3) |
|
76 | builder (3.2.3) |
|
77 | byebug (11.0.1) |
|
77 | byebug (11.0.1) |
|
78 | capybara (3.25.0) |
|
78 | capybara (3.25.0) |
|
79 | addressable |
|
79 | addressable |
|
80 | mini_mime (>= 0.1.3) |
|
80 | mini_mime (>= 0.1.3) |
|
81 | nokogiri (~> 1.8) |
|
81 | nokogiri (~> 1.8) |
|
82 | rack (>= 1.6.0) |
|
82 | rack (>= 1.6.0) |
|
83 | rack-test (>= 0.6.3) |
|
83 | rack-test (>= 0.6.3) |
|
84 | regexp_parser (~> 1.5) |
|
84 | regexp_parser (~> 1.5) |
|
85 | xpath (~> 3.2) |
|
85 | xpath (~> 3.2) |
|
86 | childprocess (1.0.1) |
|
86 | childprocess (1.0.1) |
|
87 | rake (< 13.0) |
|
87 | rake (< 13.0) |
|
88 | coffee-rails (4.2.2) |
|
88 | coffee-rails (4.2.2) |
|
89 | coffee-script (>= 2.2.0) |
|
89 | coffee-script (>= 2.2.0) |
|
90 | railties (>= 4.0.0) |
|
90 | railties (>= 4.0.0) |
|
91 | coffee-script (2.4.1) |
|
91 | coffee-script (2.4.1) |
|
92 | coffee-script-source |
|
92 | coffee-script-source |
|
93 | execjs |
|
93 | execjs |
|
94 | coffee-script-source (1.12.2) |
|
94 | coffee-script-source (1.12.2) |
|
95 | concurrent-ruby (1.1.5) |
|
95 | concurrent-ruby (1.1.5) |
|
96 | crass (1.0.4) |
|
96 | crass (1.0.4) |
|
97 | - diff-lcs (1.3) |
|
||
|
98 | dynamic_form (1.1.4) |
|
97 | dynamic_form (1.1.4) |
|
99 | erubi (1.8.0) |
|
98 | erubi (1.8.0) |
|
100 | erubis (2.7.0) |
|
99 | erubis (2.7.0) |
|
101 | execjs (2.7.0) |
|
100 | execjs (2.7.0) |
|
102 | ffi (1.11.1) |
|
101 | ffi (1.11.1) |
|
103 | fuzzy-string-match (1.0.1) |
|
102 | fuzzy-string-match (1.0.1) |
|
104 | RubyInline (>= 3.8.6) |
|
103 | RubyInline (>= 3.8.6) |
|
105 | globalid (0.4.2) |
|
104 | globalid (0.4.2) |
|
106 | activesupport (>= 4.2.0) |
|
105 | activesupport (>= 4.2.0) |
|
107 | haml (5.1.0) |
|
106 | haml (5.1.0) |
|
108 | temple (>= 0.8.0) |
|
107 | temple (>= 0.8.0) |
|
109 | tilt |
|
108 | tilt |
|
110 | haml-rails (1.0.0) |
|
109 | haml-rails (1.0.0) |
|
111 | actionpack (>= 4.0.1) |
|
110 | actionpack (>= 4.0.1) |
|
112 | activesupport (>= 4.0.1) |
|
111 | activesupport (>= 4.0.1) |
|
113 | haml (>= 4.0.6, < 6.0) |
|
112 | haml (>= 4.0.6, < 6.0) |
|
114 | html2haml (>= 1.0.1) |
|
113 | html2haml (>= 1.0.1) |
|
115 | railties (>= 4.0.1) |
|
114 | railties (>= 4.0.1) |
|
116 | html2haml (2.2.0) |
|
115 | html2haml (2.2.0) |
|
117 | erubis (~> 2.7.0) |
|
116 | erubis (~> 2.7.0) |
|
118 | haml (>= 4.0, < 6) |
|
117 | haml (>= 4.0, < 6) |
|
119 | nokogiri (>= 1.6.0) |
|
118 | nokogiri (>= 1.6.0) |
|
120 | ruby_parser (~> 3.5) |
|
119 | ruby_parser (~> 3.5) |
|
121 | i18n (1.6.0) |
|
120 | i18n (1.6.0) |
@@ -190,65 +189,48 | |||||
|
190 | rails-controller-testing (1.0.4) |
|
189 | rails-controller-testing (1.0.4) |
|
191 | actionpack (>= 5.0.1.x) |
|
190 | actionpack (>= 5.0.1.x) |
|
192 | actionview (>= 5.0.1.x) |
|
191 | actionview (>= 5.0.1.x) |
|
193 | activesupport (>= 5.0.1.x) |
|
192 | activesupport (>= 5.0.1.x) |
|
194 | rails-dom-testing (2.0.3) |
|
193 | rails-dom-testing (2.0.3) |
|
195 | activesupport (>= 4.2.0) |
|
194 | activesupport (>= 4.2.0) |
|
196 | nokogiri (>= 1.6) |
|
195 | nokogiri (>= 1.6) |
|
197 | rails-html-sanitizer (1.0.4) |
|
196 | rails-html-sanitizer (1.0.4) |
|
198 | loofah (~> 2.2, >= 2.2.2) |
|
197 | loofah (~> 2.2, >= 2.2.2) |
|
199 | rails_bootstrap_sortable (2.0.6) |
|
198 | rails_bootstrap_sortable (2.0.6) |
|
200 | momentjs-rails (>= 2.8.3) |
|
199 | momentjs-rails (>= 2.8.3) |
|
201 | railties (5.2.3) |
|
200 | railties (5.2.3) |
|
202 | actionpack (= 5.2.3) |
|
201 | actionpack (= 5.2.3) |
|
203 | activesupport (= 5.2.3) |
|
202 | activesupport (= 5.2.3) |
|
204 | method_source |
|
203 | method_source |
|
205 | rake (>= 0.8.7) |
|
204 | rake (>= 0.8.7) |
|
206 | thor (>= 0.19.0, < 2.0) |
|
205 | thor (>= 0.19.0, < 2.0) |
|
207 | rake (12.3.2) |
|
206 | rake (12.3.2) |
|
208 | rb-fsevent (0.10.3) |
|
207 | rb-fsevent (0.10.3) |
|
209 | rb-inotify (0.10.0) |
|
208 | rb-inotify (0.10.0) |
|
210 | ffi (~> 1.0) |
|
209 | ffi (~> 1.0) |
|
211 | rdiscount (2.2.0.1) |
|
210 | rdiscount (2.2.0.1) |
|
212 | regexp_parser (1.5.1) |
|
211 | regexp_parser (1.5.1) |
|
213 | rouge (3.3.0) |
|
212 | rouge (3.3.0) |
|
214 | - rspec-core (3.8.2) |
|
||
|
215 | - rspec-support (~> 3.8.0) |
|
||
|
216 | - rspec-expectations (3.8.4) |
|
||
|
217 | - diff-lcs (>= 1.2.0, < 2.0) |
|
||
|
218 | - rspec-support (~> 3.8.0) |
|
||
|
219 | - rspec-mocks (3.8.1) |
|
||
|
220 | - diff-lcs (>= 1.2.0, < 2.0) |
|
||
|
221 | - rspec-support (~> 3.8.0) |
|
||
|
222 | - rspec-rails (3.8.2) |
|
||
|
223 | - actionpack (>= 3.0) |
|
||
|
224 | - activesupport (>= 3.0) |
|
||
|
225 | - railties (>= 3.0) |
|
||
|
226 | - rspec-core (~> 3.8.0) |
|
||
|
227 | - rspec-expectations (~> 3.8.0) |
|
||
|
228 | - rspec-mocks (~> 3.8.0) |
|
||
|
229 | - rspec-support (~> 3.8.0) |
|
||
|
230 | - rspec-support (3.8.2) |
|
||
|
231 | ruby-progressbar (1.10.0) |
|
213 | ruby-progressbar (1.10.0) |
|
232 | ruby_dep (1.5.0) |
|
214 | ruby_dep (1.5.0) |
|
233 | ruby_parser (3.13.1) |
|
215 | ruby_parser (3.13.1) |
|
234 | sexp_processor (~> 4.9) |
|
216 | sexp_processor (~> 4.9) |
|
235 | rubyzip (1.2.3) |
|
217 | rubyzip (1.2.3) |
|
236 | sass (3.7.4) |
|
218 | sass (3.7.4) |
|
237 | sass-listen (~> 4.0.0) |
|
219 | sass-listen (~> 4.0.0) |
|
238 | sass-listen (4.0.0) |
|
220 | sass-listen (4.0.0) |
|
239 | rb-fsevent (~> 0.9, >= 0.9.4) |
|
221 | rb-fsevent (~> 0.9, >= 0.9.4) |
|
240 | rb-inotify (~> 0.9, >= 0.9.7) |
|
222 | rb-inotify (~> 0.9, >= 0.9.7) |
|
241 | sass-rails (5.0.7) |
|
223 | sass-rails (5.0.7) |
|
242 | railties (>= 4.0.0, < 6) |
|
224 | railties (>= 4.0.0, < 6) |
|
243 | sass (~> 3.1) |
|
225 | sass (~> 3.1) |
|
244 | sprockets (>= 2.8, < 4.0) |
|
226 | sprockets (>= 2.8, < 4.0) |
|
245 | sprockets-rails (>= 2.0, < 4.0) |
|
227 | sprockets-rails (>= 2.0, < 4.0) |
|
246 | tilt (>= 1.1, < 3) |
|
228 | tilt (>= 1.1, < 3) |
|
247 | sassc (2.0.1) |
|
229 | sassc (2.0.1) |
|
248 | ffi (~> 1.9) |
|
230 | ffi (~> 1.9) |
|
249 | rake |
|
231 | rake |
|
250 | sassc-rails (2.1.1) |
|
232 | sassc-rails (2.1.1) |
|
251 | railties (>= 4.0.0) |
|
233 | railties (>= 4.0.0) |
|
252 | sassc (>= 2.0) |
|
234 | sassc (>= 2.0) |
|
253 | sprockets (> 3.0) |
|
235 | sprockets (> 3.0) |
|
254 | sprockets-rails |
|
236 | sprockets-rails |
@@ -317,40 +299,39 | |||||
|
317 | coffee-rails |
|
299 | coffee-rails |
|
318 | dynamic_form |
|
300 | dynamic_form |
|
319 | fuzzy-string-match |
|
301 | fuzzy-string-match |
|
320 | haml |
|
302 | haml |
|
321 | haml-rails |
|
303 | haml-rails |
|
322 | in_place_editing |
|
304 | in_place_editing |
|
323 | jbuilder (~> 2.5) |
|
305 | jbuilder (~> 2.5) |
|
324 | jquery-countdown-rails |
|
306 | jquery-countdown-rails |
|
325 | jquery-datatables-rails |
|
307 | jquery-datatables-rails |
|
326 | jquery-rails |
|
308 | jquery-rails |
|
327 | jquery-tablesorter |
|
309 | jquery-tablesorter |
|
328 | jquery-timepicker-addon-rails |
|
310 | jquery-timepicker-addon-rails |
|
329 | jquery-ui-rails |
|
311 | jquery-ui-rails |
|
330 | listen (>= 3.0.5, < 3.2) |
|
312 | listen (>= 3.0.5, < 3.2) |
|
331 |
|
313 | ||
|
332 | minitest-reporters |
|
314 | minitest-reporters |
|
333 | momentjs-rails |
|
315 | momentjs-rails |
|
334 | mysql2 |
|
316 | mysql2 |
|
335 | puma |
|
317 | puma |
|
336 | rails (~> 5.2) |
|
318 | rails (~> 5.2) |
|
337 | rails-controller-testing |
|
319 | rails-controller-testing |
|
338 | rails_bootstrap_sortable |
|
320 | rails_bootstrap_sortable |
|
339 | rdiscount |
|
321 | rdiscount |
|
340 | rouge |
|
322 | rouge |
|
341 | - rspec-rails |
|
||
|
342 | sassc-rails |
|
323 | sassc-rails |
|
343 | select2-rails |
|
324 | select2-rails |
|
344 | selenium-webdriver |
|
325 | selenium-webdriver |
|
345 | simple_form |
|
326 | simple_form |
|
346 | spring |
|
327 | spring |
|
347 | spring-watcher-listen (~> 2.0.0) |
|
328 | spring-watcher-listen (~> 2.0.0) |
|
348 | sqlite3 |
|
329 | sqlite3 |
|
349 | uglifier |
|
330 | uglifier |
|
350 | web-console (>= 3.3.0) |
|
331 | web-console (>= 3.3.0) |
|
351 | webdriver |
|
332 | webdriver |
|
352 | will_paginate (~> 3.0.7) |
|
333 | will_paginate (~> 3.0.7) |
|
353 | yaml_db |
|
334 | yaml_db |
|
354 |
|
335 | ||
|
355 | BUNDLED WITH |
|
336 | BUNDLED WITH |
|
356 | 1.17.2 |
|
337 | 1.17.2 |
@@ -1,35 +1,35 | |||||
|
1 | - content_for :head do |
|
1 | - content_for :head do |
|
2 | = stylesheet_link_tag 'problems' |
|
2 | = stylesheet_link_tag 'problems' |
|
3 |
|
3 | ||
|
4 | %h1 Import problems |
|
4 | %h1 Import problems |
|
5 |
|
5 | ||
|
6 | %p= link_to '[Back to problem list]', problems_path |
|
6 | %p= link_to '[Back to problem list]', problems_path |
|
7 |
|
7 | ||
|
8 | - if @problem and @problem.errors |
|
8 | - if @problem and @problem.errors |
|
9 | =error_messages_for 'problem' |
|
9 | =error_messages_for 'problem' |
|
10 |
|
10 | ||
|
11 |
- = |
|
11 | + = form_tag do_import_problems_path, :multipart => true do |f| |
|
12 |
|
12 | ||
|
13 | .submitbox |
|
13 | .submitbox |
|
14 | %table |
|
14 | %table |
|
15 | %tr |
|
15 | %tr |
|
16 | %td Name: |
|
16 | %td Name: |
|
17 | %td= text_field_tag 'name' |
|
17 | %td= text_field_tag 'name' |
|
18 | %tr |
|
18 | %tr |
|
19 | %td Full name: |
|
19 | %td Full name: |
|
20 | %td |
|
20 | %td |
|
21 | = text_field_tag 'full_name' |
|
21 | = text_field_tag 'full_name' |
|
22 | %span{:class => 'help'} Leave blank to use the same value as the name above. |
|
22 | %span{:class => 'help'} Leave blank to use the same value as the name above. |
|
23 | %tr |
|
23 | %tr |
|
24 | %td Testdata file: |
|
24 | %td Testdata file: |
|
25 | %td= file_field_tag 'file' |
|
25 | %td= file_field_tag 'file' |
|
26 | %tr |
|
26 | %tr |
|
27 | %td |
|
27 | %td |
|
28 | %td |
|
28 | %td |
|
29 | %span{:class => 'help'} |
|
29 | %span{:class => 'help'} |
|
30 | In .zip, .tgz, tar.gz, .tar format. |
|
30 | In .zip, .tgz, tar.gz, .tar format. |
|
31 | It should includes inputs (e.g., 1.in, 2a.in, 2b.in) |
|
31 | It should includes inputs (e.g., 1.in, 2a.in, 2b.in) |
|
32 | and solutions (e.g., 1.sol, 2a.sol, 2b.sol). |
|
32 | and solutions (e.g., 1.sol, 2a.sol, 2b.sol). |
|
33 | %br/ |
|
33 | %br/ |
|
34 | You may put task description in *.html for raw html |
|
34 | You may put task description in *.html for raw html |
|
35 | and *.md or *.markdown for markdown. |
|
35 | and *.md or *.markdown for markdown. |
@@ -246,35 +246,35 | |||||
|
246 | root.password = 'ioionrails'; |
|
246 | root.password = 'ioionrails'; |
|
247 |
|
247 | ||
|
248 | class << root |
|
248 | class << root |
|
249 | public :encrypt_new_password |
|
249 | public :encrypt_new_password |
|
250 | def valid?(context=nil) |
|
250 | def valid?(context=nil) |
|
251 | true |
|
251 | true |
|
252 | end |
|
252 | end |
|
253 | end |
|
253 | end |
|
254 |
|
254 | ||
|
255 | root.encrypt_new_password |
|
255 | root.encrypt_new_password |
|
256 |
|
256 | ||
|
257 | root.roles << Role.find_by_name('admin') |
|
257 | root.roles << Role.find_by_name('admin') |
|
258 |
|
258 | ||
|
259 | root.activated = true |
|
259 | root.activated = true |
|
260 | root.save |
|
260 | root.save |
|
261 | end |
|
261 | end |
|
262 |
|
262 | ||
|
263 | def seed_users_and_roles |
|
263 | def seed_users_and_roles |
|
264 | seed_roles |
|
264 | seed_roles |
|
265 | seed_root |
|
265 | seed_root |
|
266 | end |
|
266 | end |
|
267 |
|
267 | ||
|
268 | def seed_more_languages |
|
268 | def seed_more_languages |
|
269 | Language.delete_all |
|
269 | Language.delete_all |
|
270 | - Language.create( name: 'c', pretty_name: 'C', ext: 'c', common_ext: 'c' ) |
|
270 | + Language.find_or_create_by( name: 'c', pretty_name: 'C', ext: 'c', common_ext: 'c' ) |
|
271 | - Language.create( name: 'cpp', pretty_name: 'C++', ext: 'cpp', common_ext: 'cpp,cc' ) |
|
271 | + Language.find_or_create_by( name: 'cpp', pretty_name: 'C++', ext: 'cpp', common_ext: 'cpp,cc' ) |
|
272 | - Language.create( name: 'pas', pretty_name: 'Pascal', ext: 'pas', common_ext: 'pas' ) |
|
272 | + Language.find_or_create_by( name: 'pas', pretty_name: 'Pascal', ext: 'pas', common_ext: 'pas' ) |
|
273 | - Language.create( name: 'ruby', pretty_name: 'Ruby', ext: 'rb', common_ext: 'rb' ) |
|
273 | + Language.find_or_create_by( name: 'ruby', pretty_name: 'Ruby', ext: 'rb', common_ext: 'rb' ) |
|
274 | - Language.create( name: 'python', pretty_name: 'Python', ext: 'py', common_ext: 'py' ) |
|
274 | + Language.find_or_create_by( name: 'python', pretty_name: 'Python', ext: 'py', common_ext: 'py' ) |
|
275 | - Language.create( name: 'java', pretty_name: 'Java', ext: 'java', common_ext: 'java' ) |
|
275 | + Language.find_or_create_by( name: 'java', pretty_name: 'Java', ext: 'java', common_ext: 'java' ) |
|
276 | end |
|
276 | end |
|
277 |
|
277 | ||
|
278 | seed_config |
|
278 | seed_config |
|
279 | seed_users_and_roles |
|
279 | seed_users_and_roles |
|
280 | seed_more_languages |
|
280 | seed_more_languages |
You need to be logged in to leave comments.
Login now