Archived breadcrumbs fix [SCI-8488] [SCI-8404]

This commit is contained in:
Giga Chubinidze 2023-05-22 14:09:14 +04:00
parent 2f372fd871
commit be7dc74105

View file

@ -1,5 +1,6 @@
<% if @breadcrumbs_items&.length %>
<% @breadcrumbs_items.each { |item| item[:label] = "(A) #{item[:label]}" if item[:archived] }%>
<% archived_exists = @breadcrumbs_items.any? { |item| item[:archived] } %>
<% @breadcrumbs_items.each { |item| item[:label] = "(A) #{item[:label]}" if archived_exists } %>
<% shortened = @breadcrumbs_items.length > 4 %>
<% if shortened %>