From: Gustavo Martin Morcuende Date: Sun, 20 May 2012 15:49:12 +0000 (+0200) Subject: Remove pager from Company Category index list. X-Git-Url: https://git.gumartinm.name/?a=commitdiff_plain;h=7b765baebd15932a8cada71e7e723bca52e35d73;p=mobi%2F.git Remove pager from Company Category index list. I am going to use just the Tree with the categories. --- diff --git a/apps/companyfront/modules/category/actions/actions.class.php b/apps/companyfront/modules/category/actions/actions.class.php index e144889..b27e802 100644 --- a/apps/companyfront/modules/category/actions/actions.class.php +++ b/apps/companyfront/modules/category/actions/actions.class.php @@ -18,13 +18,10 @@ class categoryActions extends sfActions //Just 1 user owns a company. Should this be improved? $companyId = CompanyTable::getInstance()->findOneByUserId($userId)->getId(); - //Doctrine Query used to show a pager with the Company Categories. + //Doctrine Query used to show a list with the Company Categories. $query=CompanyCategoryTable::getInstance()->getCompanyCategoriesByCompanyIdQuery($companyId); - $this->pager = new sfDoctrinePager('CompanyCategoryDescription', sfConfig::get('app_max_categories_on_pager')); - $this->pager->setQuery($query); - $this->pager->setPage($request->getParameter('page', 1)); - $this->pager->init(); + $this->companyCategories = $query->execute(); } public function executeShow(sfWebRequest $request) diff --git a/apps/companyfront/modules/category/templates/indexSuccess.php b/apps/companyfront/modules/category/templates/indexSuccess.php index e9c8e90..d86021c 100644 --- a/apps/companyfront/modules/category/templates/indexSuccess.php +++ b/apps/companyfront/modules/category/templates/indexSuccess.php @@ -1,25 +1,5 @@

- $pager->getResults())) ?> + $companyCategories)) ?> -haveToPaginate()): ?> - - - -Create new Category +