[open-ils-commits] r9568 - trunk/Open-ILS/web/js/dojo/fieldmapper
svn at svn.open-ils.org
svn at svn.open-ils.org
Mon May 12 22:41:37 EDT 2008
Author: miker
Date: 2008-05-12 22:41:36 -0400 (Mon, 12 May 2008)
New Revision: 9568
Modified:
trunk/Open-ILS/web/js/dojo/fieldmapper/hash.js
Log:
store actual nulls instead of stringified "null"
Modified: trunk/Open-ILS/web/js/dojo/fieldmapper/hash.js
===================================================================
--- trunk/Open-ILS/web/js/dojo/fieldmapper/hash.js 2008-05-13 02:24:27 UTC (rev 9567)
+++ trunk/Open-ILS/web/js/dojo/fieldmapper/hash.js 2008-05-13 02:41:36 UTC (rev 9568)
@@ -32,8 +32,11 @@
function _toHash (includeNulls) {
var _hash = {};
for ( var i=0; i < this._fields.length; i++) {
- if (includeNulls || this[this._fields[i]]() != null)
- _hash[this._fields[i]] = '' + this[this._fields[i]]();
+ if (includeNulls || this[this._fields[i]]() != null) {
+ if (this[this._fields[i]]() == null)
+ _hash[this._fields[i]] = null;
+ else
+ _hash[this._fields[i]] = '' + this[this._fields[i]]();
}
return _hash;
}
More information about the open-ils-commits
mailing list