diff options
author | Bharat Mediratta <bharat@menalto.com> | 2008-11-06 04:56:50 +0000 |
---|---|---|
committer | Bharat Mediratta <bharat@menalto.com> | 2008-11-06 04:56:50 +0000 |
commit | d6e942f2e37fc2e6539ddabba62faac06df59c08 (patch) | |
tree | 86938f987129826d7db4a0b8a460f758795a6471 /core/controllers/welcome.php | |
parent | 3fe8cd7135577499a9319da4a71467ba56ad46b4 (diff) |
Add quick-link to the deepest photo to test hierarchical navigation
Diffstat (limited to 'core/controllers/welcome.php')
-rw-r--r-- | core/controllers/welcome.php | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/core/controllers/welcome.php b/core/controllers/welcome.php index a311a218..7509dc89 100644 --- a/core/controllers/welcome.php +++ b/core/controllers/welcome.php @@ -26,11 +26,14 @@ class Welcome_Controller extends Template_Controller { $this->template->syscheck->modules = array(); $this->template->album_count = 0; $this->template->photo_count = 0; + $this->template->deepest_photo = null; try { $old_handler = set_error_handler(array("Welcome_Controller", "_error_handler")); $this->template->syscheck->modules = $this->_read_modules(); $this->template->album_count = ORM::factory("item")->where("type", "album")->count_all(); $this->template->photo_count = ORM::factory("item")->where("type", "photo")->count_all(); + $this->template->deepest_photo = ORM::factory("item") + ->where("type", "photo")->orderby("level", "desc")->find(); } catch (Exception $e) { } set_error_handler($old_handler); |