From 7dd59cf1f5c5452d31669ca196405ac77da3ab00 Mon Sep 17 00:00:00 2001 From: Antonio Gallo Date: Sun, 24 Jul 2011 17:06:13 +0000 Subject: added RSS - part 1 --- h-source/Application/Controllers/RssController.php | 41 ++++++++++++++++++++++ .../Application/Controllers/SpecialController.php | 2 +- 2 files changed, 42 insertions(+), 1 deletion(-) create mode 100644 h-source/Application/Controllers/RssController.php (limited to 'h-source/Application/Controllers') diff --git a/h-source/Application/Controllers/RssController.php b/h-source/Application/Controllers/RssController.php new file mode 100644 index 0000000..359c651 --- /dev/null +++ b/h-source/Application/Controllers/RssController.php @@ -0,0 +1,41 @@ +. + +if (!defined('EG')) die('Direct access not allowed!'); + +class RssController extends SpecialController +{ + + public function __construct($model, $controller, $queryString) + { + parent::__construct($model, $controller, $queryString); + + $data['title'] = 'RSS - '.Website::$generalName; + $this->append($data); + } + + public function modifications($lang = 'en') + { + parent::modifications($lang); + $this->clean(); + $this->load('modifications'); + } + +} \ No newline at end of file diff --git a/h-source/Application/Controllers/SpecialController.php b/h-source/Application/Controllers/SpecialController.php index 3776a18..480c0fa 100644 --- a/h-source/Application/Controllers/SpecialController.php +++ b/h-source/Application/Controllers/SpecialController.php @@ -110,7 +110,7 @@ class SpecialController extends BaseController $this->helper('Pages','special/'.$this->action.'/'.$this->lang,'page'); - $this->m['HistoryModel']->clear()->inner('hardware')->on('hardware.id_hard=history.id')->select()->where($whereClauseArray)->orderBy('id_history desc'); + $this->m['HistoryModel']->clear()->select('history.*,hardware.*')->inner('hardware')->on('hardware.id_hard=history.id')->where($whereClauseArray)->orderBy('id_history desc'); $recordNumber = $this->m['HistoryModel']->rowNumber(); $page = $this->viewArgs['page']; -- cgit v1.2.3