Пример #1
0
 /**
  * Set all forms.
  */
 public function initialize()
 {
     parent::initialize();
     if (!isset($this->view->forms)) {
         $this->view->activeForm = 'General';
         $this->view->forms = array('General' => new SettingsGeneralForm($this->config), 'Dashboard' => new SettingsDashboardForm($this->config));
         //$this->view->formUsers = new SettingsUsersForm(Users::Find());
         $this->view->formDevices = new SettingsDevicesForm(Devices::Find());
         $this->view->formMenu = new SettingsMenuItemsForm(MenuItems::Find(array('order' => 'name')));
         $this->view->formNewMenuItem = new SettingsMenuItemsNewForm();
         $this->view->formNewDevice = new SettingsDevicesNewForm();
     }
 }