fix: server-side search for Chatflows page to search across all pages#6155
Open
octo-patch wants to merge 1 commit intoFlowiseAI:mainfrom
Open
fix: server-side search for Chatflows page to search across all pages#6155octo-patch wants to merge 1 commit intoFlowiseAI:mainfrom
octo-patch wants to merge 1 commit intoFlowiseAI:mainfrom
Conversation
Contributor
There was a problem hiding this comment.
Code Review
This pull request implements server-side search for chatflows, moving the filtering logic from the frontend to the backend. The getAllChatflows endpoint now accepts a search query, which the service uses to filter results by name, category, or ID. The UI has been updated with a debounced search mechanism to trigger these requests. I have no feedback to provide.
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.
Fixes the same client-side search limitation reported for Agentflows in #5868, but for the Chatflows page.
Problem
The Chatflows page uses a local
filterFlowsfunction that filters only the data loaded for the current page. When users have many chatflows spread across multiple pages and type in the search box, results from other pages are never shown.Solution
searchquery parameter to thegetAllChatflowscontroller and service. The search filter matches againstname,category, andidusing case-insensitiveLIKEqueries, and is applied before pagination so thattotalaccurately reflects the filtered count.filterFlowswith a debounced (300ms) effect that passes the search term to the API and resets to page 1 on new searches. Updated search placeholder to "Search Name, Category, or ID".Testing
Note: This fix mirrors the approach used in PR #6133 for the Agentflows page.