Actions
Defect #24746
closedTemplate::Error after project and issue rebuild
Status:
Closed
Priority:
Normal
Assignee:
-
Category:
Issues
Target version:
-
Start date:
Due date:
% Done:
0%
Estimated time:
Resolution:
Invalid
Affected version:
Description
Hello,
i had a issue with projects tree. i found a 'solution' in this forum to rebuild the tree:
ruby bin/rails runner 'Project.rebuild_tree!' RAILS_ENV=production ruby bin/rails runner 'Issue.rebuild_tree!' RAILS_ENV=production
now projects tree a re fine, but when i would like to enter in the project-issue page, i have an error:
Started GET "/projects/xxx/issues" for xx.xx.xx.xx at 2017-01-03 18:11:11 +0100 Processing by IssuesController#index as HTML Parameters: {"project_id"=>"xxx"} Current user: xx(id=xx) Rendered queries/_filters.html.erb (24.9ms) Rendered issues/index.html.erb within layouts/base (26.5ms) Completed 500 Internal Server Error in 128ms (ActiveRecord: 44.7ms) ActionView::Template::Error (comparison of NilClass with 218 failed): 3: var operatorByType = <%= raw_json Query.operators_by_filter_type %>; 4: var availableFilters = <%= raw_json query.available_filters_as_json %>; 5: var labelDayPlural = <%= raw_json l(:label_day_plural) %>; 6: var allProjects = <%= raw_json query.all_projects_values %>; 7: $(document).ready(function(){ 8: initFilters(); 9: <% query.filters.each do |field, options| %> app/models/project.rb:784:in `sort_by' app/models/project.rb:784:in `project_tree' app/models/query.rb:336:in `all_projects_values' app/views/queries/_filters.html.erb:6:in `block in _app_views_queries__filters_html_erb__928470405_121460600' app/views/queries/_filters.html.erb:1:in `_app_views_queries__filters_html_erb__928470405_121460600' app/views/issues/index.html.erb:19:in `block in _app_views_issues_index_html_erb__380465873_120187980' app/views/issues/index.html.erb:11:in `_app_views_issues_index_html_erb__380465873_120187980' app/controllers/issues_controller.rb:77:in `block (2 levels) in index' app/controllers/issues_controller.rb:76:in `index' lib/redmine/sudo_mode.rb:63:in `sudo_mode'
i note the the number 218 is always the same even if i change project.
can someone help me please.
Environment: Redmine version 3.2.0.stable Ruby version 1.9.3-p194 (2012-04-20) [i486-linux] Rails version 4.2.5 Environment production Database adapter Mysql2
thanks.
Updated by Toshi MARUYAMA almost 8 years ago
- Status changed from New to Needs feedback
- Priority changed from Urgent to Normal
Updated by del med almost 8 years ago
Thanks Toshi for this reply.
i'm upgrading my ruby version to 2.2.6 the i will upgrade redmine for 3.2.4.
but for now, i didn't find any Project or issue with lft, rgt or root_id null !
Updated by del med almost 8 years ago
the probleme come from project table.
i set lft and rgt to 0, then i create a new sub-project of project id = 1.
normally redmine should recalculate and update all lft and rgt value, but it's not the case. il have always values equal to 0 and the new project 1/2 .
i tried to update all projects to 1/2 and create a new sub-project of project id =1.
i have lft and rgt equal:
i set lft and rgt to 0, then i create a new sub-project of project id = 1.
normally redmine should recalculate and update all lft and rgt value, but it's not the case. il have always values equal to 0 and the new project 1/2 .
i tried to update all projects to 1/2 and create a new sub-project of project id =1.
i have lft and rgt equal:
- first SP: 3/4
- second SP: 4/5
- Parent: 1/2
- next project : 1/2
- first SP: 2/3
- second SP: 4/5
- Parent: 1/6
- next project : 7/8
there's a way to recalculate this please ? even by sql query !
Updated by del med almost 8 years ago
For plug-ins I have creditors and http://redminecrm.com/ with light version.
Updated by Toshi MARUYAMA almost 8 years ago
- Status changed from Needs feedback to Closed
- Resolution set to Invalid
Actions