move tag path to the appropriate helper
This commit is contained in:
parent
ac9afe0d14
commit
060a2e2257
3 changed files with 7 additions and 2 deletions
5
app/helpers/tags_helper.rb
Normal file
5
app/helpers/tags_helper.rb
Normal file
|
@ -0,0 +1,5 @@
|
|||
module TagsHelper
|
||||
def tag_path tag
|
||||
"/tags/#{tag}"
|
||||
end
|
||||
end
|
|
@ -14,7 +14,7 @@
|
|||
= project.name
|
||||
.small-tags
|
||||
- project.tag_list.each do |tag|
|
||||
= link_to tag, "/tags/#{tag}"
|
||||
= link_to tag, tag_path(tag)
|
||||
|
||||
%td= truncate project.url_to_repo
|
||||
%td= project.code
|
||||
|
|
|
@ -7,5 +7,5 @@
|
|||
|
||||
.tags-list
|
||||
- @tags.all.each do |tag|
|
||||
= link_to "#{tag.name}(#{tag.count})", "/tags/#{tag.name}"
|
||||
= link_to "#{tag.name}(#{tag.count})", tag_path(name)
|
||||
|
||||
|
|
Loading…
Reference in a new issue