Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
G
gitlab-ce
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Jérome Perrin
gitlab-ce
Commits
06276bd3
Commit
06276bd3
authored
Apr 21, 2016
by
Phil Hughes
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Correctly shows no results text
Correct search results count
parent
3137559d
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
2 deletions
+2
-2
app/helpers/search_helper.rb
app/helpers/search_helper.rb
+1
-1
app/views/search/_results.html.haml
app/views/search/_results.html.haml
+1
-1
No files found.
app/helpers/search_helper.rb
View file @
06276bd3
...
@@ -23,7 +23,7 @@ module SearchHelper
...
@@ -23,7 +23,7 @@ module SearchHelper
if
collection
.
count
>
0
if
collection
.
count
>
0
from
=
collection
.
offset_value
+
1
from
=
collection
.
offset_value
+
1
to
=
collection
.
offset_value
+
collection
.
length
to
=
collection
.
offset_value
+
collection
.
length
count
=
collection
.
count
count
=
collection
.
total_
count
"Showing
#{
from
}
-
#{
to
}
of
#{
count
}
#{
scope
.
humanize
(
capitalize:
false
)
}
for
\"
#{
term
}
\"
"
"Showing
#{
from
}
-
#{
to
}
of
#{
count
}
#{
scope
.
humanize
(
capitalize:
false
)
}
for
\"
#{
term
}
\"
"
end
end
...
...
app/views/search/_results.html.haml
View file @
06276bd3
-
if
@
search_resul
ts
.
empty?
-
if
@
objec
ts
.
empty?
=
render
partial:
"search/results/empty"
=
render
partial:
"search/results/empty"
-
else
-
else
.gray-content-block
.gray-content-block
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment