fixed display issue of pre-cat items in fines dislpay
authorerickson <erickson@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Thu, 27 Jul 2006 20:06:28 +0000 (20:06 +0000)
committererickson <erickson@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Thu, 27 Jul 2006 20:06:28 +0000 (20:06 +0000)
git-svn-id: svn://svn.open-ils.org/ILS/trunk@5137 dcc99617-32d9-48b4-a31d-7c20da2025e4

Open-ILS/web/opac/skin/default/js/myopac.js

index 8772ea9..a6c38d4 100644 (file)
@@ -532,10 +532,24 @@ function myOPACShowCircTransaction(trans, record, circ) {
 
        var row = myopacCircTransTemplate.cloneNode(true);
 
-       buildTitleDetailLink(record, $n(row,'myopac_circ_trans_title'));
+       if(record) {
+               buildTitleDetailLink(record, $n(row,'myopac_circ_trans_title'));
+
+               $n(row,'myopac_circ_trans_author').appendChild(text(
+                       normalize(truncate(record.author(), 65))));
+
+       } else {
+
+               var req = new Request( FETCH_COPY, circ.target_copy() );
+               req.alertEvents = false;
+               req.send(true);
+               var copy = req.result();
+               if( copy ) {
+                       $n(row,'myopac_circ_trans_title').appendChild(text(copy.dummy_title()));
+                       $n(row,'myopac_circ_trans_author').appendChild(text(copy.dummy_author()));
+               }
+       }
 
-       $n(row,'myopac_circ_trans_author').appendChild(text(
-               normalize(truncate(record.author(), 65))));
 
        $n(row,'myopac_circ_trans_start').
                appendChild(text(_trimTime(trans.xact_start())));