From: phasefx Date: Tue, 11 Jan 2011 21:45:53 +0000 (+0000) Subject: fix regression with org selector when specifying ?ol= and the org unit hiding setting... X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=ed0714051eaff723d05a2030d6ef8867ae708bca;p=evergreen%2Fjoelewis.git fix regression with org selector when specifying ?ol= and the org unit hiding setting is unset git-svn-id: svn://svn.open-ils.org/ILS/trunk@19155 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- diff --git a/Open-ILS/web/opac/common/js/opac_utils.js b/Open-ILS/web/opac/common/js/opac_utils.js index 9c10e2ae8b..e585137080 100644 --- a/Open-ILS/web/opac/common/js/opac_utils.js +++ b/Open-ILS/web/opac/common/js/opac_utils.js @@ -854,7 +854,11 @@ function checkOrgHiding() { if ( findOrgDepth( context_org ) < depth ) { return false; // disable org hiding if Original Location doesn't make sense with setting depth (avoids disjointed org selectors) } - return { 'org' : findOrgUnit(context_org), 'depth' : depth }; + if (depth) { + return { 'org' : findOrgUnit(context_org), 'depth' : depth }; + } else { + return false; + } } var orgTreeSelector;