changeset 997:c1b8a34d3560 cannam

Merge
author Chris Cannam <chris.cannam@soundsoftware.ac.uk>
date Fri, 09 Nov 2012 13:58:49 +0000
parents 6982f326cb06 (current diff) c43450d54787 (diff)
children a2660a5eb395 c2b09e16f9fa
files
diffstat 2 files changed, 9 insertions(+), 13 deletions(-) [+]
line wrap: on
line diff
--- a/app/helpers/projects_helper.rb	Fri Nov 09 11:29:47 2012 +0000
+++ b/app/helpers/projects_helper.rb	Fri Nov 09 13:58:49 2012 +0000
@@ -162,14 +162,12 @@
     
   end
 
-  # Renders a tree of projects that the current user does not belong
-  # to, or of all projects if the current user is not logged in.  The
-  # given collection may be a subset of the whole project tree
-  # (eg. some intermediate nodes are private and can not be seen).  We
-  # are potentially interested in various things: the project name,
-  # description, manager(s), creation date, last activity date,
-  # general activity level, whether there is anything actually hosted
-  # here for the project, etc.
+  # Renders a tree of projects.  The given collection may be a subset
+  # of the whole project tree (eg. some intermediate nodes are private
+  # and can not be seen).  We are potentially interested in various
+  # things: the project name, description, manager(s), creation date,
+  # last activity date, general activity level, whether there is
+  # anything actually hosted here for the project, etc.
   def render_project_table(projects)
 
     s = ""
--- a/vendor/plugins/redmine_tags/lib/redmine_tags/patches/projects_controller_patch.rb	Fri Nov 09 11:29:47 2012 +0000
+++ b/vendor/plugins/redmine_tags/lib/redmine_tags/patches/projects_controller_patch.rb	Fri Nov 09 13:58:49 2012 +0000
@@ -1,3 +1,4 @@
+# -*- coding: utf-8 -*-
 require_dependency 'projects_controller'
 
 module RedmineTags
@@ -127,13 +128,10 @@
           end
   
           unless @tag_list.empty?
-            @tagged_projects_ids = Project.visible.tagged_with(@tag_list).collect{ |project| Project.find(project.id) }
+            @tagged_projects_ids = Project.visible.tagged_with(@tag_list).collect{ |project| Project.find(project.id).root }
             @projects = @projects & @tagged_projects_ids
+            @projects = @projects.uniq
           end
-          
-          @projects = @projects.collect{ |project| project.root }
-          @projects = @projects.uniq
-                    
         end
       end
     end