add link for tag subscription edit

This commit is contained in:
albert
2013-02-17 15:23:48 -05:00
parent 4b6a9136b9
commit 06fd8f9c52
2 changed files with 5 additions and 3 deletions

View File

@@ -25,7 +25,7 @@ div#page {
} }
aside#sidebar { aside#sidebar {
width: 15%; width: 15em;
float: left; float: left;
h1 { h1 {

View File

@@ -115,9 +115,11 @@ class UserPresenter
def subscriptions(template) def subscriptions(template)
if user.subscriptions.any? if user.subscriptions.any?
user.subscriptions.map do |subscription| str = user.subscriptions.map do |subscription|
template.link_to(subscription.name, template.posts_path(:tags => "sub:#{user.name}:#{subscription.name}")) template.link_to(subscription.name, template.posts_path(:tags => "sub:#{user.name}:#{subscription.name}"))
end.join(", ").html_safe end.join(", ")
s += " [" + template.link_to("edit", template.tag_subscriptions_path) + "]"
str.html_safe
else else
"None" "None"
end end