From f307badac4a09c70deb82571efb0f6e235238274 Mon Sep 17 00:00:00 2001 From: Gustavo Martin Morcuende Date: Tue, 15 May 2012 19:36:37 +0200 Subject: [PATCH] Chosen language and ads list web page. Use the chosen language when making click on the pager links. The current language must keep being the chosen one by the user. --- apps/companyfront/modules/ad/actions/actions.class.php | 3 +++ apps/companyfront/modules/ad/templates/indexSuccess.php | 10 +++++----- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/apps/companyfront/modules/ad/actions/actions.class.php b/apps/companyfront/modules/ad/actions/actions.class.php index 869ea1b..8e78acd 100644 --- a/apps/companyfront/modules/ad/actions/actions.class.php +++ b/apps/companyfront/modules/ad/actions/actions.class.php @@ -49,6 +49,9 @@ class adActions extends sfActions $this->pager->setQuery($query); $this->pager->setPage($request->getParameter('page', 1)); $this->pager->init(); + + + $this->languageCode = $language->getCode(); } public function executeShow(sfWebRequest $request) diff --git a/apps/companyfront/modules/ad/templates/indexSuccess.php b/apps/companyfront/modules/ad/templates/indexSuccess.php index 04d0d0c..48948e2 100644 --- a/apps/companyfront/modules/ad/templates/indexSuccess.php +++ b/apps/companyfront/modules/ad/templates/indexSuccess.php @@ -16,21 +16,21 @@ haveToPaginate()): ?> -- 2.1.4