akvo / akvo-flow

A data collection and monitoring tool that works anywhere.
http://akvo.org/products/akvoflow/
GNU Affero General Public License v3.0
65 stars 31 forks source link

In public map responses for option questions, cascades, photos, and videos are rendered as a string #1635

Closed janagombitova closed 7 years ago

janagombitova commented 8 years ago

Since the introduction of codes for option questions and geotagging of media items, the collected data is shown in the public map as a string. This issue refers to https://github.com/akvo/akvo-flow/issues/1632

Question types rendered as a string:

screen shot 2016-04-28 at 08 55 18 screen shot 2016-04-28 at 09 41 46 screen shot 2016-08-12 at 13 26 10
janagombitova commented 8 years ago

Created via Reamaze:

Link: https://akvoo.reamaze.com/admin/conversations/akvoflow-support-request-number-14616-from-anatamambo-at-gmail-dot-com

janagombitova commented 8 years ago

Furthermore, photo or video with geotag or without is also shown as a string

screen shot 2016-06-07 at 08 11 03 screen shot 2016-06-07 at 08 12 20
mtwestra commented 8 years ago

fixed as part of [#1577]

janagombitova commented 8 years ago

Test plan:

  1. Open Flow without logging in and on the public map select a data point (ideally one where you know all questions are represented - especially: option questions with codes, cascades, photos, videos and Caddisfly)
  2. Check that the submitted answers are not rendered as a string
  3. Click through multiple points to confirm
  4. Check in different browsers as well
janagombitova commented 7 years ago

Notes from testing

Options and cascades show now as pipe separated values - 👍 Geoshapes show as strings but that is outside of the scope of this issue. - 👍

There is an inconsistency in how the photo and video responses are shown. The photos render on the top of the side bar and are clickable, so that is ok. But in the answers they either show the full url or only a path. Same for videos. @mtwestra why is this and can we show the url for all cases?

screen shot 2016-10-20 at 16 00 02

screen shot 2016-10-20 at 16 01 04

screen shot 2016-10-20 at 16 01 32

screen shot 2016-10-20 at 16 01 37

You can check it out on https://uat1.akvoflow.org/ on data points located around Schiphol.

mtwestra commented 7 years ago

@janagombitova: This seems to be some legacy stuff. The path of the photo that is in the actual answer used to contain the path on the device, which is not relevant. To display the photo, the backend stripped off the image name, and the actual path to amazon was build up. From what I see here, the video path is still treated like that, while for the photo both types of paths are now shown. I am not sure where that comes from. In any case, both of these should be replaced by the reconstructed path: amazon root+image folder + filename. This value should be easy to get as it is also used to show the image.

janagombitova commented 7 years ago

@mtwestra that sounds like an easy fix. Can you take a look at it and try to fix it up? Thank you

janagombitova commented 7 years ago

Based on the discussion with @mtwestra I am creating a separate issue to deal with the diversity in displaying video and photo responses. https://github.com/akvo/akvo-flow/issues/1799

If we do not take into account the difference in displaying the photo and video answers, then this issue passes the test plan 👍