From 9acf48e78ae46611a6ca1b7b008fedc4a3e7f4f6 Mon Sep 17 00:00:00 2001 From: lorentz Date: Wed, 29 Apr 2026 14:36:22 -0400 Subject: [PATCH] fix(analyzer): priorities has no is_deleted column MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Filter-options endpoint was rejecting from the priorities subquery, and because all six lookups run in Promise.all the whole endpoint failed with HTTP 500 — leaving every multi-select dropdown empty including Client. priorities is a small reference table with no soft-delete; just filter on is_active. Co-Authored-By: Claude Opus 4.7 (1M context) --- app/api/analyzer/tickets/filter-options/route.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/app/api/analyzer/tickets/filter-options/route.ts b/app/api/analyzer/tickets/filter-options/route.ts index 0be4b9b..6f3c8c4 100644 --- a/app/api/analyzer/tickets/filter-options/route.ts +++ b/app/api/analyzer/tickets/filter-options/route.ts @@ -52,8 +52,9 @@ export async function GET() { ORDER BY sort_order NULLS LAST, label` ), postgresClient.query( + // priorities has no is_deleted column (no soft-delete on this small table) `SELECT value, label FROM priorities - WHERE is_active = true AND is_deleted = false + WHERE is_active = true ORDER BY value` ), postgresClient.query(