From 04d57bca29380bfd648d38c28f5071f64118d293 Mon Sep 17 00:00:00 2001
From: Jason Stephenson <jstephenson@mvlc.org>
Date: Mon, 21 Nov 2011 13:47:30 -0500
Subject: [PATCH] Limit display to 856 with ind1 = 4 and ind2 = 0 or 1.

Minor modification to Open-ILS/src/templates/opac/parts/
misc_util.tt2 that limits the display of 856 urls to that have
indicator 1 equal to 4 and indicator 2 equal to 0 or 1. These should
be those that point directly to the resource.

Signed-off-by: Jason Stephenson <jstephenson@mvlc.org>
Signed-off-by: Dan Scott <dscott@laurentian.ca>
---
 Open-ILS/src/templates/opac/parts/misc_util.tt2 | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Open-ILS/src/templates/opac/parts/misc_util.tt2 b/Open-ILS/src/templates/opac/parts/misc_util.tt2
index 1657bd6893..db30d6b3d7 100644
--- a/Open-ILS/src/templates/opac/parts/misc_util.tt2
+++ b/Open-ILS/src/templates/opac/parts/misc_util.tt2
@@ -39,7 +39,7 @@
 
         # Extract the 856 URLs that are not otherwise represented by asset.uri's
         args.online_res = [];
-        FOR node IN xml.findnodes('//*[@tag="856"]');
+        FOR node IN xml.findnodes('//*[@tag="856" and @ind1="4" and (@ind2="0" or @ind2="1")]');
             IF node.findnodes('./*[@code="9" or @code="w" or @code="n"]'); NEXT; END; # asset.uri's
             label = node.findnodes('./*[@code="y"]');
             notes = node.findnodes('./*[@code="z" or @code="3"]');
-- 
2.11.0