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

Refactor the landing page backend API and add the top-loved dataset. #3270

Merged
merged 13 commits into from
Feb 20, 2025

Conversation

GspikeHalo
Copy link
Collaborator

Purpose:

Refactor the backend API of the landing page to reduce duplicate code. Add a top section on the landing page for the newly added dataset categories in the hub.

Changes:

  1. Rename getTopLovedWorkflows to getTops and modify its return type to List[DashboardClickableFileEntry] (which is a type included in the search results).
  2. Enhance getTops to dynamically select tables and columns, enabling support for different entity types and activities.
  3. Refactor fetchDashboardWorkflowsByWids to reuse existing logic in WorkflowResource.scala.
  4. Add fetchDashboardDatasetsByDids to reuse existing logic in DatasetResource.scala.
  5. Refactor data processing methods in the landing page to reuse search result processing methods (to be replaced during future search-related refactoring).
  6. Add dynamic navigation in the browse-section based on user permissions to ensure consistency with list item behavior.
  7. Add a "Top Loved Dataset" section to the landing page.

Demos:

"Top Loved Dataset" section:
image

Redirect when user has access:
image

Redirect when user lacks access:
image

@GspikeHalo GspikeHalo self-assigned this Feb 19, 2025
Copy link
Collaborator

@aglinxinyuan aglinxinyuan left a comment

Choose a reason for hiding this comment

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

LGTM!

Base automatically changed from team-b-add-dataset-interaction-button to master February 20, 2025 01:49
@GspikeHalo GspikeHalo merged commit acf0acd into master Feb 20, 2025
8 checks passed
@GspikeHalo GspikeHalo deleted the add-dataset-landing-page branch February 20, 2025 01:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants