From: Dan Wells Date: Thu, 29 Mar 2012 21:07:23 +0000 (-0400) Subject: Only load "new" serials display if we have data X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=0f3291546b37cd3722e3b64e78203c95282fc369;p=contrib%2FConifer.git Only load "new" serials display if we have data If we try to load the "new" serials display template, but have no data (for instance, if "Use fully compressed serial holdings" is false), we get a server error. Rather than wrap the whole template in an 'if', let's just not load it. Signed-off-by: Dan Wells Signed-off-by: Mike Rylander --- diff --git a/Open-ILS/src/templates/opac/parts/record/issues.tt2 b/Open-ILS/src/templates/opac/parts/record/issues.tt2 index 585cee6a04..998e2d64d9 100644 --- a/Open-ILS/src/templates/opac/parts/record/issues.tt2 +++ b/Open-ILS/src/templates/opac/parts/record/issues.tt2 @@ -1,4 +1,8 @@
- [% INCLUDE 'opac/parts/record/issues-db.tt2' # "new" serials holdings %] + [% + IF ctx.holding_summary_tree; + INCLUDE 'opac/parts/record/issues-db.tt2'; # "new" serials holdings + END; + %] [% INCLUDE 'opac/parts/record/issues-mfhd.tt2' # mfhd-based "classic" serials %]