From 8041a3a4ded442e13391b9128b2bf28a4a3ba71b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Hlav=C3=A1=C4=8Dek?= Date: Fri, 25 Jul 2025 14:20:13 +0200 Subject: [PATCH 1/4] Provide absolute URL --- productcomments.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/productcomments.php b/productcomments.php index 3ba52fd..403a16e 100644 --- a/productcomments.php +++ b/productcomments.php @@ -455,7 +455,7 @@ public function renderModerateLists() $helper->table = $this->name; $helper->table_id = 'waiting-approval-productcomments-list'; $helper->token = Tools::getAdminTokenLite('AdminModules'); - $helper->currentIndex = AdminController::$currentIndex . '&configure=' . $this->name; + $helper->currentIndex = $this->context->link->getAdminLink('AdminModules', false) . '&configure=' . $this->name . '&tab_module=' . $this->tab . '&module_name=' . $this->name; $helper->no_link = true; $return .= $helper->generateList($comments, $fields_list); @@ -480,7 +480,7 @@ public function renderModerateLists() $helper->table = $this->name; $helper->table_id = 'reported-productcomments-list'; $helper->token = Tools::getAdminTokenLite('AdminModules'); - $helper->currentIndex = AdminController::$currentIndex . '&configure=' . $this->name; + $helper->currentIndex = $this->context->link->getAdminLink('AdminModules', false) . '&configure=' . $this->name . '&tab_module=' . $this->tab . '&module_name=' . $this->name; $helper->no_link = true; $return .= $helper->generateList($comments, $fields_list); @@ -564,7 +564,7 @@ public function renderCriterionList() $helper->title = $this->trans('Review Criteria', [], 'Modules.Productcomments.Admin'); $helper->table = $this->name . 'criterion'; $helper->token = Tools::getAdminTokenLite('AdminModules'); - $helper->currentIndex = AdminController::$currentIndex . '&configure=' . $this->name; + $helper->currentIndex = $this->context->link->getAdminLink('AdminModules', false) . '&configure=' . $this->name . '&tab_module=' . $this->tab . '&module_name=' . $this->name; return $helper->generateList($criterions, $fields_list); } @@ -585,7 +585,7 @@ public function renderCommentsList() $helper->table = $this->name; $helper->table_id = 'approved-productcomments-list'; $helper->token = Tools::getAdminTokenLite('AdminModules'); - $helper->currentIndex = AdminController::$currentIndex . '&configure=' . $this->name; + $helper->currentIndex = $this->context->link->getAdminLink('AdminModules', false) . '&configure=' . $this->name . '&tab_module=' . $this->tab . '&module_name=' . $this->name; $helper->no_link = true; $page = ($page = Tools::getValue('submitFilter' . $helper->list_id)) ? (int) $page : 1; From 2fd6638a60e425e6f0657b00f4aeef554be33dbc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Hlav=C3=A1=C4=8Dek?= Date: Wed, 29 Oct 2025 16:44:52 +0100 Subject: [PATCH 2/4] Update productcomments.php --- productcomments.php | 24 ++++++++++++++++++++---- 1 file changed, 20 insertions(+), 4 deletions(-) diff --git a/productcomments.php b/productcomments.php index 403a16e..1bebe72 100644 --- a/productcomments.php +++ b/productcomments.php @@ -455,7 +455,11 @@ public function renderModerateLists() $helper->table = $this->name; $helper->table_id = 'waiting-approval-productcomments-list'; $helper->token = Tools::getAdminTokenLite('AdminModules'); - $helper->currentIndex = $this->context->link->getAdminLink('AdminModules', false) . '&configure=' . $this->name . '&tab_module=' . $this->tab . '&module_name=' . $this->name; + $helper->currentIndex = $this->context->link->getAdminLink('AdminModules', false, [], [ + 'configure' => $this->name, + 'tab_module' => $this->tab, + 'module_name' => $this->name, + ]); $helper->no_link = true; $return .= $helper->generateList($comments, $fields_list); @@ -480,7 +484,11 @@ public function renderModerateLists() $helper->table = $this->name; $helper->table_id = 'reported-productcomments-list'; $helper->token = Tools::getAdminTokenLite('AdminModules'); - $helper->currentIndex = $this->context->link->getAdminLink('AdminModules', false) . '&configure=' . $this->name . '&tab_module=' . $this->tab . '&module_name=' . $this->name; + $helper->currentIndex = $this->context->link->getAdminLink('AdminModules', false, [], [ + 'configure' => $this->name, + 'tab_module' => $this->tab, + 'module_name' => $this->name, + ]); $helper->no_link = true; $return .= $helper->generateList($comments, $fields_list); @@ -564,7 +572,11 @@ public function renderCriterionList() $helper->title = $this->trans('Review Criteria', [], 'Modules.Productcomments.Admin'); $helper->table = $this->name . 'criterion'; $helper->token = Tools::getAdminTokenLite('AdminModules'); - $helper->currentIndex = $this->context->link->getAdminLink('AdminModules', false) . '&configure=' . $this->name . '&tab_module=' . $this->tab . '&module_name=' . $this->name; + $helper->currentIndex = $this->context->link->getAdminLink('AdminModules', false, [], [ + 'configure' => $this->name, + 'tab_module' => $this->tab, + 'module_name' => $this->name, + ]); return $helper->generateList($criterions, $fields_list); } @@ -585,7 +597,11 @@ public function renderCommentsList() $helper->table = $this->name; $helper->table_id = 'approved-productcomments-list'; $helper->token = Tools::getAdminTokenLite('AdminModules'); - $helper->currentIndex = $this->context->link->getAdminLink('AdminModules', false) . '&configure=' . $this->name . '&tab_module=' . $this->tab . '&module_name=' . $this->name; + $helper->currentIndex = $this->context->link->getAdminLink('AdminModules', false, [], [ + 'configure' => $this->name, + 'tab_module' => $this->tab, + 'module_name' => $this->name, + ]); $helper->no_link = true; $page = ($page = Tools::getValue('submitFilter' . $helper->list_id)) ? (int) $page : 1; From 902e2fac40beb7a85900981178c9be05abc0e759 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Hlav=C3=A1=C4=8Dek?= Date: Wed, 29 Oct 2025 17:46:25 +0100 Subject: [PATCH 3/4] Update productcomments.php --- productcomments.php | 24 ++++-------------------- 1 file changed, 4 insertions(+), 20 deletions(-) diff --git a/productcomments.php b/productcomments.php index 1bebe72..64ae2d6 100644 --- a/productcomments.php +++ b/productcomments.php @@ -455,11 +455,7 @@ public function renderModerateLists() $helper->table = $this->name; $helper->table_id = 'waiting-approval-productcomments-list'; $helper->token = Tools::getAdminTokenLite('AdminModules'); - $helper->currentIndex = $this->context->link->getAdminLink('AdminModules', false, [], [ - 'configure' => $this->name, - 'tab_module' => $this->tab, - 'module_name' => $this->name, - ]); + $helper->currentIndex = $this->context->link->getAdminLink('AdminModules', false, [], ['configure' => $this->name, 'tab_module' => $this->tab, 'module_name' => $this->name]); $helper->no_link = true; $return .= $helper->generateList($comments, $fields_list); @@ -484,11 +480,7 @@ public function renderModerateLists() $helper->table = $this->name; $helper->table_id = 'reported-productcomments-list'; $helper->token = Tools::getAdminTokenLite('AdminModules'); - $helper->currentIndex = $this->context->link->getAdminLink('AdminModules', false, [], [ - 'configure' => $this->name, - 'tab_module' => $this->tab, - 'module_name' => $this->name, - ]); + $helper->currentIndex = $this->context->link->getAdminLink('AdminModules', false, [], ['configure' => $this->name, 'tab_module' => $this->tab, 'module_name' => $this->name]); $helper->no_link = true; $return .= $helper->generateList($comments, $fields_list); @@ -572,11 +564,7 @@ public function renderCriterionList() $helper->title = $this->trans('Review Criteria', [], 'Modules.Productcomments.Admin'); $helper->table = $this->name . 'criterion'; $helper->token = Tools::getAdminTokenLite('AdminModules'); - $helper->currentIndex = $this->context->link->getAdminLink('AdminModules', false, [], [ - 'configure' => $this->name, - 'tab_module' => $this->tab, - 'module_name' => $this->name, - ]); + $helper->currentIndex = $this->context->link->getAdminLink('AdminModules', false, [], ['configure' => $this->name, 'tab_module' => $this->tab, 'module_name' => $this->name]); return $helper->generateList($criterions, $fields_list); } @@ -597,11 +585,7 @@ public function renderCommentsList() $helper->table = $this->name; $helper->table_id = 'approved-productcomments-list'; $helper->token = Tools::getAdminTokenLite('AdminModules'); - $helper->currentIndex = $this->context->link->getAdminLink('AdminModules', false, [], [ - 'configure' => $this->name, - 'tab_module' => $this->tab, - 'module_name' => $this->name, - ]); + $helper->currentIndex = $this->context->link->getAdminLink('AdminModules', false, [], ['configure' => $this->name, 'tab_module' => $this->tab, 'module_name' => $this->name]); $helper->no_link = true; $page = ($page = Tools::getValue('submitFilter' . $helper->list_id)) ? (int) $page : 1; From 7ed9f9e139a55139a831e39d02702cfd17ce957f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Daniel=20Hlav=C3=A1=C4=8Dek?= Date: Fri, 31 Oct 2025 11:36:21 +0100 Subject: [PATCH 4/4] Update productcomments.php --- productcomments.php | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/productcomments.php b/productcomments.php index 64ae2d6..381f65c 100644 --- a/productcomments.php +++ b/productcomments.php @@ -455,7 +455,7 @@ public function renderModerateLists() $helper->table = $this->name; $helper->table_id = 'waiting-approval-productcomments-list'; $helper->token = Tools::getAdminTokenLite('AdminModules'); - $helper->currentIndex = $this->context->link->getAdminLink('AdminModules', false, [], ['configure' => $this->name, 'tab_module' => $this->tab, 'module_name' => $this->name]); + $helper->currentIndex = $this->context->link->getAdminLink('AdminModules', false, [], ['configure' => $this->name, 'tab_module' => $this->tab, 'module_name' => $this->name]); $helper->no_link = true; $return .= $helper->generateList($comments, $fields_list); @@ -480,7 +480,7 @@ public function renderModerateLists() $helper->table = $this->name; $helper->table_id = 'reported-productcomments-list'; $helper->token = Tools::getAdminTokenLite('AdminModules'); - $helper->currentIndex = $this->context->link->getAdminLink('AdminModules', false, [], ['configure' => $this->name, 'tab_module' => $this->tab, 'module_name' => $this->name]); + $helper->currentIndex = $this->context->link->getAdminLink('AdminModules', false, [], ['configure' => $this->name, 'tab_module' => $this->tab, 'module_name' => $this->name]); $helper->no_link = true; $return .= $helper->generateList($comments, $fields_list); @@ -564,7 +564,7 @@ public function renderCriterionList() $helper->title = $this->trans('Review Criteria', [], 'Modules.Productcomments.Admin'); $helper->table = $this->name . 'criterion'; $helper->token = Tools::getAdminTokenLite('AdminModules'); - $helper->currentIndex = $this->context->link->getAdminLink('AdminModules', false, [], ['configure' => $this->name, 'tab_module' => $this->tab, 'module_name' => $this->name]); + $helper->currentIndex = $this->context->link->getAdminLink('AdminModules', false, [], ['configure' => $this->name, 'tab_module' => $this->tab, 'module_name' => $this->name]); return $helper->generateList($criterions, $fields_list); } @@ -585,7 +585,7 @@ public function renderCommentsList() $helper->table = $this->name; $helper->table_id = 'approved-productcomments-list'; $helper->token = Tools::getAdminTokenLite('AdminModules'); - $helper->currentIndex = $this->context->link->getAdminLink('AdminModules', false, [], ['configure' => $this->name, 'tab_module' => $this->tab, 'module_name' => $this->name]); + $helper->currentIndex = $this->context->link->getAdminLink('AdminModules', false, [], ['configure' => $this->name, 'tab_module' => $this->tab, 'module_name' => $this->name]); $helper->no_link = true; $page = ($page = Tools::getValue('submitFilter' . $helper->list_id)) ? (int) $page : 1;