participedia / frontend

DEPRECATED - see https://github.com/participedia/api/ instead
MIT License
3 stars 2 forks source link

Same Entry, Different Titles in Profile View #865

Closed scottofletcher closed 5 years ago

scottofletcher commented 6 years ago

From @davidascher on June 26, 2018 21:47

Sender: scottowenfletcher@gmail.com Comment: Able to Select the Same Method From Different Tiles. Clicking 'CARE Community Score Card' brings you to the same page as clicking 'Community Score Card' does - the former is more up-to-date (changed the title), the latter shouldn't appear at all. Same thing with 'Community Forestry' and 'Community Forestry Groups' Open #224 in Usersnap Dashboard

Usersnap Feedback - Able to Select the Same Method From Different Tiles. Clicking 'CARE Commun(...) Download original image

Browser: Firefox 60 (Windows 10) Referer: https://participedia.xyz/users/417712 Screen size: 1920 x 1080 Browser size: 1920 x 876

Powered by usersnap.com

Copied from original issue: participedia/usersnaps#211

scottofletcher commented 6 years ago

NOTE: the duplicates don't show up on regular search - only when you're looking through Robert's entries from his profile page

ascott commented 5 years ago

@davidascher it looks like the issue here is with the API.

GET /users/{id} returns multiple case objects for the same id. it looks like it includes a case for every time i have edited it.

screenshot 2019-03-08 11 18 42

i could fix this on the frontend by looking for duplicate ids, and then sorting by updated date and only showing the latest updated case.

it's probably a better idea to fix this in the API, but I haven't been able to figure out what's going on there yet. my local db is only showing a single entry for this id, so i'm not sure how it is returning multiple. any ideas?