Description:
Merge pull request #12 from wytesk133/master
Updated Gemfile and fixed various bugs
Commit status:
[Not Reviewed]
References:
Diff options:
Comments:
0 Commit comments
0 Inline Comments
Unresolved TODOs:
There are no unresolved TODOs
r379:91238b16dbc9 - - 11 files changed: 76 inserted, 71 deleted
@@ -1,6 +1,6 | |||||
|
1 | source 'https://rubygems.org' |
|
1 | source 'https://rubygems.org' |
|
2 |
|
2 | ||
|
3 |
- gem 'rails', '3.2.1 |
|
3 | + gem 'rails', '3.2.21' |
|
4 |
|
4 | ||
|
5 | # Bundle edge Rails instead: |
|
5 | # Bundle edge Rails instead: |
|
6 | # gem 'rails', :git => 'git://github.com/rails/rails.git' |
|
6 | # gem 'rails', :git => 'git://github.com/rails/rails.git' |
@@ -10,13 +10,13 | |||||
|
10 | # Gems used only for assets and not required |
|
10 | # Gems used only for assets and not required |
|
11 | # in production environments by default. |
|
11 | # in production environments by default. |
|
12 | group :assets do |
|
12 | group :assets do |
|
13 |
- gem 'sass-rails', '~> 3.2. |
|
13 | + gem 'sass-rails', '~> 3.2.6' |
|
14 |
- gem 'coffee-rails', '~> 3.2. |
|
14 | + gem 'coffee-rails', '~> 3.2.2' |
|
15 |
|
15 | ||
|
16 | # See https://github.com/sstephenson/execjs#readme for more supported runtimes |
|
16 | # See https://github.com/sstephenson/execjs#readme for more supported runtimes |
|
17 | # gem 'therubyracer', :platforms => :ruby |
|
17 | # gem 'therubyracer', :platforms => :ruby |
|
18 |
|
18 | ||
|
19 |
- gem 'uglifier' |
|
19 | + gem 'uglifier' |
|
20 | end |
|
20 | end |
|
21 |
|
21 | ||
|
22 | gem 'prototype-rails' |
|
22 | gem 'prototype-rails' |
@@ -36,15 +36,15 | |||||
|
36 | # To use debugger |
|
36 | # To use debugger |
|
37 | # gem 'debugger' |
|
37 | # gem 'debugger' |
|
38 |
|
38 | ||
|
39 |
- gem |
|
39 | + gem 'haml' |
|
40 |
- gem |
|
40 | + gem 'mail' |
|
41 |
- gem |
|
41 | + gem 'rdiscount' |
|
42 |
- gem |
|
42 | + gem 'test-unit' |
|
43 |
- gem 'will_paginate', '~> 3.0. |
|
43 | + gem 'will_paginate', '~> 3.0.7' |
|
44 | gem 'dynamic_form' |
|
44 | gem 'dynamic_form' |
|
45 | gem 'in_place_editing' |
|
45 | gem 'in_place_editing' |
|
46 |
- gem 'verification', :git => ' |
|
46 | + gem 'verification', :git => 'https://github.com/sikachu/verification.git' |
|
47 |
|
47 | ||
|
48 | group :test, :development do |
|
48 | group :test, :development do |
|
49 |
- gem |
|
49 | + gem 'rspec-rails', '~> 2.99.0' |
|
50 | end |
|
50 | end |
@@ -1,5 +1,5 | |||||
|
1 | GIT |
|
1 | GIT |
|
2 |
- remote: |
|
2 | + remote: https://github.com/sikachu/verification.git |
|
3 | revision: 76eaf51b13276ecae54bd9cd115832595d2ff56d |
|
3 | revision: 76eaf51b13276ecae54bd9cd115832595d2ff56d |
|
4 | specs: |
|
4 | specs: |
|
5 | verification (1.0.3) |
|
5 | verification (1.0.3) |
@@ -9,12 +9,12 | |||||
|
9 | GEM |
|
9 | GEM |
|
10 | remote: https://rubygems.org/ |
|
10 | remote: https://rubygems.org/ |
|
11 | specs: |
|
11 | specs: |
|
12 |
- actionmailer (3.2.1 |
|
12 | + actionmailer (3.2.21) |
|
13 |
- actionpack (= 3.2.1 |
|
13 | + actionpack (= 3.2.21) |
|
14 | mail (~> 2.5.4) |
|
14 | mail (~> 2.5.4) |
|
15 |
- actionpack (3.2.1 |
|
15 | + actionpack (3.2.21) |
|
16 |
- activemodel (= 3.2.1 |
|
16 | + activemodel (= 3.2.21) |
|
17 |
- activesupport (= 3.2.1 |
|
17 | + activesupport (= 3.2.21) |
|
18 | builder (~> 3.0.0) |
|
18 | builder (~> 3.0.0) |
|
19 | erubis (~> 2.7.0) |
|
19 | erubis (~> 2.7.0) |
|
20 | journey (~> 1.0.4) |
|
20 | journey (~> 1.0.4) |
@@ -22,18 +22,18 | |||||
|
22 | rack-cache (~> 1.2) |
|
22 | rack-cache (~> 1.2) |
|
23 | rack-test (~> 0.6.1) |
|
23 | rack-test (~> 0.6.1) |
|
24 | sprockets (~> 2.2.1) |
|
24 | sprockets (~> 2.2.1) |
|
25 |
- activemodel (3.2.1 |
|
25 | + activemodel (3.2.21) |
|
26 |
- activesupport (= 3.2.1 |
|
26 | + activesupport (= 3.2.21) |
|
27 | builder (~> 3.0.0) |
|
27 | builder (~> 3.0.0) |
|
28 |
- activerecord (3.2.1 |
|
28 | + activerecord (3.2.21) |
|
29 |
- activemodel (= 3.2.1 |
|
29 | + activemodel (= 3.2.21) |
|
30 |
- activesupport (= 3.2.1 |
|
30 | + activesupport (= 3.2.21) |
|
31 | arel (~> 3.0.2) |
|
31 | arel (~> 3.0.2) |
|
32 | tzinfo (~> 0.3.29) |
|
32 | tzinfo (~> 0.3.29) |
|
33 |
- activeresource (3.2.1 |
|
33 | + activeresource (3.2.21) |
|
34 |
- activemodel (= 3.2.1 |
|
34 | + activemodel (= 3.2.21) |
|
35 |
- activesupport (= 3.2.1 |
|
35 | + activesupport (= 3.2.21) |
|
36 |
- activesupport (3.2.1 |
|
36 | + activesupport (3.2.21) |
|
37 | i18n (~> 0.6, >= 0.6.4) |
|
37 | i18n (~> 0.6, >= 0.6.4) |
|
38 | multi_json (~> 1.0) |
|
38 | multi_json (~> 1.0) |
|
39 | arel (3.0.3) |
|
39 | arel (3.0.3) |
@@ -44,15 +44,15 | |||||
|
44 | coffee-script (2.3.0) |
|
44 | coffee-script (2.3.0) |
|
45 | coffee-script-source |
|
45 | coffee-script-source |
|
46 | execjs |
|
46 | execjs |
|
47 |
- coffee-script-source (1. |
|
47 | + coffee-script-source (1.8.0) |
|
48 | diff-lcs (1.2.5) |
|
48 | diff-lcs (1.2.5) |
|
49 | dynamic_form (1.1.4) |
|
49 | dynamic_form (1.1.4) |
|
50 | erubis (2.7.0) |
|
50 | erubis (2.7.0) |
|
51 |
- execjs (2.2. |
|
51 | + execjs (2.2.2) |
|
52 |
- haml (4.0. |
|
52 | + haml (4.0.6) |
|
53 | tilt |
|
53 | tilt |
|
54 | hike (1.2.3) |
|
54 | hike (1.2.3) |
|
55 |
- i18n (0. |
|
55 | + i18n (0.7.0) |
|
56 | in_place_editing (1.2.0) |
|
56 | in_place_editing (1.2.0) |
|
57 | journey (1.0.4) |
|
57 | journey (1.0.4) |
|
58 | json (1.8.1) |
|
58 | json (1.8.1) |
@@ -61,9 +61,9 | |||||
|
61 | treetop (~> 1.4.8) |
|
61 | treetop (~> 1.4.8) |
|
62 | mime-types (1.25.1) |
|
62 | mime-types (1.25.1) |
|
63 | multi_json (1.10.1) |
|
63 | multi_json (1.10.1) |
|
64 |
- mysql2 (0.3.1 |
|
64 | + mysql2 (0.3.17) |
|
65 | polyglot (0.3.5) |
|
65 | polyglot (0.3.5) |
|
66 |
- power_assert (0. |
|
66 | + power_assert (0.2.2) |
|
67 | prototype-rails (3.2.1) |
|
67 | prototype-rails (3.2.1) |
|
68 | rails (~> 3.2) |
|
68 | rails (~> 3.2) |
|
69 | rack (1.4.5) |
|
69 | rack (1.4.5) |
@@ -73,26 +73,26 | |||||
|
73 | rack |
|
73 | rack |
|
74 | rack-test (0.6.2) |
|
74 | rack-test (0.6.2) |
|
75 | rack (>= 1.0) |
|
75 | rack (>= 1.0) |
|
76 |
- rails (3.2.1 |
|
76 | + rails (3.2.21) |
|
77 |
- actionmailer (= 3.2.1 |
|
77 | + actionmailer (= 3.2.21) |
|
78 |
- actionpack (= 3.2.1 |
|
78 | + actionpack (= 3.2.21) |
|
79 |
- activerecord (= 3.2.1 |
|
79 | + activerecord (= 3.2.21) |
|
80 |
- activeresource (= 3.2.1 |
|
80 | + activeresource (= 3.2.21) |
|
81 |
- activesupport (= 3.2.1 |
|
81 | + activesupport (= 3.2.21) |
|
82 | bundler (~> 1.0) |
|
82 | bundler (~> 1.0) |
|
83 |
- railties (= 3.2.1 |
|
83 | + railties (= 3.2.21) |
|
84 |
- railties (3.2.1 |
|
84 | + railties (3.2.21) |
|
85 |
- actionpack (= 3.2.1 |
|
85 | + actionpack (= 3.2.21) |
|
86 |
- activesupport (= 3.2.1 |
|
86 | + activesupport (= 3.2.21) |
|
87 | rack-ssl (~> 1.3.2) |
|
87 | rack-ssl (~> 1.3.2) |
|
88 | rake (>= 0.8.7) |
|
88 | rake (>= 0.8.7) |
|
89 | rdoc (~> 3.4) |
|
89 | rdoc (~> 3.4) |
|
90 | thor (>= 0.14.6, < 2.0) |
|
90 | thor (>= 0.14.6, < 2.0) |
|
91 |
- rake (10. |
|
91 | + rake (10.4.2) |
|
92 | rdiscount (2.1.7.1) |
|
92 | rdiscount (2.1.7.1) |
|
93 | rdoc (3.12.2) |
|
93 | rdoc (3.12.2) |
|
94 | json (~> 1.4) |
|
94 | json (~> 1.4) |
|
95 |
- rspec-collection_matchers (1. |
|
95 | + rspec-collection_matchers (1.1.2) |
|
96 | rspec-expectations (>= 2.99.0.beta1) |
|
96 | rspec-expectations (>= 2.99.0.beta1) |
|
97 | rspec-core (2.99.2) |
|
97 | rspec-core (2.99.2) |
|
98 | rspec-expectations (2.99.2) |
|
98 | rspec-expectations (2.99.2) |
@@ -107,25 +107,25 | |||||
|
107 | rspec-core (~> 2.99.0) |
|
107 | rspec-core (~> 2.99.0) |
|
108 | rspec-expectations (~> 2.99.0) |
|
108 | rspec-expectations (~> 2.99.0) |
|
109 | rspec-mocks (~> 2.99.0) |
|
109 | rspec-mocks (~> 2.99.0) |
|
110 |
- sass (3.4. |
|
110 | + sass (3.4.9) |
|
111 | sass-rails (3.2.6) |
|
111 | sass-rails (3.2.6) |
|
112 | railties (~> 3.2.0) |
|
112 | railties (~> 3.2.0) |
|
113 | sass (>= 3.1.10) |
|
113 | sass (>= 3.1.10) |
|
114 | tilt (~> 1.3) |
|
114 | tilt (~> 1.3) |
|
115 |
- sprockets (2.2. |
|
115 | + sprockets (2.2.3) |
|
116 | hike (~> 1.2) |
|
116 | hike (~> 1.2) |
|
117 | multi_json (~> 1.0) |
|
117 | multi_json (~> 1.0) |
|
118 | rack (~> 1.0) |
|
118 | rack (~> 1.0) |
|
119 | tilt (~> 1.1, != 1.3.0) |
|
119 | tilt (~> 1.1, != 1.3.0) |
|
120 |
- test-unit (3.0. |
|
120 | + test-unit (3.0.9) |
|
121 | power_assert |
|
121 | power_assert |
|
122 | thor (0.19.1) |
|
122 | thor (0.19.1) |
|
123 | tilt (1.4.1) |
|
123 | tilt (1.4.1) |
|
124 | treetop (1.4.15) |
|
124 | treetop (1.4.15) |
|
125 | polyglot |
|
125 | polyglot |
|
126 | polyglot (>= 0.3.1) |
|
126 | polyglot (>= 0.3.1) |
|
127 |
- tzinfo (0.3.4 |
|
127 | + tzinfo (0.3.42) |
|
128 |
- uglifier (2. |
|
128 | + uglifier (2.6.0) |
|
129 | execjs (>= 0.3.0) |
|
129 | execjs (>= 0.3.0) |
|
130 | json (>= 1.8.0) |
|
130 | json (>= 1.8.0) |
|
131 | will_paginate (3.0.7) |
|
131 | will_paginate (3.0.7) |
@@ -134,18 +134,18 | |||||
|
134 | ruby |
|
134 | ruby |
|
135 |
|
135 | ||
|
136 | DEPENDENCIES |
|
136 | DEPENDENCIES |
|
137 |
- coffee-rails (~> 3.2. |
|
137 | + coffee-rails (~> 3.2.2) |
|
138 | dynamic_form |
|
138 | dynamic_form |
|
139 | haml |
|
139 | haml |
|
140 | in_place_editing |
|
140 | in_place_editing |
|
141 |
|
141 | ||
|
142 | mysql2 |
|
142 | mysql2 |
|
143 | prototype-rails |
|
143 | prototype-rails |
|
144 |
- rails (= 3.2.1 |
|
144 | + rails (= 3.2.21) |
|
145 | rdiscount |
|
145 | rdiscount |
|
146 | - rspec-rails (~> 2.0) |
|
146 | + rspec-rails (~> 2.99.0) |
|
147 |
- sass-rails (~> 3.2. |
|
147 | + sass-rails (~> 3.2.6) |
|
148 | test-unit |
|
148 | test-unit |
|
149 |
- uglifier |
|
149 | + uglifier |
|
150 | verification! |
|
150 | verification! |
|
151 |
- will_paginate (~> 3.0. |
|
151 | + will_paginate (~> 3.0.7) |
@@ -31,20 +31,21 | |||||
|
31 | user = User.find(session[:user_id]) |
|
31 | user = User.find(session[:user_id]) |
|
32 | @message = Message.new(params[:message]) |
|
32 | @message = Message.new(params[:message]) |
|
33 | @message.sender = user |
|
33 | @message.sender = user |
|
34 | - if !@message.save |
|
34 | + if @message.body == '' or !@message.save |
|
35 | - render :action => 'list' and return |
|
35 | + flash[:notice] = 'An error occurred' |
|
36 | else |
|
36 | else |
|
37 | flash[:notice] = 'New message posted' |
|
37 | flash[:notice] = 'New message posted' |
|
38 | - redirect_to :action => 'list' |
|
||
|
39 | end |
|
38 | end |
|
|
39 | + redirect_to :action => 'list' | ||
|
40 | end |
|
40 | end |
|
41 |
|
41 | ||
|
42 | def reply |
|
42 | def reply |
|
43 | user = User.find(session[:user_id]) |
|
43 | user = User.find(session[:user_id]) |
|
44 | @message = Message.new(params[:r_message]) |
|
44 | @message = Message.new(params[:r_message]) |
|
45 | @message.sender = user |
|
45 | @message.sender = user |
|
46 | - if !@message.save |
|
46 | + if @message.body == '' or !@message.save |
|
47 | - render :action => 'show' and return |
|
47 | + flash[:notice] = 'An error occurred' |
|
|
48 | + redirect_to :action => 'show', :id => @message.replying_message_id | ||
|
48 | else |
|
49 | else |
|
49 | flash[:notice] = 'Message replied' |
|
50 | flash[:notice] = 'Message replied' |
|
50 | rep_msg = @message.replying_message |
|
51 | rep_msg = @message.replying_message |
@@ -58,7 +59,7 | |||||
|
58 | message = Message.find(params[:id]) |
|
59 | message = Message.find(params[:id]) |
|
59 | message.replied = true |
|
60 | message.replied = true |
|
60 | message.save |
|
61 | message.save |
|
61 |
- flash[:notice] = 'Message hid |
|
62 | + flash[:notice] = 'Message hidden (just marked replied)' |
|
62 | redirect_to :action => 'console' |
|
63 | redirect_to :action => 'console' |
|
63 | end |
|
64 | end |
|
64 |
|
65 |
@@ -1,5 +1,5 | |||||
|
1 |
|
1 | ||
|
2 | - <% if compiler_message==nil or compiler_message=='' %> |
|
2 | + <% if compiler_message == nil or compiler_message.chomp == '' %> |
|
3 | No message |
|
3 | No message |
|
4 | <% else %> |
|
4 | <% else %> |
|
5 | <div><div><a href="#" onClick="n = this.parentNode.parentNode.lastChild; |
|
5 | <div><div><a href="#" onClick="n = this.parentNode.parentNode.lastChild; |
@@ -1,6 +1,6 | |||||
|
1 | %h2= "Compiler message for submission \##{@submission.number}, task: #{@submission.problem.name}" |
|
1 | %h2= "Compiler message for submission \##{@submission.number}, task: #{@submission.problem.name}" |
|
2 | %p |
|
2 | %p |
|
3 | - - if @submission.compiler_message.chomp == '' |
|
3 | + - if @submission.compiler_message == nil or @submission.compiler_message.chomp == '' |
|
4 |
- |
|
4 | + No message |
|
5 | - else |
|
5 | - else |
|
6 | = simple_format(@submission.compiler_message) |
|
6 | = simple_format(@submission.compiler_message) |
@@ -14,7 +14,7 | |||||
|
14 | <%= password_field 'user', 'password_confirmation' %></p> |
|
14 | <%= password_field 'user', 'password_confirmation' %></p> |
|
15 |
|
15 | ||
|
16 | <p><label for="user_email">E-mail</label><br/> |
|
16 | <p><label for="user_email">E-mail</label><br/> |
|
17 |
- <%= |
|
17 | + <%= email_field 'user', 'email' %></p> |
|
18 |
|
18 | ||
|
19 | <p><label for="user_alias">Alias</label><br/> |
|
19 | <p><label for="user_alias">Alias</label><br/> |
|
20 | <%= text_field 'user', 'alias' %></p> |
|
20 | <%= text_field 'user', 'alias' %></p> |
@@ -16,7 +16,7 | |||||
|
16 | <td><%= text_field 'user', 'full_name', :size => 30 %></td> |
|
16 | <td><%= text_field 'user', 'full_name', :size => 30 %></td> |
|
17 | <td><%= password_field 'user', 'password', :size => 10 %></td> |
|
17 | <td><%= password_field 'user', 'password', :size => 10 %></td> |
|
18 | <td><%= password_field 'user', 'password_confirmation', :size => 10 %></td> |
|
18 | <td><%= password_field 'user', 'password_confirmation', :size => 10 %></td> |
|
19 |
- <td><%= |
|
19 | + <td><%= email_field 'user', 'email', :size => 15 %></td> |
|
20 | <td><%= submit_tag "Create" %></td> |
|
20 | <td><%= submit_tag "Create" %></td> |
|
21 | </tr> |
|
21 | </tr> |
|
22 | </table> |
|
22 | </table> |
@@ -11,7 +11,8 | |||||
|
11 |
|
11 | ||
|
12 | = form_tag :action => 'retrieve_password' do |
|
12 | = form_tag :action => 'retrieve_password' do |
|
13 | =t 'registration.password_retrieval.instructions' |
|
13 | =t 'registration.password_retrieval.instructions' |
|
14 | - = text_field 'email', nil, :size => 20 |
|
14 | + %br/ |
|
|
15 | + = email_field 'email', nil, :size => 20 | ||
|
15 | %br/ |
|
16 | %br/ |
|
16 | = submit_tag(t 'registration.password_retrieval.button_label') |
|
17 | = submit_tag(t 'registration.password_retrieval.button_label') |
|
17 |
|
18 |
@@ -25,12 +25,12 | |||||
|
25 | %tr |
|
25 | %tr |
|
26 | %td{:align => "right"} |
|
26 | %td{:align => "right"} |
|
27 | = "#{t 'email_label'}:" |
|
27 | = "#{t 'email_label'}:" |
|
28 |
- %td= f. |
|
28 | + %td= f.email_field :email |
|
29 | %tr |
|
29 | %tr |
|
30 | %td |
|
30 | %td |
|
31 | %td |
|
31 | %td |
|
32 | %small |
|
32 | %small |
|
33 |
- =t |
|
33 | + =t('registration.email_guide').html_safe |
|
34 | %tr |
|
34 | %tr |
|
35 | %td/ |
|
35 | %td/ |
|
36 | %td |
|
36 | %td |
@@ -34,4 +34,7 | |||||
|
34 |
|
34 | ||
|
35 | # Expands the lines which load the assets |
|
35 | # Expands the lines which load the assets |
|
36 | config.assets.debug = true |
|
36 | config.assets.debug = true |
|
|
37 | + | ||
|
|
38 | + # Prevents assets from rendering twice | ||
|
|
39 | + config.serve_static_assets = false | ||
|
37 | end |
|
40 | end |
@@ -9,8 +9,8 | |||||
|
9 | email_label: 'E-mail' |
|
9 | email_label: 'E-mail' |
|
10 | password_label: 'Password' |
|
10 | password_label: 'Password' |
|
11 |
|
11 | ||
|
12 | - go_ahead_to: "Go ahead to" |
|
12 | + go_ahead_to: "Go ahead to " |
|
13 | - go_back_to: "Go back to" |
|
13 | + go_back_to: "Go back to " |
|
14 | login_page: "login page" |
|
14 | login_page: "login page" |
|
15 | home_page: "home page" |
|
15 | home_page: "home page" |
|
16 |
|
16 |
You need to be logged in to leave comments.
Login now