[open-ils-commits] r19852 - trunk/Open-ILS/web/opac/common/js (phasefx)
svn at svn.open-ils.org
svn at svn.open-ils.org
Tue Mar 22 11:59:47 EDT 2011
Author: phasefx
Date: 2011-03-22 11:59:44 -0400 (Tue, 22 Mar 2011)
New Revision: 19852
Modified:
trunk/Open-ILS/web/opac/common/js/opac_utils.js
Log:
have checkILSEvent handle events that aren't in ils_events.xml
Signed-off-by: Jason Etheridge <jason at esilibrary.com>
Modified: trunk/Open-ILS/web/opac/common/js/opac_utils.js
===================================================================
--- trunk/Open-ILS/web/opac/common/js/opac_utils.js 2011-03-22 14:40:41 UTC (rev 19851)
+++ trunk/Open-ILS/web/opac/common/js/opac_utils.js 2011-03-22 15:59:44 UTC (rev 19852)
@@ -1043,8 +1043,13 @@
}
function checkILSEvent(obj) {
- if( obj && obj.ilsevent != null && obj.ilsevent != 0 )
- return parseInt(obj.ilsevent);
+ if (obj && typeof obj == 'object' && typeof obj.ilsevent != 'undefined') {
+ if (obj.ilsevent === '') {
+ return true;
+ } else if ( obj.ilsevent != null && obj.ilsevent != 0 ) {
+ return parseInt(obj.ilsevent);
+ }
+ }
return null;
}
More information about the open-ils-commits
mailing list