Project

General

Profile

Defect #28343

Updated by Go MAEDA over 6 years ago

When i want to save a custom query, the sort_criteria saved in database is wrong. 
 And i have this error : 

 <pre> 
 ActionView::Template::Error (undefined method `+' for nil:NilClass): 
     1: <%= hidden_field_tag 'set_filter', '1' %> 
     2: <%= hidden_field_tag 'type', @query.type, :disabled => true, :id => 'query_type' %> 
     3: <%= query_hidden_sort_tag(@query) %> 
     4: 
     5: <div id="query_form_with_buttons" class="hide-when-print"> 
     6: <div id="query_form_content"> 
   lib/redmine/sort_criteria.rb:35:in `block in to_param' 
   lib/redmine/sort_criteria.rb:35:in `collect' 
   lib/redmine/sort_criteria.rb:35:in `to_param' 
   app/helpers/queries_helper.rb:372:in `query_hidden_sort_tag' 
   app/views/queries/_query_form.html.erb:3:in `_3dab2d6c79ffe592a7e685bf7851a687' 
   app/views/issues/index.html.erb:11:in `block in _f2c5feeaee6cbb1d8e600dad9df23bd6' 
   app/views/issues/index.html.erb:10:in `_f2c5feeaee6cbb1d8e600dad9df23bd6' 
   app/controllers/issues_controller.rb:51:in `block (2 levels) in index' 
   app/controllers/issues_controller.rb:46:in `index' 
   lib/redmine/sudo_mode.rb:63:in `sudo_mode' 
 </pre> 

 The value used to be : @--- []@ --- [] 
 but i have : 
 <pre> 
 --- 
 - -  
   - asc 
 - -  
   - asc 
 - -  
   - asc 
 </pre> 

 Or if i select just one sort item : 
 <pre> 
 --- 
 - - id 
   - desc 
 - -  
   - asc 
 - -  
   - asc 
 </pre>

Back