Commit 593b05ea945f63fde39689eb62cf890d417b39bc

Authored by Dmitriy Zaporozhets
1 parent 1a20976a

Look for project description during search

Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
Showing 1 changed file with 1 additions and 1 deletions   Show diff stats
app/models/project.rb
@@ -122,7 +122,7 @@ class Project &lt; ActiveRecord::Base @@ -122,7 +122,7 @@ class Project &lt; ActiveRecord::Base
122 end 122 end
123 123
124 def search query 124 def search query
125 - joins(:namespace).where("projects.name LIKE :query OR projects.path LIKE :query OR namespaces.name LIKE :query", query: "%#{query}%") 125 + joins(:namespace).where("projects.name LIKE :query OR projects.path LIKE :query OR namespaces.name LIKE :query OR projects.description LIKE :query", query: "%#{query}%")
126 end 126 end
127 127
128 def find_with_namespace(id) 128 def find_with_namespace(id)