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

feat: add dynamic filters #494

Merged
merged 3 commits into from
Dec 13, 2024
Merged

feat: add dynamic filters #494

merged 3 commits into from
Dec 13, 2024

Conversation

foyarash
Copy link
Collaborator

@foyarash foyarash commented Dec 6, 2024

Title

Add the possibility to retrieve filters dynamically

Type of Change

  • New feature
  • Bug fix
  • Documentation update
  • Example update
  • Refactoring
  • Hotfix
  • Security patch
  • UI/UX improvement

Issue

#491

Description

This PR adds the possibility to pass an async function to the filters array, which will return an array of filters.
This also adds the possibility to group filters by an id to give the filters with the same group name a radio button like behavior.

Testing

Dynamic filters have been setup in the example app on the Post model

@foyarash foyarash requested a review from cregourd December 6, 2024 14:40
Copy link

changeset-bot bot commented Dec 6, 2024

🦋 Changeset detected

Latest commit: 73263f2

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@premieroctet/next-admin Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

packages/next-admin/src/utils/prisma.ts Outdated Show resolved Hide resolved
@foyarash foyarash force-pushed the feat/dynamic-filters branch from 6ff1ca4 to ea2bcad Compare December 13, 2024 10:39
@foyarash foyarash merged commit 07d8996 into main Dec 13, 2024
3 checks passed
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.

2 participants