dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #13432
[Branch ~dhis2-devs-core/dhis2/trunk] Rev 4303: minor fix
------------------------------------------------------------
revno: 4303
committer: Morten Olav Hansen <mortenoh@xxxxxxxxx>
branch nick: dhis2
timestamp: Mon 2011-08-15 16:09:44 +0200
message:
minor fix
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 2011-08-15 14:08:38 +0000
+++ dhis-2/dhis-web/dhis-web-dataentry/src/main/webapp/dhis-web-dataentry/javascript/form.js 2011-08-15 14:09:44 +0000
@@ -1079,15 +1079,10 @@
var id = this.getDataValueIdentifier( dataElementId, categoryOptionComboId, periodId, organisationUnitId );
var dataValues = this.getAllDataValues();
- var ret = delete dataValues[id];
-
- if(ret) {
- console.log("deleted with id " + id);
- } else {
- console.log("could not delete with id " + id);
+ if(dataValues[id] != null) {
+ delete dataValues[id];
+ localStorage[KEY_DATAVALUES] = JSON.stringify( dataValues );
}
-
- localStorage[KEY_DATAVALUES] = JSON.stringify( dataValues );
}
/**