From 793aace69a5dbddc6bda6159bdfb5dfa6af3c281 Mon Sep 17 00:00:00 2001 From: Jorge Manrubia Date: Tue, 18 Nov 2025 11:36:47 +0100 Subject: [PATCH] Remove implicit order when filtering by closed cards We set the order in the dedicated column controllers and we don't want this in place when using composable filters. Also, this raises an error with the MySQL move when combined with assignees. Because we inject a .distinct there, that messes up with the query select, resulting in having to add a redundant select to the closed sorting scope, so that the closure.created_at is not lost. --- app/models/card.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/models/card.rb b/app/models/card.rb index 76283ebb6..08e5ead88 100644 --- a/app/models/card.rb +++ b/app/models/card.rb @@ -26,7 +26,7 @@ class Card < ApplicationRecord case index when "stalled" then stalled when "postponing_soon" then postponing_soon - when "closed" then closed.recently_closed_first + when "closed" then closed when "not_now" then postponed.latest when "golden" then golden when "draft" then drafted