Pull call number from XML holdings, not MARC record
authorDan Scott <dan@coffeecode.net>
Mon, 2 May 2011 02:06:50 +0000 (22:06 -0400)
committerBill Erickson <berick@esilibrary.com>
Wed, 20 Jul 2011 18:37:32 +0000 (14:37 -0400)
KCLS uses call numbers in the MARC record, but most other sites
use the call numbers from asset.call_number. For now, just display
the first returned call number; eventually the display will probably
need to be adjusted to handle call number / shelving location / library
/ status like the current AjaxPAC does.

Also note that ##URI## call numbers should be filtered out but are
not yet.

Signed-off-by: Dan Scott <dan@coffeecode.net>
Open-ILS/web/templates/default/opac/parts/misc_util.tt2
Open-ILS/web/templates/default/opac/parts/result/table.tt2

index 3e6b175..0e7cd2c 100644 (file)
         # clean up the ISBN
         args.isbn_clean = args.isbn.replace('\ .*', '');
 
-        args.holdsing = [];
+        args.holdings = [];
         FOR holding IN xml.findnodes('//*[local-name()="volumes"]/*[local-name()="volume"]');
-            args.holdings.push({
-                # TODO
-            });
+            args.holdings.push(
+                holding.getAttribute('label')
+            );
         END;
 
         # Extract the copy count summary
index 5445489..3fd5497 100644 (file)
                                                             <td colspan='2'>
                                                                 <strong>[% l('Call number:') %]</strong>[% args.marc_cn %][%# XXX KCLS %]
                                                             </td>
+                                                            <td>[% args.holdings.0 %]</td>
                                                         </tr>
                                                         <tr name="results_pub_tr" class="[% attrs.publisher ? '' : 'hide_me' %]">
                                                             <td valign="top">
                                                 <img title="[% attrs.format_label %]" alt="[% attrs.format_label %]" src="[% attrs.format_icon %]" />
                                                 [% END %]
 
+<<<<<<< HEAD
                                                 <!-- unAPI link -->
                                                 <abbr class="unapi-id" title='tag:[% ctx.hostname %],[% date.format(date.now, '%Y') %]:biblio-record_entry/[% rec.id %]'></abbr>
+=======
+                                                <span class="hide_me">
+                                                    <abbr class="unapi-id">&nbsp;</abbr>
+                                                </span>
+>>>>>>> 1184851... Pull call number from XML holdings, not MARC record
 
                                                 <!-- Empty span used for creating Google Book Search-->
                                                 <span name="googleBooksLink" class="hide_me">