Skip to content

fix: Feature: Implement Full-Text Search for Tickets using Supabase pg_trgm#645

Open
saij3b wants to merge 1 commit into
ritesh-1918:mainfrom
saij3b:bounty/379-feature-implement-full-text-search-for-t
Open

fix: Feature: Implement Full-Text Search for Tickets using Supabase pg_trgm#645
saij3b wants to merge 1 commit into
ritesh-1918:mainfrom
saij3b:bounty/379-feature-implement-full-text-search-for-t

Conversation

@saij3b
Copy link
Copy Markdown
Contributor

@saij3b saij3b commented May 29, 2026

Closes #379.

Frontend deps aren't installed in this clone, so I can't fully run build/lint, but the file changes follow existing conventions and imports.

Summary

Added Supabase pg_trgm-backed live ticket search to satisfy bounty #379:

  • supabase/migrations/20260530000000_ticket_search.sql — enables pg_trgm, adds GIN trigram indexes on tickets.subject/description/category/status and profiles.full_name, and defines a search_tickets(q, limit_count) RPC (SECURITY INVOKER so existing RLS scopes results to the caller's role/company automatically). Returns ticket id, subject, description, category, status, priority, assignee name, and a similarity rank.
  • Frontend/src/admin/components/AdminHeader.jsx — kept the existing search input but wired it to a 300ms-debounced supabase.rpc('search_tickets', …) call, rendered a dropdown of up to 8 matches under the input with loading/empty states, added full keyboard navigation (ArrowUp/Down highlight, Enter opens the highlighted ticket via /admin/ticket/:id, Escape clears/closes), click-outside dismissal, and ARIA combobox/listbox roles. Plain Enter without a highlighted result still falls back to the existing /admin/tickets?q=… page filter for continuity.

Tests: no test suite detected


Bounty attempt.

@vercel
Copy link
Copy Markdown

vercel Bot commented May 29, 2026

@saij3b is attempting to deploy a commit to the ritesh Team on Vercel.

A member of the Team first needs to authorize it.

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented May 29, 2026

Warning

Review limit reached

@saij3b, we couldn't start this review because you've reached your PR review rate limit.

More reviews will be available in 4 minutes and 19 seconds. Learn how PR review limits work.

Your organization has run out of usage credits. Purchase more in the billing tab.

⌛ How to resolve this issue?

After more reviews become available, a review can be triggered using the @coderabbitai review command as a PR comment. Alternatively, push new commits to this PR.

We recommend that you space out your commits to avoid hitting the rate limit.

🚦 How do rate limits work?

CodeRabbit enforces hourly rate limits for each developer per organization.

Our paid plans include higher PR review limits than trial, open-source, and free plans. In all cases, reviews become available again over time. During sustained high-volume PR review activity, CodeRabbit may temporarily slow when the next review becomes available.

Please see our Fair Usage Limits Policy for further information.

ℹ️ Review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 7a7c9abb-77e4-4c9a-ad10-20e281b2d415

📥 Commits

Reviewing files that changed from the base of the PR and between da8faf2 and aae59c8.

📒 Files selected for processing (2)
  • Frontend/src/admin/components/AdminHeader.jsx
  • supabase/migrations/20260530000000_ticket_search.sql
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

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.

Feature: Implement Full-Text Search for Tickets using Supabase pg_trgm

1 participant