akvo / akvo-flow-mobile

Akvo Flow app
GNU General Public License v3.0
18 stars 16 forks source link

Make manual loading of survey in wrong FLOW app impossible #242

Closed mtwestra closed 9 years ago

mtwestra commented 9 years ago

Some mobile users manually transfer a survey from one FLOW instance to a FLOW app from another instance. This can happen when an enumerator collects data using different FLOW instances, and doesn't install the correct FLOW app for a given survey.

Proposed solution: 1) Include the GAE app id in the survey definition XML 2) In the FLOW app, on loading a manually transferred survey, check if the survey XML app id corresponds to the data server as set in the FLOW app. If they don't match, display a toast saying that the survey does not belong to this FLOW instance app.

Corresponding FLOW Dashboard issue: https://github.com/akvo/akvo-flow/issues/1071

ichinaski commented 9 years ago

I'd suggest to leverage the existing notification errors (they now include meaningful messages), rather than showing a temporary toast.

cc/ @mtwestra

mtwestra commented 9 years ago

agreed

ichinaski commented 9 years ago

Test plan:

rumca commented 9 years ago

The above test plan passes as described :+1: