{/if}
{include file="frontend/objects/monograph_summary.tpl" monograph=$monograph}
- {if $smarty.foreach.monographListLoop.iteration is even by 1}
+ {if $counter is even by 1}
{/if}
+ {assign var=counter value=$counter+1}
{/foreach}
{* Close .row if we have an odd number of titles *}
- {if count($monographs) > 0 && $smarty.foreach.monographListLoop.iteration is odd by 1}
+ {if $counter > 1 && $counter is even by 1}
{/if}
diff --git a/templates/frontend/objects/monograph_summary.tpl b/templates/frontend/objects/monograph_summary.tpl
index 5baf5de927c..7d65f00f943 100644
--- a/templates/frontend/objects/monograph_summary.tpl
+++ b/templates/frontend/objects/monograph_summary.tpl
@@ -8,11 +8,17 @@
* @brief Display a summary view of a monograph for display in lists
*
* @uses $monograph Monograph The monograph to be displayed
+ * @uses $isFeatured bool Is this a featured monograph?
*}
-
diff --git a/templates/frontend/pages/catalogCategory.tpl b/templates/frontend/pages/catalogCategory.tpl
index 542eacdb48c..f2f4e8b0a5e 100644
--- a/templates/frontend/pages/catalogCategory.tpl
+++ b/templates/frontend/pages/catalogCategory.tpl
@@ -13,6 +13,8 @@
* @uses $newReleasesMonographs array List of new monographs in this category
* @uses $parentCategory Category Parent category if one exists
* @uses $subcategories array List of subcategories if they exist
+ * @uses $alreadyShown array Array of monograph IDs which have already been
+ * displayed. These IDs are excluded from later sections.
*}
{include file="common/frontend/header.tpl" pageTitleTranslated=$category->getLocalizedTitle()}
@@ -54,54 +56,25 @@
{/iterate}
-
{/if}
{* No published titles in this category *}
{if empty($publishedMonographs)}
+
+ {translate key="catalog.allBooks"}
+
{translate key="catalog.noTitlesSection"}
{else}
- {* Featured monographs *}
- {if !empty($featuredMonographIds)}
-
- {translate key="catalog.featuredBooks"}
-
-
- {assign var="counter" value=1}
- {foreach from=$featuredMonographIds item=featuredMonographId}
- {if array_key_exists($featuredMonographId, $publishedMonographs)}
- {if $counter is odd by 1}
-
- {/if}
- {include file="frontend/objects/monograph_summary.tpl" monograph=$publishedMonographs[$featuredMonographId]}
- {if $counter is even by 1}
-
- {/if}
- {assign var=counter value=$counter+1}
- {/if}
- {/foreach}
- {* Close .row if we have an odd number of titles *}
- {if $counter > 1 && $counter is even by 1}
-
- {assign var="counter" value=1}
- {foreach from=$featuredMonographIds item=featuredMonographId}
- {if array_key_exists($featuredMonographId, $publishedMonographs)}
- {if $counter is odd by 1}
-
- {/if}
- {include file="frontend/objects/monograph_summary.tpl" monograph=$publishedMonographs[$featuredMonographId]}
- {if $counter is even by 1}
-
- {/if}
- {assign var=counter value=$counter+1}
- {/if}
- {/foreach}
- {* Close .row if we have an odd number of titles *}
- {if $counter > 1 && $counter is even by 1}
-