From 733e442ab447e6c3c870907a383c6d3d4567222e Mon Sep 17 00:00:00 2001 From: Marcel Werk Date: Tue, 3 Dec 2024 15:42:38 +0100 Subject: [PATCH] Unify RPC endpoint naming --- ts/WoltLabSuite/Core/Api/Gridviews/GetRows.ts | 2 +- .../files/js/WoltLabSuite/Core/Api/Gridviews/GetRows.js | 2 +- wcfsetup/install/files/lib/bootstrap/com.woltlab.wcf.php | 2 +- .../core/{gridviews => gridViews}/GetRows.class.php | 4 ++-- 4 files changed, 5 insertions(+), 5 deletions(-) rename wcfsetup/install/files/lib/system/endpoint/controller/core/{gridviews => gridViews}/GetRows.class.php (96%) diff --git a/ts/WoltLabSuite/Core/Api/Gridviews/GetRows.ts b/ts/WoltLabSuite/Core/Api/Gridviews/GetRows.ts index 142f6b15b6..3ebbc399b0 100644 --- a/ts/WoltLabSuite/Core/Api/Gridviews/GetRows.ts +++ b/ts/WoltLabSuite/Core/Api/Gridviews/GetRows.ts @@ -16,7 +16,7 @@ export async function getRows( filters?: Map, gridViewParameters?: Map, ): Promise> { - const url = new URL(`${window.WSC_RPC_API_URL}core/gridviews/rows`); + const url = new URL(`${window.WSC_RPC_API_URL}core/grid-views/rows`); url.searchParams.set("gridView", gridViewClass); url.searchParams.set("pageNo", pageNo.toString()); url.searchParams.set("sortField", sortField); diff --git a/wcfsetup/install/files/js/WoltLabSuite/Core/Api/Gridviews/GetRows.js b/wcfsetup/install/files/js/WoltLabSuite/Core/Api/Gridviews/GetRows.js index 8e0931892b..f85f33a7d7 100644 --- a/wcfsetup/install/files/js/WoltLabSuite/Core/Api/Gridviews/GetRows.js +++ b/wcfsetup/install/files/js/WoltLabSuite/Core/Api/Gridviews/GetRows.js @@ -3,7 +3,7 @@ define(["require", "exports", "WoltLabSuite/Core/Ajax/Backend", "../Result"], fu Object.defineProperty(exports, "__esModule", { value: true }); exports.getRows = getRows; async function getRows(gridViewClass, pageNo, sortField = "", sortOrder = "ASC", filters, gridViewParameters) { - const url = new URL(`${window.WSC_RPC_API_URL}core/gridviews/rows`); + const url = new URL(`${window.WSC_RPC_API_URL}core/grid-views/rows`); url.searchParams.set("gridView", gridViewClass); url.searchParams.set("pageNo", pageNo.toString()); url.searchParams.set("sortField", sortField); diff --git a/wcfsetup/install/files/lib/bootstrap/com.woltlab.wcf.php b/wcfsetup/install/files/lib/bootstrap/com.woltlab.wcf.php index 22f5a5a0a2..60ddb452b2 100644 --- a/wcfsetup/install/files/lib/bootstrap/com.woltlab.wcf.php +++ b/wcfsetup/install/files/lib/bootstrap/com.woltlab.wcf.php @@ -135,7 +135,7 @@ return static function (): void { $event->register(new \wcf\system\endpoint\controller\core\comments\responses\RenderResponses); $event->register(new \wcf\system\endpoint\controller\core\comments\responses\UpdateResponse); $event->register(new \wcf\system\endpoint\controller\core\exceptions\RenderException); - $event->register(new \wcf\system\endpoint\controller\core\gridviews\GetRows); + $event->register(new \wcf\system\endpoint\controller\core\gridViews\GetRows); $event->register(new \wcf\system\endpoint\controller\core\messages\GetMentionSuggestions); $event->register(new \wcf\system\endpoint\controller\core\sessions\DeleteSession); $event->register(new \wcf\system\endpoint\controller\core\users\options\DeleteOption); diff --git a/wcfsetup/install/files/lib/system/endpoint/controller/core/gridviews/GetRows.class.php b/wcfsetup/install/files/lib/system/endpoint/controller/core/gridViews/GetRows.class.php similarity index 96% rename from wcfsetup/install/files/lib/system/endpoint/controller/core/gridviews/GetRows.class.php rename to wcfsetup/install/files/lib/system/endpoint/controller/core/gridViews/GetRows.class.php index a2dc415696..a4b8185909 100644 --- a/wcfsetup/install/files/lib/system/endpoint/controller/core/gridviews/GetRows.class.php +++ b/wcfsetup/install/files/lib/system/endpoint/controller/core/gridViews/GetRows.class.php @@ -1,6 +1,6 @@ * @since 6.2 */ -#[GetRequest('/core/gridviews/rows')] +#[GetRequest('/core/grid-views/rows')] final class GetRows implements IController { #[\Override] -- 2.20.1