Description:
main page show problem code separately
Commit status:
[Not Reviewed]
References:
Diff options:
Comments:
0 Commit comments
0 Inline Comments
Unresolved TODOs:
There are no unresolved TODOs
r447:049c108d9256 - - 2 files changed: 8 inserted, 3 deleted
@@ -1,18 +1,21 | |||||
|
1 | <tr class="info-<%= (problem_counter%2==0) ? "even" : "odd" %>"> |
|
1 | <tr class="info-<%= (problem_counter%2==0) ? "even" : "odd" %>"> |
|
2 | <td> |
|
2 | <td> |
|
3 | <%= "#{problem_counter+1}" %> |
|
3 | <%= "#{problem_counter+1}" %> |
|
4 | </td> |
|
4 | </td> |
|
5 | <td> |
|
5 | <td> |
|
6 |
- <%= " |
|
6 | + <%= "#{problem.name}"%> |
|
|
7 | + </td> | ||
|
|
8 | + <td> | ||
|
|
9 | + <%= "#{problem.full_name}" %> | ||
|
7 | <%= link_to_description_if_any "[#{t 'main.problem_desc'}]", problem %> |
|
10 | <%= link_to_description_if_any "[#{t 'main.problem_desc'}]", problem %> |
|
8 | </td> |
|
11 | </td> |
|
9 | <td align="center"> |
|
12 | <td align="center"> |
|
10 | <%= @prob_submissions[problem.id][:count] %> |
|
13 | <%= @prob_submissions[problem.id][:count] %> |
|
11 | </td> |
|
14 | </td> |
|
12 | <td> |
|
15 | <td> |
|
13 | <%= render :partial => 'submission_short', |
|
16 | <%= render :partial => 'submission_short', |
|
14 | :locals => { |
|
17 | :locals => { |
|
15 | :submission => @prob_submissions[problem.id][:submission], |
|
18 | :submission => @prob_submissions[problem.id][:submission], |
|
16 | :problem_name => problem.name }%> |
|
19 | :problem_name => problem.name }%> |
|
17 | </td> |
|
20 | </td> |
|
18 | </tr> |
|
21 | </tr> |
@@ -4,48 +4,50 | |||||
|
4 | = user_title_bar(@user) |
|
4 | = user_title_bar(@user) |
|
5 |
|
5 | ||
|
6 | .announcementbox{:style => (@announcements.length==0 ? "display:none" : "")} |
|
6 | .announcementbox{:style => (@announcements.length==0 ? "display:none" : "")} |
|
7 | %span{:class => 'title'} |
|
7 | %span{:class => 'title'} |
|
8 | Announcements |
|
8 | Announcements |
|
9 | #announcementbox-body |
|
9 | #announcementbox-body |
|
10 | = render :partial => 'announcement', :collection => @announcements |
|
10 | = render :partial => 'announcement', :collection => @announcements |
|
11 |
|
11 | ||
|
12 | - if GraderConfiguration.show_submitbox_to?(@user) |
|
12 | - if GraderConfiguration.show_submitbox_to?(@user) |
|
13 | .submitbox |
|
13 | .submitbox |
|
14 | = error_messages_for 'submission' |
|
14 | = error_messages_for 'submission' |
|
15 | = render :partial => 'submission_box' |
|
15 | = render :partial => 'submission_box' |
|
16 |
|
16 | ||
|
17 |
|
17 | ||
|
18 | %hr/ |
|
18 | %hr/ |
|
19 |
|
19 | ||
|
20 | - if (GraderConfiguration.contest_mode?) and (@user.site!=nil) and (@user.site.started!=true) |
|
20 | - if (GraderConfiguration.contest_mode?) and (@user.site!=nil) and (@user.site.started!=true) |
|
21 | %p=t 'main.start_soon' |
|
21 | %p=t 'main.start_soon' |
|
22 |
|
22 | ||
|
23 | - if GraderConfiguration.show_tasks_to?(@user) |
|
23 | - if GraderConfiguration.show_tasks_to?(@user) |
|
24 | - if not GraderConfiguration.multicontests? |
|
24 | - if not GraderConfiguration.multicontests? |
|
25 | %table.info |
|
25 | %table.info |
|
26 | %tr.info-head |
|
26 | %tr.info-head |
|
27 | %th |
|
27 | %th |
|
28 | - %th Tasks |
|
28 | + %th Tasks name |
|
|
29 | + %th Full name | ||
|
29 | %th # of sub(s) |
|
30 | %th # of sub(s) |
|
30 | %th Results |
|
31 | %th Results |
|
31 | = render :partial => 'problem', :collection => @problems |
|
32 | = render :partial => 'problem', :collection => @problems |
|
32 | - else |
|
33 | - else |
|
33 | - @contest_problems.each do |cp| |
|
34 | - @contest_problems.each do |cp| |
|
34 | - if cp[:problems].length > 0 |
|
35 | - if cp[:problems].length > 0 |
|
35 | %h2{:class =>'contest-title'} |
|
36 | %h2{:class =>'contest-title'} |
|
36 | = "#{cp[:contest] ? cp[:contest].title : 'Public problems'}" |
|
37 | = "#{cp[:contest] ? cp[:contest].title : 'Public problems'}" |
|
37 | %table.info |
|
38 | %table.info |
|
38 | %tr.info-head |
|
39 | %tr.info-head |
|
39 | %th |
|
40 | %th |
|
40 | - %th Tasks |
|
41 | + %th Tasks name |
|
|
42 | + %th Full name | ||
|
41 | %th # of sub(s) |
|
43 | %th # of sub(s) |
|
42 | %th Results |
|
44 | %th Results |
|
43 | = render :partial => 'problem', :collection => cp[:problems] |
|
45 | = render :partial => 'problem', :collection => cp[:problems] |
|
44 |
|
46 | ||
|
45 |
|
47 | ||
|
46 | %hr/ |
|
48 | %hr/ |
|
47 |
|
49 | ||
|
48 | %script{:type => 'text/javascript'} |
|
50 | %script{:type => 'text/javascript'} |
|
49 | = "Announcement.refreshUrl = '#{url_for :controller => 'main', :action => 'announcements'}';" |
|
51 | = "Announcement.refreshUrl = '#{url_for :controller => 'main', :action => 'announcements'}';" |
|
50 | Announcement.registerRefreshEventTimer(); |
|
52 | Announcement.registerRefreshEventTimer(); |
|
51 |
|
53 |
You need to be logged in to leave comments.
Login now