added truth test and using for holdability check
authorerickson <erickson@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Thu, 29 Jun 2006 21:35:59 +0000 (21:35 +0000)
committererickson <erickson@dcc99617-32d9-48b4-a31d-7c20da2025e4>
Thu, 29 Jun 2006 21:35:59 +0000 (21:35 +0000)
git-svn-id: svn://svn.open-ils.org/ILS/trunk@4854 dcc99617-32d9-48b4-a31d-7c20da2025e4

Open-ILS/web/opac/common/js/opac_utils.js
Open-ILS/web/opac/skin/default/js/rdetail.js

index beaebad..f1fbcfa 100644 (file)
@@ -890,3 +890,4 @@ function parseForm(form) {
 }
 
 
+function isTrue(x) { return ( x && x != "0" && x != 'f' ); }
index b08ece8..e2a9c29 100644 (file)
@@ -692,17 +692,15 @@ function rdetailBuildStatusColumns() {
        for( i = 0; i < cp_statuses.length; i++ ) {
 
                var c = cp_statuses[i];
-
-               if(c && c.holdable()) {
-
+               if( c && isTrue(c.holdable()) ) {
                        var name = c.name();
                        _statusPositions[i] = c;
                        var node = template.cloneNode(true);
                        var data = findNodeByName( node, config.names.rdetail.cp_status);
-
+       
                        data.appendChild(text(name));
                        parent.appendChild(node);
-               }       
+               }
        }       
 
        numStatuses = 0;