diff --git a/backend/Controllers/ProductAdmin.php b/backend/Controllers/ProductAdmin.php index 985403e2..3c33dc4c 100644 --- a/backend/Controllers/ProductAdmin.php +++ b/backend/Controllers/ProductAdmin.php @@ -96,7 +96,12 @@ public function fetch( // сохранить и выход в список $buttonRedirectToList = $this->request->post('apply_and_quit', 'integer', 0); - if (($buttonRedirectToList == 1) && !empty($urlRedirectToList = $this->request->getRootUrl() . '/backend/index.php?controller=ProductsAdmin')) { + if ($buttonRedirectToList == 1) { + $urlRedirectToList = htmlspecialchars_decode($this->request->getRootUrl() . urldecode($this->request->get( + 'return', + null, + '/backend/index.php?controller=ProductsAdmin' + ))); $this->postRedirectGet->redirect($urlRedirectToList); }