Changes for site map front end indentation
This commit is contained in:
parent
fcbba6660b
commit
83fb5230a4
|
@ -1,16 +1,20 @@
|
||||||
<div class="site-map">
|
<div class="site-map">
|
||||||
<% @items.each_with_index do |item, i| %>
|
<% i = 1 %>
|
||||||
|
<% @items.each do |item| %>
|
||||||
<% if item.show_in_sitemap_for(I18n.locale.to_s) %>
|
<% if item.show_in_sitemap_for(I18n.locale.to_s) %>
|
||||||
<div class="map-block">
|
<div class="map-block">
|
||||||
<h4><%= i+1 %> <a href='<%= item.path %>'><%= item.title %></a></h4>
|
<h4><%= i %> <a href='<%= item.path %>'><%= item.title %></a></h4>
|
||||||
<ul>
|
<ul>
|
||||||
<% item.children.each_with_index do |child, ii| %>
|
<% ii = 1 %>
|
||||||
|
<% item.children.each do |child| %>
|
||||||
<% if child.show_in_sitemap_for(I18n.locale.to_s) %>
|
<% if child.show_in_sitemap_for(I18n.locale.to_s) %>
|
||||||
<li class="clear"><%= "#{i+1}-#{ii+1}" %> <a href='<%= child.path %>'><%= child.title %></a></span></li>
|
<li class="clear"><%= "#{i}-#{ii}" %> <a href='<%= child.path %>'><%= child.title %></a></span></li>
|
||||||
|
<% ii += 1 %>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% end if item.children %>
|
<% end if item.children %>
|
||||||
</ul>
|
</ul>
|
||||||
</div>
|
</div>
|
||||||
|
<% i += 1 %>
|
||||||
<% end %>
|
<% end %>
|
||||||
<% end %>
|
<% end %>
|
||||||
</div>
|
</div>
|
||||||
|
|
Reference in New Issue