Blame view

protected/controllers/WarrantyController.php 947 Bytes
a1684257   Administrator   first commit
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
  <?php
  
  class WarrantyController extends NodeSiteController
  {
      public function actionIndex()
      {
          /** @var $warrantyRoot WarrantyRoot */
          $warrantyRoot = WarrantyRoot::model()->with('i18n')->findByPk($this->getNode()->data_id);
          $this->pageName = $warrantyRoot->i18n->page_name;
          $this->setSEOParams($warrantyRoot->i18n->title, $warrantyRoot->i18n->keywords, $warrantyRoot->i18n->description);
          $this->setContacts(explode(',', $warrantyRoot->contacts_data));
          $certificates = GalleryPhoto::model()->with('i18n')->findAll(array('order' => 'rank asc', 'condition' => 'gallery_id=' . $warrantyRoot->certificate_gallery_id));
          $this->headerGalleryId = $warrantyRoot->header_gallery_id;
          $this->render('index', array(
              'content' => $warrantyRoot->i18n->content,
              'sidebar' => $warrantyRoot->i18n->sidebar,
              'certificates' => $certificates
          ));
      }
  }