Description:
fixed empty main/test bug
git-svn-id: http://theory.cpe.ku.ac.th/grader/web/trunk@90 6386c4cd-e34a-4fa8-8920-d93eb39b512e
Commit status:
[Not Reviewed]
References:
Diff options:
Comments:
0 Commit comments
0 Inline Comments
Unresolved TODOs:
There are no unresolved TODOs
r41:25eaa3e37851 - - 1 file changed: 5 inserted, 3 deleted
@@ -1,18 +1,17 | |||
|
1 | 1 | <h2>Test Interface</h2> |
|
2 | 2 | |
|
3 | 3 | <% if @problems.length==0 %> |
|
4 |
- |
|
|
5 | - <% return %> | |
|
6 | - <% end %> | |
|
4 | + There is no submission | |
|
5 | + <% else %> | |
|
7 | 6 | |
|
8 | 7 | <script type="text/javascript"> |
|
9 | 8 | var submissionCount = { |
|
10 | 9 | <% @submissions.each do |submission| %> |
|
11 | 10 | <%= submission.problem_id %> : <%= submission.number %>, |
|
12 | 11 | <% end %> |
|
13 | 12 | }; |
|
14 | 13 | function updateSubmissionList() { |
|
15 | 14 | currentProb = document.getElementById("test_request_problem_id").value; |
|
16 | 15 | count = submissionCount[currentProb]; |
|
17 | 16 | submissionSelect = document.getElementById("test_request_submission_number"); |
|
18 | 17 | submissionSelect.options.length = 0; |
@@ -56,12 +55,15 | |||
|
56 | 55 | |
|
57 | 56 | <h3>Previous requests</h3> |
|
58 | 57 | |
|
59 | 58 | <table border="1"> |
|
60 | 59 | <tr> |
|
61 | 60 | <th></td> |
|
62 | 61 | <th>problem</th> |
|
63 | 62 | <th>#</th> |
|
64 | 63 | <th>status</th> |
|
65 | 64 | </tr> |
|
66 | 65 | <%= render :partial => 'test_request', :collection => @user.test_requests %> |
|
67 | 66 | </table> |
|
67 | + | |
|
68 | + <% end %> | |
|
69 | + |
You need to be logged in to leave comments.
Login now