@@ -184,30 +184,30 @@ def ranged_rfc_data(interval = 'year', from = DateTime.new(0), to = DateTime.now
184184 name : RequestForComment . model_name . human ( count : :other ) ,
185185 data : RequestForComment . in_range ( from , to )
186186 . select ( RequestForComment . sanitize_sql ( [ 'date_trunc(?, created_at) AS "key", count(id) AS "value"' , interval ] ) )
187- . group ( ' key' ) . order ( ' key' ) ,
187+ . group ( : key) . order ( : key) ,
188188 } ,
189189 {
190190 key : 'rfcs_solved' ,
191191 name : t ( 'statistics.entries.request_for_comments.percent_solved' ) ,
192192 data : RequestForComment . in_range ( from , to )
193193 . where ( solved : true )
194194 . select ( RequestForComment . sanitize_sql ( [ 'date_trunc(?, created_at) AS "key", count(id) AS "value"' , interval ] ) )
195- . group ( ' key' ) . order ( ' key' ) ,
195+ . group ( : key) . order ( : key) ,
196196 } ,
197197 {
198198 key : 'rfcs_soft_solved' ,
199199 name : t ( 'statistics.entries.request_for_comments.percent_soft_solved' ) ,
200200 data : RequestForComment . in_range ( from , to ) . unsolved
201201 . where ( full_score_reached : true )
202202 . select ( RequestForComment . sanitize_sql ( [ 'date_trunc(?, created_at) AS "key", count(id) AS "value"' , interval ] ) )
203- . group ( ' key' ) . order ( ' key' ) ,
203+ . group ( : key) . order ( : key) ,
204204 } ,
205205 {
206206 key : 'rfcs_unsolved' ,
207207 name : t ( 'statistics.entries.request_for_comments.percent_unsolved' ) ,
208208 data : RequestForComment . in_range ( from , to ) . unsolved
209209 . select ( RequestForComment . sanitize_sql ( [ 'date_trunc(?, created_at) AS "key", count(id) AS "value"' , interval ] ) )
210- . group ( ' key' ) . order ( ' key' ) ,
210+ . group ( : key) . order ( : key) ,
211211 } ,
212212 ]
213213 end
@@ -219,14 +219,14 @@ def ranged_user_data(interval = 'year', from = DateTime.new(0), to = DateTime.no
219219 name : t ( 'statistics.entries.contributors.active' ) ,
220220 data : Submission . where ( created_at : from ..to )
221221 . select ( Submission . sanitize_sql ( [ 'date_trunc(?, created_at) AS "key", count(distinct CONCAT(contributor_type, contributor_id)) AS "value"' , interval ] ) )
222- . group ( ' key' ) . order ( ' key' ) ,
222+ . group ( : key) . order ( : key) ,
223223 } ,
224224 {
225225 key : 'submissions' ,
226226 name : t ( 'statistics.entries.exercises.submissions' ) ,
227227 data : Submission . where ( created_at : from ..to )
228228 . select ( Submission . sanitize_sql ( [ 'date_trunc(?, created_at) AS "key", count(id) AS "value"' , interval ] ) )
229- . group ( ' key' ) . order ( ' key' ) ,
229+ . group ( : key) . order ( : key) ,
230230 axis : 'right' ,
231231 } ,
232232 ]
0 commit comments