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

Add sorting functions on survey response columns #2517

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

Herover
Copy link
Collaborator

@Herover Herover commented Feb 1, 2025

Description

This PR adds some sorting on survey responses viewed in lists.

Screenshots

Many options
image

Single option
image

Free text
image

Changes

  • Free text responses are sorted alphabetically with the browsers locale compare, meaning order can change depending on browser language.
  • Many options are sorted by number of options selected.
  • Single options are sorted by selected or not

Notes to reviewer

A smartlist that adds people who responed to "A very open survey" has all the kinds of columns implemented.

Related issues

Resolves #2508

Copy link
Contributor

@ziggabyte ziggabyte left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi! I tried this out on a list where i added people who had responded to the "cheese survey", and also added people based on a different criteria. When I tried to sort the list based on the survey response columns when there were more people in the list, it did not behave really as I would have expected.

You can look at the list I used here and try sorting it, to see the buggy behaviour: /organize/1/people/lists/59

Do you wanna take a look and see what this behaviour is about, and see if you can fix it? :D

@Herover
Copy link
Collaborator Author

Herover commented Feb 20, 2025

Thanks for the feedback, I didn't consider testing with people who had not answered a survey. I hope it looks better now!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Lists: Sort based on responses to surveys
2 participants