Implement upvoting and downvoting system for Jira External Share

Description

Enable users to create an upvoting and downvoting system for Jira External Share board share to allow clients to vote on issues and help prioritize initiatives.


On share config user can “enable voting”.
It should be possible to pick issue field (numeric field) that we will update with number of votes.

We store in db table:

Column name

type

id

bigint

host_id

int

issue_id

text

project_id

text

voted_external_user_id

bitint

value

smallint

Value: 1 - mean upvote
Value: -1 - mean downvote

created

date-time

last_updated

date-time

On external user dashboard we present list of issue where user voted.
On internal issue view we present who voted, when and what value.
New votes table on issue view, project view, global view:


For Testing:

In project config / share config user should be able to enable/disable voting
In the share config, the user should be able to select the field into which the number of votes on the ticket in Jira will be saved. Saving is possible only if field is added to appropriate screen
Logged in user should be able to add or remove vote for issue
All votes for current issue should be listed in issue share in activity section
All user votes should be listed in user dashboard
All issue votes should be listed in view as below
All project votes should be listed in view as below

Linked issues

relates to
Issue Type Icon ESFJ-1515 E2E Playwright Test - Voting Priority: Lowest
To Do
Issue Type Icon ESFJ-1531 Vote timestamp does not take user's time zone setting into consideration Priority: Lowest
Review

Activity

Automation for Jira 11 April 2025, 14:03

Hello @Daniel Siara,

Please merge code to dev branch.
This is the best moment to add more information that can be helpful to prepare release notes.

  • Can you prepare short overview of change that can be used in release notes?

  • Please provide short GIF that showcase feature.

  • If GIF make no sense, can you provide image that highlights feature that can be used in release notes (cropped & annotated)?

Tomasz Lewandowski 11 April 2025, 14:03

As per Zulip discussion. Implementation verified on QA environment. No other new release blocking issues were encountered.

Daniel Siara 10 April 2025, 17:11

@Tomasz Lewandowski 6. According to me, this is the correct action. User votes for a specific issue and not for a specific share of that issue. Even if the share in which the user voted on the issue was deleted, it seems to me that his vote should still be valid. In the video you uploaded you can see that the user's vote is marked, so there can not be a situation in which the user casts the same vote twice.

So user should vote for a specific issue. In other case option to save votes number in Jira field does not make sense to me

Tomasz Lewandowski 10 April 2025, 15:19

@Daniel Siara

  1. Verified

  2. Downvote added and verified

  3. As discussed over Zulip, the Vote date still fails to display for me fo I’m failing this one

  4. As above

  5. Verified


  1. There is 1 more thing i noticed. After voting then deleting share link, when creating a new one the votes from previously deleted share are visible in audit trail. I’m not sure if this is intended but i assume not? Especially since the same user can add multiple votes this way.

Daniel Siara 4 April 2025, 09:01

@Tomasz Lewandowski

  1. Fixed

  2. It seems to me that the current behavior is quite simple and intuitive. After hovering over the button, the user receives information about what vote action he can perform, @Parsa Shiva what do you think?

  1. For me date displays (also in incognito), please check again, maybe create different ticket

  2. Exporting works also for me. I think your export problem is related to with missing date.

  3. Right, I forget about it in this place. Fixed

Tomasz Lewandowski 2 April 2025, 16:39

A few issues i encountered:
1) Once the vote is removed from the shared link, the entry still remains with an artifact under action column:

2) I don’t really see an option to downvote. If a downvote is done by clicking on a 👍 button twice, i don’t think this is the best solution. To me it seems misleading, we should add a separate 👎 button for that. Clicking any of those buttons for the 2nd time should completely remove the vote for all parties that can see it.

3) Vote Date column does not display any data

4) Clicking on Export to CSV button ends up in an infinite loading

5) For audit trail purposes I would suggest that apart from the votes tab, we also add an action to the activity where we add action “VOTED” and “REMOVED VOTE”. @Parsa Shiva for a consult here cause maybe i misunderstood the purpose of the task. @Daniel Siara If it’s more convenient i can also make a separate ticket out of that

Automation for Jira 31 March 2025, 09:56

Hello @Daniel Siara

This is the best moment to add more information that can be helpful for tester.

  • What areas are affected?

  • What are potential edge cases?

  • Was it checked for XSS problems?

  • Does change affect security, is new data exposed?

Please attach - Before / After screenshot if possible.

Daniel Siara 28 March 2025, 15:55

@Mariusz Szymański 🏓

Mariusz Szymański 25 March 2025, 07:57

@Krzysztof Bogdan No worries. I will take it.

Krzysztof Bogdan 24 March 2025, 13:41

@Mariusz Szymański Can you take review over. I have currently to much on my plate right now 😭

Automation for Jira 23 March 2025, 16:02

Hello [~accountid:],
Task is ready for review.

@Daniel Siara please make sure reviewer
have easy access to contend to be reviewed.

If this is code change. Please make sure PR is created.
If this is new documentation, blogpost, etc. Please provide link to page.

Parsa Shiva (pshiva@warsawdynamics.com) 29 March 2024, 10:51