Commit 0ca6ba5abdec27cbe75527208b90674f721763e2
1 parent
e899fcf6
Exists in
master
and in
29 other branches
ActionItem85: make list block generate links
git-svn-id: https://svn.colivre.coop.br/svn/noosfero/trunk@793 3f533792-8f58-4932-b0fe-aaf55b0a4547
Showing
1 changed file
with
16 additions
and
1 deletions
Show diff stats
app/models/list_block.rb
1 | 1 | class ListBlock < Design::Block |
2 | 2 | |
3 | 3 | def content |
4 | - Profile.find(:all).map{|p|p.name} | |
4 | + | |
5 | + lambda do | |
6 | + content_tag( | |
7 | + 'ul', | |
8 | + Profile.find(:all).map do |p| | |
9 | + content_tag( | |
10 | + 'li', | |
11 | + content_tag( | |
12 | + 'span', | |
13 | + link_to( p.name, :profile => p.identifier) | |
14 | + )) | |
15 | + end | |
16 | + ) | |
17 | + end | |
18 | + | |
5 | 19 | end |
20 | + | |
6 | 21 | end | ... | ... |