[open-ils-commits] r599 - conifer/trunk/web/opac/skin/default/xml/rdetail (dbs)
svn at svn.open-ils.org
svn at svn.open-ils.org
Thu Jul 30 13:19:59 EDT 2009
Author: dbs
Date: 2009-07-30 13:19:55 -0400 (Thu, 30 Jul 2009)
New Revision: 599
Modified:
conifer/trunk/web/opac/skin/default/xml/rdetail/rdetail_summary.xml
Log:
Extend the number of elements that are being displayed to be more appropriate for academic institutions.
Hide elements that contain no content.
Display URLs in a way that makes sense for our legacy practice (all link text went into subfield z instead of y),
although it should still be usable by institutions that do things the right way :)
Try to fix unAPI now that Zotero is parsing the post-JS DOM (having two unAPI entries for a single record is not good).
Modified: conifer/trunk/web/opac/skin/default/xml/rdetail/rdetail_summary.xml
===================================================================
--- conifer/trunk/web/opac/skin/default/xml/rdetail/rdetail_summary.xml 2009-07-28 07:43:38 UTC (rev 598)
+++ conifer/trunk/web/opac/skin/default/xml/rdetail/rdetail_summary.xml 2009-07-30 17:19:55 UTC (rev 599)
@@ -1,12 +1,12 @@
-<abbr class="unapi-id" title='tag:<!--#echo var="HTTP_HOST"-->,<!--#echo var="OILS_TIME_YEAR"-->:biblio-record_entry/<!--#echo var="OILS_OPAC_RID"-->'></abbr>
+<abbr name="unapi" class="unapi-id" title='tag:<!--#echo var="HTTP_HOST"-->,<!--#echo var="OILS_TIME_YEAR"-->:biblio-record_entry/<!--#echo var="OILS_OPAC_RID"-->'></abbr>
<!-- This holds the record summary information -->
<div>
<table id='rdetail_details_table'>
<tbody id='rdetail_details_tbody'>
<tr>
- <td id='rdetail_image_cell' rowspan='20'>
+ <td id='rdetail_image_cell' rowspan='30'>
<a id='rdetail_img_link'>
<img style='border: none;' id='rdetail_image'
onerror='
@@ -21,11 +21,18 @@
</div>
</td>
<td nowrap='nowrap' class='rdetail_desc'>&common.title;</td>
- <!-- *** Example of how to use the openils.BibTemplate infrastructure to augment the stock
- *** summary screen with more and/or different information. In this case, the raw MARC 245. -->
- <td type='opac/slot-data' query='datafield[tag=245]' class='rdetail_item' id='rdetail_title'> </td>
+ <td type='opac/slot-data' query='datafield[tag=245]' class='rdetail_item' id='rdetail_title'> </td>
</tr>
+ <tr class='hide_me' id='tag246'>
+ <td nowrap='nowrap' class='rdetail_desc'>Alternate title</td>
+ <td type='opac/slot-data' query='datafield[tag=246] > subfield[code=a]' class='rdetail_item'>
+ <script type='opac/slot-format'><![CDATA[
+ unHideMe($('tag246'));
+ return '<span>' + dojox.data.dom.textContent(item) + '</span><br/>';
+ ]]></script>
+ </td>
+ </tr>
<tr>
<td nowrap='nowrap' class='rdetail_desc'>&common.author;</td>
<td class='rdetail_item'>
@@ -33,24 +40,40 @@
</td>
</tr>
- <tr>
+ <tr class='hide_me' id='tag020'>
<td nowrap='nowrap' class='rdetail_desc'>&common.isbn;</td>
- <td class='rdetail_item' id='rdetail_isbn'> </td>
+ <td type='opac/slot-data' query='datafield[tag=020]' class='rdetail_item' id='rdetail_isbn'>
+ <script type='opac/slot-format'><![CDATA[
+ unHideMe($('tag020'));
+ return '<span>' + dojox.data.dom.textContent(item) + '</span><br/>';
+ ]]></script>
+ </td>
+
</tr>
+ <tr class='hide_me' id='tag022'>
+ <td nowrap='nowrap' class='rdetail_desc'>ISSN</td>
+ <td type='opac/slot-data' query='datafield[tag=022]' class='rdetail_item' id='rdetail_issn'>
+ <script type='opac/slot-format'><![CDATA[
+ unHideMe($('tag022'));
+ return '<span>' + dojox.data.dom.textContent(item) + '</span><br/>';
+ ]]></script>
+ </td>
+ </tr>
+
<tr>
<td nowrap='nowrap' class='rdetail_desc'>&common.edition;</td>
<td class='rdetail_item' id='rdetail_edition'> </td>
</tr>
- <tr>
+ <tr class='hide_me'>
<td nowrap='nowrap' class='rdetail_desc'>&common.pubdate;</td>
<td class='rdetail_item' id='rdetail_pubdate'> </td>
</tr>
<tr>
<td nowrap='nowrap' class='rdetail_desc'>&common.publisher;</td>
- <td type='opac/slot-data' query='datafield[tag=260]' class='rdetail_item' id='rdetail_publisher'> </td>
+ <td type='opac/slot-data' query='datafield[tag=260]' class='rdetail_item' id='rdetail_publisher'> </td>
</tr>
@@ -67,67 +90,142 @@
</td>
</tr>
- <tr>
+ <tr class='hide_me' id='tag520'>
<td nowrap='nowrap' class='rdetail_desc'>&rdetail.detailMain.abstract;</td>
- <td class='rdetail_item' id='rdetail_abstract'> </td>
+ <td type='opac/slot-data' query='datafield[tag=520]' class='rdetail_item' id='rdetail_abstract'>
+ <script type='opac/slot-format'><![CDATA[
+ unHideMe($('tag520'));
+ return '<span>' + dojox.data.dom.textContent(item) + '</span><br/>';
+ ]]></script>
+ </td>
+
</tr>
<!-- *** Example of how to use the openils.BibTemplate infrastructure to augment the stock
*** summary screen with complex information, such as new search links on subjects. -->
- <tr>
- <td nowrap='nowrap' class='rdetail_desc'>Subjects</td>
- <td type='opac/slot-data' query='datafield[tag=650]' class='rdetail_item'>
- <script type='opac/slot-format'><![CDATA[
- var cgi = new CGI();
- var other_params = [ 'd', 'l', 'r', 'av', 's', 'sd' ];
- var total = '';
- var output = [];
- var list = dojo.query( 'subfield', item );
- for (var i =0; i < list.length; i++) {
- total += dojox.data.dom.textContent(list[i]) + ' ';
- var current = '<a href="rresult.xml?rt=subject&t=' + total;
- for (var p in other_params) {
- if (cgi.param(other_params[p]))
- current += '&' + other_params[p] + '=' + cgi.param(other_params[p]);
- }
- current += '">' + dojox.data.dom.textContent(list[i]) + '</a>'
- output.push(current);
- }
- return '<span>' + output.join(' -- ') + '</span><br/>';
- ]]></script>
- </td>
- </tr>
-
- <tr class='hide_me' id='rdetail_online_row'>
- <!-- *** Example of how to use the openils.BibTemplate infrastructure to augment the stock
- *** summary screen with complex information, such as location-specific URIs (856$9). -->
- <td nowrap='nowrap' class='rdetail_desc'>&rdetail.summary.online;
- <span class='hide_me' type='opac/slot-data' query='datafield[tag=856] subfield[code=9]'>
- <script type='opac/slot-format'><![CDATA[
- // There exists at least one localized URI. Clear all links.
- dojo.query('*:not([type^=opac])', 'rdetail_online').orphan();
- return '';
- ]]></script>
- </span>
- </td>
- <td class='rdetail_item' id='rdetail_online' type='opac/slot-data' query='volumes > volume > uris > uri' join=", ">
+ <tr class='hide_me' id='tag650'>
+ <td nowrap='nowrap' class='rdetail_desc'>Subjects</td>
+ <td type='opac/slot-data' query='datafield[tag=650]' class='rdetail_item'>
+ <script type='opac/slot-format'><![CDATA[
+ unHideMe($('tag650'));
+ var cgi = new CGI();
+ var other_params = [ 'd', 'l', 'r', 'av', 's', 'sd' ];
+ var total = '';
+ var output = [];
+ var list = dojo.query( 'subfield', item );
+ for (var i =0; i < list.length; i++) {
+ total += dojox.data.dom.textContent(list[i]) + ' ';
+ var current = '<a href="rresult.xml?rt=subject&t=' + total;
+ for (var p in other_params) {
+ if (cgi.param(other_params[p]))
+ current += '&' + other_params[p] + '=' + cgi.param(other_params[p]);
+ }
+ current += '">' + dojox.data.dom.textContent(list[i]) + '</a>'
+ output.push(current);
+ }
+ return '<span>' + output.join(' -- ') + '</span><br/>';
+ ]]></script>
+ </td>
+ </tr>
+ <tr class='hide_me' id='tag500'>
+ <td nowrap='nowrap' class='rdetail_desc'>General note</td>
+ <td type='opac/slot-data' query='datafield[tag=500]' class='rdetail_item'>
+ <script type='opac/slot-format'><![CDATA[
+ unHideMe($('tag500'));
+ return '<span>' + dojox.data.dom.textContent(item) + '</span><br/>';
+ ]]></script>
+ </td>
+ </tr>
+ <tr class='hide_me' id='tag505'>
+ <td nowrap='nowrap' class='rdetail_desc'>Contents note</td>
+ <td type='opac/slot-data' query='datafield[tag=505]' class='rdetail_item'>
+ <script type='opac/slot-format'><![CDATA[
+ unHideMe($('tag505'));
+ return '<span>' + dojox.data.dom.textContent(item) + '</span><br/>';
+ ]]></script>
+ </td>
+ </tr>
+ <tr class='hide_me' id='tag506'>
+ <td nowrap='nowrap' class='rdetail_desc'>Usage restrictions</td>
+ <td type='opac/slot-data' query='datafield[tag=506] > subfield[code=a]' class='rdetail_item'>
+ <script type='opac/slot-format'><![CDATA[
+ unHideMe($('tag506'));
+ return '<span>' + dojox.data.dom.textContent(item) + '</span> ';
+ ]]></script>
+ </td>
+ </tr>
+ <tr class='hide_me' id='tag511'>
+ <td nowrap='nowrap' class='rdetail_desc'>Performer note</td>
+ <td type='opac/slot-data' query='datafield[tag=511]' class='rdetail_item'>
+ <script type='opac/slot-format'><![CDATA[
+ unHideMe($('tag511'));
+ return '<span>' + dojox.data.dom.textContent(item) + '</span><br/>';
+ ]]></script>
+ </td>
+ </tr>
+ <tr class='hide_me' id='tag700'>
+ <td nowrap='nowrap' class='rdetail_desc'>Additional authors</td>
+ <td type='opac/slot-data' query='datafield[tag=700]' class='rdetail_item'>
+ <script type='opac/slot-format'><![CDATA[
+ unHideMe($('tag700'));
+ return '<span>' + dojox.data.dom.textContent(item) + '</span><br/>';
+ ]]></script>
+ </td>
+ </tr>
+ <tr class='hide_me' id='tag780'>
+ <td nowrap='nowrap' class='rdetail_desc'>Preceding entry</td>
+ <td type='opac/slot-data' query='datafield[tag=780]' class='rdetail_item'>
+ <script type='opac/slot-format'><![CDATA[
+ unHideMe($('tag780'));
+ return '<span>' + dojox.data.dom.textContent(item) + '</span><br/>';
+ ]]></script>
+ </td>
+ </tr>
+ <tr class='hide_me' id='tag785'>
+ <td nowrap='nowrap' class='rdetail_desc'>Succeeding entry</td>
+ <td type='opac/slot-data' query='datafield[tag=785]' class='rdetail_item'>
+ <script type='opac/slot-format'><![CDATA[
+ unHideMe($('tag785'));
+ return '<span>' + dojox.data.dom.textContent(item) + '</span><br/>';
+ ]]></script>
+ </td>
+ </tr>
+ <tr class='hide_me' id='rdetail_online_row'>
+ <!-- *** Example of how to use the openils.BibTemplate infrastructure to augment the stock
+ *** summary screen with complex information, such as location-specific URIs (856$9). -->
+ <td nowrap='nowrap' class='rdetail_desc'>&rdetail.summary.online;
+ <span class='hide_me' type='opac/slot-data' query='datafield[tag=856] subfield[code=9]'>
<script type='opac/slot-format'><![CDATA[
- var link = '<a href="' + item.getAttribute('href') + '" class="classic_link">' + item.getAttribute('label') + '</a>';
- if (item.getAttribute('use_restriction'))
- link += ' (' + item.getAttribute('use_restriction') + ') <br />';
- return link;
+ // There exists at least one localized URI. Clear all links.
+ dojo.query('*:not([type^=opac])', 'rdetail_online').orphan();
+ return '';
]]></script>
- </td>
- </tr>
+ </span>
+ </td>
+ <td class='rdetail_item' id='rdetail_online' type='opac/slot-data' query='volumes > volume > uris > uri'>
+ <script type='opac/slot-format'><![CDATA[
+ var uri = Array();
+ uri.href = item.getAttribute('href');
+ uri.label = item.getAttribute('label');
+ uri.use = item.getAttribute('use_restriction');
+ if (uri.href == uri.label) {
+ if (uri.use && uri.use != uri.label) {
+ uri.label = uri.use;
+ uri.use = null;
+ }
+ }
+ var link = '<a class="classic_link" href="' + uri.href + '">' + uri.label + '</a>';
+ if (uri.use) {
+ link += ' (' + uri.use + ')';
+ }
+ return '<span>' + link + '</span><br/>';
+ ]]></script>
+ </td>
+ </tr>
</tbody>
</table>
- <!-- Empty span used for creating unAPI links -->
- <abbr name="unapi" class="unapi-id">
- <!-- unAPI URI goes here -->
- </abbr>
-
<script language='javascript' type='text/javascript'><![CDATA[
config.ids.rdetail.details_body = 'rdetail_details_body';
More information about the open-ils-commits
mailing list