Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support for like, dislike functionality #591

Open
skrishn opened this issue Mar 12, 2024 · 5 comments
Open

Support for like, dislike functionality #591

skrishn opened this issue Mar 12, 2024 · 5 comments
Assignees
Labels
2-ENH New feature or request Reporter 4.x Crowdsource Reporter (new)
Milestone

Comments

@skrishn
Copy link
Collaborator

skrishn commented Mar 12, 2024

Add support for users to 'Like', 'Dislike' a report. This is a config option. User will have to select a layer and select a numerical field to store the Like and dislike values.

@skrishn skrishn added 2-ENH New feature or request Reporter 4.x Crowdsource Reporter (new) labels Mar 12, 2024
@skrishn skrishn added this to the 2024.R02 milestone Mar 12, 2024
@sumitzarkar
Copy link
Collaborator

@skrishn

We would need how the configuration will be passed for this

@skrishn
Copy link
Collaborator Author

skrishn commented Mar 29, 2024

@sumitzarkar I'm still waiting on the app configuration designs.

Users would see a list of layers, and for those layers that are checked, they'd see options: Like, Dislike, Comment, Show Reporting Layers ( Report button shows up on the layers with this capability). For each enabled option, the user will configure the appropriate field. The UI would look similar to the CountDown Instant app. https://localgovdev.mapsdevext.arcgis.com/home/item.html?id=0125d213b027409b8d549e0295832e71

(#590)

I'll keep you posted

@sumitzarkar
Copy link
Collaborator

sumitzarkar commented Apr 2, 2024

@skrishn

Could you please ask the Instant app team to share the json structure for this configuration

@sumitzarkar
Copy link
Collaborator

@skrishn

Here is how the behavior of the like/dislike icons will be implemented:

  • By default, everything will be in neutral color as per mockups and only Like and Dislike will be clickable
    image

  • Once the user clicks like button. The like count will be increased by one and the like button will be shown in theme color to represent that the user has liked it and both the like and dislike buttons will now be disabled
    image

  • Similarly, if the dislike button is clicked, the dislike count will be increased by one and the dislike button will be shown in theme color and both buttons will be disabled
    image

Note: Just like the old reporter app here also users can like/dislike the same feature again and again when it is reopened.

@prachichawande-ct
Copy link
Collaborator

@skrishn

Dev Checklist

Items Is required Status Comments
Required NLS changes? No
Required Backward compatibility No
Required 508 Yes
Need Sanitize? No

Impact Analysis Report

Impacted Areas Comments
Have Configuration changes? No
Have Runtime changes? Yes
Impact on RTL Yes
Impact on feature details panel The Like or dislike button should be displayed below the feature details panel in the following cases:
  • The like or dislike field should be supported by the selected layer
  • Like or dislike field option should be enabled and respective fields should be chosen in the configuration
Like, dislike functionality
  • On clicking the like button should increment the count of a button by 1 and the button should be highlighted
  • If the like button is already clicked (button highlighted) then on clicking the button again should decrement the count of a button by 1 (button highlight should get removed)
  • If like button is already clicked(highlighted)
    • On dislike button click should decrement the count of a like button by 1 (like button highlight should get removed)
    • Count of dislike button should be incremented by 1(dislike button should be highlighted)
On click of the like or dislike button should update the feature info's like or dislike field values by the count of like or dislike field
If the user goes back from the feature's details panel and selects the same feature then the like or dislike clicked button state should be maintained

sumitzarkar added a commit that referenced this issue May 9, 2024
- #591
- Updated info card
 - to support feature details and like dislike functionality
 - #417
- Added strings for filter and feature details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2-ENH New feature or request Reporter 4.x Crowdsource Reporter (new)
Projects
None yet
Development

No branches or pull requests

3 participants