dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #20863
[Branch ~dhis2-devs-core/dhis2/trunk] Rev 9717: Data entry, null check for local storage
------------------------------------------------------------
revno: 9717
committer: Lars Helge Øverland <larshelge@xxxxxxxxx>
branch nick: dhis2
timestamp: Tue 2013-02-05 00:40:03 +0200
message:
Data entry, null check for local storage
modified:
dhis-2/dhis-web/dhis-web-dataentry/src/main/webapp/dhis-web-dataentry/javascript/form.js
--
lp:dhis2
https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk
Your team DHIS 2 developers is subscribed to branch lp:dhis2.
To unsubscribe from this branch go to https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk/+edit-subscription
=== modified file 'dhis-2/dhis-web/dhis-web-dataentry/src/main/webapp/dhis-web-dataentry/javascript/form.js'
--- dhis-2/dhis-web/dhis-web-dataentry/src/main/webapp/dhis-web-dataentry/javascript/form.js 2013-01-04 18:10:25 +0000
+++ dhis-2/dhis-web/dhis-web-dataentry/src/main/webapp/dhis-web-dataentry/javascript/form.js 2013-02-04 22:40:03 +0000
@@ -1974,7 +1974,7 @@
var id = this.getDataValueIdentifier( dataElementId, categoryOptionComboId, periodId, organisationUnitId );
var dataValues = this.getAllDataValues();
- if ( dataValues[id] != null )
+ if ( dataValues != null && dataValues[id] != null )
{
delete dataValues[id];
localStorage[KEY_DATAVALUES] = JSON.stringify( dataValues );