summaryrefslogtreecommitdiff
path: root/protected/modules/cms/controllers/SitecontentController.php
diff options
context:
space:
mode:
Diffstat (limited to 'protected/modules/cms/controllers/SitecontentController.php')
-rw-r--r--protected/modules/cms/controllers/SitecontentController.php4
1 files changed, 3 insertions, 1 deletions
diff --git a/protected/modules/cms/controllers/SitecontentController.php b/protected/modules/cms/controllers/SitecontentController.php
index e4f7a5f..43fb74b 100644
--- a/protected/modules/cms/controllers/SitecontentController.php
+++ b/protected/modules/cms/controllers/SitecontentController.php
@@ -42,8 +42,10 @@ class SitecontentController extends Controller
$model = $this->loadContent();
$this->breadcrumbs = array($model->title);
- if($model->id > 1) {
+ if($model->depth == 1) {
$this->menu = CMS::getMenuPoints($model->id);
+ } elseif ($model->depth == 2){
+ $this->menu = CMS::getMenuPoints($model->oparent->id);
}
$this->render('view', array(
'sitecontent' => $model,