Skip to content
Snippets Groups Projects
Unverified Commit 4929ae1c authored by Arnaud Levy's avatar Arnaud Levy Committed by GitHub
Browse files

Reprise des enfants et parents dans le static des catégories d'actualités (#2291)

* Fix

* better
parent d43d7253
No related branches found
Tags v3.0.0
No related merge requests found
......@@ -23,6 +23,7 @@ module AsLocalizedTree
end
def parent
return if about.parent.nil?
about.parent.localization_for(language)
end
......
......@@ -12,6 +12,21 @@ category = @l10n.about
full_width: true,
toc_offcanvas: true %>
position: <%= category.position %>
<%
if @l10n.parent
hugo = @l10n.parent.hugo(@website)
%>
parent: "<%= hugo.path %>"
<% end %>
<% if @l10n.children.any? %>
children:
<%
@l10n.children.ordered.each do |child|
hugo = child.hugo(@website)
%>
- <%= hugo.path %>
<% end %>
<% end %>
<%= render 'admin/application/l10n/static', about: @l10n %>
<%= render 'admin/application/featured_image/static', about: @l10n %>
<%= render 'admin/application/meta_description/static', about: @l10n %>
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment