[open-ils-commits] r19853 - branches/rel_2_1/Open-ILS/web/opac/common/js (phasefx)
svn at svn.open-ils.org
svn at svn.open-ils.org
Tue Mar 22 12:00:16 EDT 2011
Author: phasefx
Date: 2011-03-22 12:00:13 -0400 (Tue, 22 Mar 2011)
New Revision: 19853
Modified:
branches/rel_2_1/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: branches/rel_2_1/Open-ILS/web/opac/common/js/opac_utils.js
===================================================================
--- branches/rel_2_1/Open-ILS/web/opac/common/js/opac_utils.js 2011-03-22 15:59:44 UTC (rev 19852)
+++ branches/rel_2_1/Open-ILS/web/opac/common/js/opac_utils.js 2011-03-22 16:00:13 UTC (rev 19853)
@@ -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