Hi
I am making events through API which include coordinates. But when posting the event everything gets saved except coordinates.
URL : http://localhost:8090/dhis/api/events/
Pay Load :
{
“coordinate”: {“latitude”: 13.1707428419558, “longitude”: 79.6169626173919},
“event”: “O02d839dd7c”,
“eventDate”: “2017-04-05T16:20:00.360+05:30”,
“orgUnit”: “ZFMOv30Ab8b”,
“program”: “Ml0ZNj9APN0”,
“programStage”: “iWcQ5lxmsy4”,
“status”: “COMPLETED”
}
Import summary is all OK and rest of the data is saved.
Version:
2.25
Build revision:
f20cd15
Build date:
2017-06-12 17:23
Same happens in 26 and 27 also.
Regards
harsh
Markus
(Markus Bekken)
12 June 2017 14:40
2
Dear Harsh,
can you reproduce in play? Trying to reproduce through the event capture app, the only difference I see between the two payloads is the number of decimals in the coordinate captured. The apps uses only 6 decimals:
“coordinate”:{“latitude”:9.394871,“longitude”:-11.487579}
Markus
···
jun. 2017 kl. 14.53 skrev Harsh Atal harsh.atal@gmail.com :
Hi
I am making events through API which include coordinates. But when posting the event everything gets saved except coordinates.
URL : http://localhost:8090/dhis/api/events/
Pay Load :
{
“coordinate”: {“latitude”: 13.1707428419558, “longitude”: 79.6169626173919},
“event”: “O02d839dd7c”,
“eventDate”: “2017-04-05T16:20:00.360+05:30”,
“orgUnit”: “ZFMOv30Ab8b”,
“program”: “Ml0ZNj9APN0”,
“programStage”: “iWcQ5lxmsy4”,
“status”: “COMPLETED”
}
Import summary is all OK and rest of the data is saved.
Version:
2.25
Build revision:
f20cd15
Build date:
2017-06-12 17:23
Same happens in 26 and 27 also.
Regards
harsh
Mailing list: https://launchpad.net/~dhis2-devs
Post to : dhis2-devs@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-devs
More help : https://help.launchpad.net/ListHelp
You need to set the program stage ‘Capture coordinates’. Also be aware that you can only set coordinates with the post, they will not update via the API.
Pierre
···
On Mon, Jun 12, 2017 at 4:40 PM Markus Bekken markus@dhis2.org wrote:
Dear Harsh,
can you reproduce in play? Trying to reproduce through the event capture app, the only difference I see between the two payloads is the number of decimals in the coordinate captured. The apps uses only 6 decimals:
“coordinate”:{“latitude”:9.394871,“longitude”:-11.487579}
Markus
jun. 2017 kl. 14.53 skrev Harsh Atal harsh.atal@gmail.com :
Hi
I am making events through API which include coordinates. But when posting the event everything gets saved except coordinates.
URL : http://localhost:8090/dhis/api/events/
Pay Load :
{
“coordinate”: {“latitude”: 13.1707428419558, “longitude”: 79.6169626173919},
“event”: “O02d839dd7c”,
“eventDate”: “2017-04-05T16:20:00.360+05:30”,
“orgUnit”: “ZFMOv30Ab8b”,
“program”: “Ml0ZNj9APN0”,
“programStage”: “iWcQ5lxmsy4”,
“status”: “COMPLETED”
}
Import summary is all OK and rest of the data is saved.
Version:
2.25
Build revision:
f20cd15
Build date:
2017-06-12 17:23
Same happens in 26 and 27 also.
Regards
harsh
Mailing list: https://launchpad.net/~dhis2-devs
Post to : dhis2-devs@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-devs
More help : https://help.launchpad.net/ListHelp
Mailing list: https://launchpad.net/~dhis2-devs
Post to : dhis2-devs@lists.launchpad.net
Unsubscribe : https://launchpad.net/~dhis2-devs
More help : https://help.launchpad.net/ListHelp
–
Pierre Dane
Director of Technology
Jembi Health Systems NPC