software-project / scrum-pm

Scrum PM is a plugin for Redmine ticket management system. It adds Scrum items like backlog, dashboard and others.
www.software-project.eu/EN/scrumpm
126 stars 47 forks source link

error showing dashboard using redmine 0.9.3-stable e Postgresql 8.3 #11

Closed cfiorini closed 14 years ago

cfiorini commented 14 years ago

Hi, after installing your plugin i got an sql error on postgresql 8.3. I posted a patch too because in postgresql || is used for string concatenation. I don't know if works in mysql! bye claudio

diff --git a/app/controllers/sprints_controller.rb b/app/controllers/sprints_controller.rb
index 3f4eb7f..4aebe8e 100755
--- a/app/controllers/sprints_controller.rb
+++ b/app/controllers/sprints_controller.rb
@@ -28,7 +28,7 @@ class SprintsController < ApplicationController
   def show
     unless @sprint.nil?
       @unassigned_tasks = Issue.find(:all,
-             :conditions => ["user_story_id IS NULL AND (fixed_version_id = ? || project_id = ?)", @sprint.id, @project.id ])
+             :conditions => ["user_story_id IS NULL AND (fixed_version_id = ? OR project_id = ?)", @sprint.id, @project.id ])
       @issue_statuses = IssueStatus.find(:all)
       @project_users = User.find(:all, :joins => :members, :conditions => ["members.project_id = ?", @project.id])
software-project commented 14 years ago

Thank you I have pushed commit with credits to you. Take care.