From: miker Date: Tue, 13 May 2008 02:22:32 +0000 (+0000) Subject: allow null properties coming from objects X-Git-Url: https://old-git.evergreen-ils.org/?a=commitdiff_plain;h=24f58f25f2ddd0c7086070c8092ef2de9f79da17;p=Evergreen.git allow null properties coming from objects git-svn-id: svn://svn.open-ils.org/ILS/trunk@9564 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- diff --git a/Open-ILS/web/js/dojo/fieldmapper/hash.js b/Open-ILS/web/js/dojo/fieldmapper/hash.js index c186dfac93..6f82e57534 100644 --- a/Open-ILS/web/js/dojo/fieldmapper/hash.js +++ b/Open-ILS/web/js/dojo/fieldmapper/hash.js @@ -29,10 +29,10 @@ if(!dojo._hasResource['fieldmapper.hash']){ return this; } - function _toHash () { + function _toHash (includeNulls) { var _hash = {}; for ( var i=0; i < this._fields.length; i++) { - if (this[this._fields[i]]() != null) + if (includeNulls || this[this._fields[i]]() != null) _hash[this._fields[i]] = '' + this[this._fields[i]](); } return _hash;