take advantage of new virtual duedate field on noncat circs in opac display
authorerickson <erickson@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Fri, 20 Nov 2009 17:48:19 +0000 (17:48 +0000)
committererickson <erickson@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Fri, 20 Nov 2009 17:48:19 +0000 (17:48 +0000)
git-svn-id: svn://svn.open-ils.org/ILS/trunk@14990 dcc99617-32d9-48b4-a31d-7c20da2025e4

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

index 65d57b2..7f49442 100644 (file)
@@ -1389,13 +1389,13 @@ function myOPACDrawNonCatCirc(r) {
        appendClear($n(row, 'circ_lib'), text(findOrgUnit(circ.circ_lib()).name()));
        appendClear($n(row, 'item_type'), text(type.name()));
 
-       var duration = interval_to_seconds(type.circ_duration());
-       duration = parseInt(duration + '000');
-
-       var dtf = circ.circ_time();
-    var start = dojo.date.stamp.fromISOString(circ.circ_time());
-       var due = new Date(  start.getTime() + duration );
-       appendClear($n(row, 'circ_time'), text(due.iso8601Format('YMDHM', null, true, true)));
+       appendClear(
+        $n(row, 'circ_time'), 
+        text(dojo.date.locale.format(
+            dojo.date.stamp.fromISOString(circ.duedate()),
+            {format : 'short'}
+        ))
+    );
 }