Skip to content

Commit

Permalink
- Fix issue with 'category and subtype or type' partial (EU material)…
Browse files Browse the repository at this point in the history
… that caused multiple 'type' headings to appear
  • Loading branch information
j-corry committed Nov 25, 2024
1 parent 0719b9d commit 2820c95
Showing 1 changed file with 9 additions and 18 deletions.
Original file line number Diff line number Diff line change
@@ -1,29 +1,20 @@
- unless category.blank?
%div.item-details
- if category.is_a?(Array)
%div.item-details
%div.item-details-label= "Type"
= render 'search/fragments/simple_list', items: category, separator: ';', terminator: ';', singular: false
%div.item-details-label= "Type"
%span>= render 'search/fragments/simple_list', items: category, separator: ';', terminator: ';', singular: false
- else
%div.item-details
%div.item-details-label= "Type"
= object_display_name(category, singular: true)
%div.item-details-label= "Type"
%span>= object_display_name(category, singular: true)
- unless subtype.blank?
- unless category.blank?
%span>= "; "
- if subtype.is_a?(Array)
%div.item-details
%div.item-details-label= "Type"
= render 'search/fragments/simple_list', items: subtype, separator: ';', terminator: ';', singular: false
= render 'search/fragments/simple_list', items: subtype, separator: ';', terminator: ';', singular: false
- else
%div.item-details
%div.item-details-label= "Type"
= object_display_name(subtype, singular: true)
= object_display_name(subtype, singular: true)
- if subtype.blank? && category.blank?
- if type.is_a?(Array)
%div.item-details
%div.item-details-label= "Type"
= render 'search/fragments/simple_list', items: type, separator: ';', terminator: ';', singular: false
= render 'search/fragments/simple_list', items: type, separator: ';', terminator: ';', singular: false
- else
%div.item-details
%div.item-details-label= "Type"
= object_display_name(type, singular: true)
= object_display_name(type, singular: true)

0 comments on commit 2820c95

Please sign in to comment.