From dac920d491947c300df7f66e0397fe771c61abea Mon Sep 17 00:00:00 2001 From: Nick Khaetsky Date: Thu, 25 Jan 2024 11:19:59 +0300 Subject: [PATCH 1/2] Introduce setSortableOrderComplete event in Sortable --- src/Database/Traits/Sortable.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/Database/Traits/Sortable.php b/src/Database/Traits/Sortable.php index 62e5ee306..4b9918c98 100644 --- a/src/Database/Traits/Sortable.php +++ b/src/Database/Traits/Sortable.php @@ -83,6 +83,8 @@ public function setSortableOrder($itemIds, $referencePool = null) ->update([$this->getSortOrderColumn() => $update['sort_order']]); } } + + $this->fireEvent('model.setSortableOrderComplete'); } /** From d8d37dda46718364c59f59daf0c87de2695592d6 Mon Sep 17 00:00:00 2001 From: daft Date: Fri, 26 Jan 2024 12:09:52 +1100 Subject: [PATCH 2/2] Update event name --- src/Database/Traits/Sortable.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Database/Traits/Sortable.php b/src/Database/Traits/Sortable.php index 4b9918c98..2c274da47 100644 --- a/src/Database/Traits/Sortable.php +++ b/src/Database/Traits/Sortable.php @@ -84,7 +84,7 @@ public function setSortableOrder($itemIds, $referencePool = null) } } - $this->fireEvent('model.setSortableOrderComplete'); + $this->fireEvent('model.setSortableOrder'); } /**