fix themas listings
This commit is contained in:
parent
76db2afbbc
commit
aa724bdea5
3 changed files with 10 additions and 4 deletions
4
Rules
4
Rules
|
@ -6,8 +6,7 @@ preprocess do
|
||||||
themas.each do |thema|
|
themas.each do |thema|
|
||||||
content = ''
|
content = ''
|
||||||
attributes = {
|
attributes = {
|
||||||
naam: thema,
|
naam: thema
|
||||||
verenigingen: @items.filter{|i| i[:themas] and i[:themas].include?(thema)}.flatten.uniq.compact
|
|
||||||
}
|
}
|
||||||
identifier = "/themas/#{thema}"
|
identifier = "/themas/#{thema}"
|
||||||
|
|
||||||
|
@ -42,6 +41,7 @@ end
|
||||||
compile '/themas/*' do
|
compile '/themas/*' do
|
||||||
layout '/thema.*'
|
layout '/thema.*'
|
||||||
layout '/default.*'
|
layout '/default.*'
|
||||||
|
layout '/base.*'
|
||||||
write ext: 'html'
|
write ext: 'html'
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -3,5 +3,7 @@
|
||||||
<div class="details-container details-text">
|
<div class="details-container details-text">
|
||||||
<%= yield %>
|
<%= yield %>
|
||||||
</div>
|
</div>
|
||||||
<%= render '/partials/detail.*' %>
|
<% verenigingen_voor_thema(item[:naam]).each do |ver| %>
|
||||||
|
<%= render '/partials/pretty_link.*', :item => ver %>
|
||||||
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
|
|
|
@ -16,6 +16,10 @@ module VerenigingenHelper
|
||||||
@items.find_all("**/themas/*")
|
@items.find_all("**/themas/*")
|
||||||
end
|
end
|
||||||
|
|
||||||
|
def verenigingen_voor_thema(thema)
|
||||||
|
@items.filter{|i| i[:themas] and i[:themas].include?(thema)}.to_a
|
||||||
|
end
|
||||||
|
|
||||||
def konventen
|
def konventen
|
||||||
@items.find_all("**/konventen/*").to_a
|
@items.find_all("**/konventen/*").to_a
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue