Skip to content

Sohail: HGN Questionnaire Dashboard: Community Members (Filtered Members View)#5139

Open
sohailuddinsyed wants to merge 1 commit intodevelopmentfrom
Sohail-community-members-skill-filter
Open

Sohail: HGN Questionnaire Dashboard: Community Members (Filtered Members View)#5139
sohailuddinsyed wants to merge 1 commit intodevelopmentfrom
Sohail-community-members-skill-filter

Conversation

@sohailuddinsyed
Copy link
Copy Markdown
Contributor

@sohailuddinsyed sohailuddinsyed commented Apr 12, 2026

Description

Task: HGN Questionnaire Dashboard: Community Members (Filtered Members View)

Main source: Follow up task for PR 2143

Route: /hgnhelp/community
Purpose: Ensure the Community Members page displays members correctly on initial load, preserves filtered member rendering, and adds frontend sort controls for name and score.

Issue: The frontend was not showing members when the page loaded with no filters applied, even though the backend endpoint returns all members without query parameters. The sortOrder parameter was present but had no UI to control it, and the default member rendering path needed to be aligned with the backend behavior.

Related PRs (if any):

This frontend PR is related to the backend PR 2143.

Main changes explained:

  • Updated src/components/HGNHelpSkillsDashboard/CommunityMembersPage.jsx to render RankedUserList by default instead of hiding members when no filters are selected.
  • Added sort controls for sortBy (name or score) and sortOrder (ascending or descending) so the user can change sort order from the UI.
  • Updated src/components/HGNHelpSkillsDashboard/RankedUserList.jsx to call /hgnHelp/community when no filters are applied and retain /hgnform/ranked for filtered results.
  • Added frontend normalization for default member responses so topSkills can be shown when members are displayed without filters.
  • Added client-side sorting logic for both name and score while preserving the existing filtered member rendering and search behavior.

How to test:

  1. Check out the frontend branch.
  2. Run npm install and start the development server.
  3. Clear browser site data/cache.
  4. Log in as an admin user.
  5. Navigate to /hgnhelp/community.
  6. Confirm that all members are shown by default with top skills visible.
  7. Apply one or more skill filters/preferences and confirm matching community members are displayed with score and top skills.
  8. Verify name sort order works in ascending and descending modes.
  9. Verify score sort order works in ascending and descending modes.
  10. Confirm that search still filters the displayed members as expected.

Screenshots of changes:

Screenshot 2026-04-12 013638 Screenshot 2026-04-12 013629

…filtered member rendering, and add name/score sort controls
@netlify
Copy link
Copy Markdown

netlify bot commented Apr 12, 2026

Deploy Preview for highestgoodnetwork-dev ready!

Name Link
🔨 Latest commit 933cb94
🔍 Latest deploy log https://app.netlify.com/projects/highestgoodnetwork-dev/deploys/69db6688f7a17800084aef50
😎 Deploy Preview https://deploy-preview-5139--highestgoodnetwork-dev.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

@sohailuddinsyed sohailuddinsyed added the High Priority - Please Review First This is an important PR we'd like to get merged as soon as possible label Apr 12, 2026
@sonarqubecloud
Copy link
Copy Markdown

Copy link
Copy Markdown

@HemanthNidamanuru HemanthNidamanuru left a comment

Choose a reason for hiding this comment

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

Hi Sohail,

I tested this PR locally and everything looks good except one issue - when no filter is selected, the score is not displaying on the member cards (shows as "/ 10" with no value). Is that the expected behavior?

Image Image Image Image Image Image

@rapolusidhartha
Copy link
Copy Markdown

image image image Working as expected

Copy link
Copy Markdown

@rapolusidhartha rapolusidhartha left a comment

Choose a reason for hiding this comment

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

working as expecting
Well done

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

High Priority - Please Review First This is an important PR we'd like to get merged as soon as possible

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants