mirror of
https://github.com/indentlabs/notebook.git
synced 2025-10-26 11:19:22 +00:00
Show all included content types on universe#show, not just core types
This commit is contained in:
parent
0019e894db
commit
7d1d3f176d
@ -115,15 +115,13 @@
|
||||
|
||||
<%# TODO: not this %>
|
||||
<% if @content.is_a? Universe %>
|
||||
<div class="col s12 m12 l4">
|
||||
<%= render partial: 'content/cards/in_universe_content_list', locals: { content_type: :character, content_list: @content.characters } %>
|
||||
</div>
|
||||
<% content_to_show = [Character, Location, Item, Creature, Race, Religion, Group, Magic, Language, Scene] %>
|
||||
|
||||
<div class="col s12 m12 l4">
|
||||
<%= render partial: 'content/cards/in_universe_content_list', locals: { content_type: :location, content_list: @content.locations } %>
|
||||
</div>
|
||||
<% content_to_show.each do |content_type| %>
|
||||
<% next if @content.send(content_type.name.downcase.pluralize).empty? %>
|
||||
|
||||
<div class="col s12 m12 l4">
|
||||
<%= render partial: 'content/cards/in_universe_content_list', locals: { content_type: :item, content_list: @content.items } %>
|
||||
</div>
|
||||
<div class="col s12 m12 l4">
|
||||
<%= render partial: 'content/cards/in_universe_content_list', locals: { content_type: content_type.name.downcase.to_sym, content_list: @content.send(content_type.name.downcase.pluralize) } %>
|
||||
</div>
|
||||
<% end %>
|
||||
<% end %>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user