feat: add featured projects admin flow#140
Open
Whiznificent wants to merge 2 commits into
Open
Conversation
- Add FeaturedProjects storage key to StorageKey enum - Add FeaturedProjectEvent type to types.rs - Add publish_featured_project_event to events.rs - Add featured_registry.rs with set_featured and list_featured_projects - Expose set_featured and list_featured_projects in lib.rs - Add 6 tests covering admin-only access, not-found, set/unfeature, idempotency, pagination, and empty list
|
@Whiznificent Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits. You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀 |
Contributor
|
@Whiznificent please resolve conflicts |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #126
Summary
Implements the featured projects admin flow, allowing admins to highlight trusted or important projects on-chain.
Changes
storage_keys.rs– AddedFeaturedProjectsstorage key to persist the list of featured project IDs.types.rs– AddedFeaturedProjectEventstruct emitted on feature/unfeature actions.events.rs– Addedpublish_featured_project_eventpublisher.featured_registry.rs– New module with:set_featured(admin, project_id, featured)– admin-only, marks/unmarks a project as featured, emits event, idempotent.list_featured_projects(start, limit)– paginated listing of featured projects (max 100 per page).lib.rs– Exposedset_featuredandlist_featured_projectsas public contract methods.tests/featured.rs– 6 tests covering:Acceptance Criteria
closes #126