public function preDispatch()
 {
     $this->setModel(new Kwc_Directories_Item_Directory_Trl_AdminModel(array('proxyModel' => Kwc_Abstract::createChildModel(Kwc_Abstract::getSetting($this->_getParam('class'), 'masterComponentClass')), 'trlModel' => Kwc_Abstract::createChildModel($this->_getParam('class')))));
     parent::preDispatch();
     $url = Kwc_Admin::getInstance($this->_getParam('class'))->getControllerUrl('Form');
     $this->_editDialog['controllerUrl'] = $url;
 }
 public function preDispatch()
 {
     parent::preDispatch();
     $this->_components = array();
     foreach (Kwc_Abstract::getChildComponentClasses($this->_getParam('class'), 'paragraphs') as $c) {
         if (Kwc_Abstract::hasSetting($c, 'componentName')) {
             $name = Kwc_Abstract::getSetting($c, 'componentName');
             if ($name) {
                 $this->_components[$name] = $c;
             }
         }
     }
 }
 public function preDispatch()
 {
     parent::preDispatch();
     if (is_instance_of(Kwc_Abstract::getSetting($this->_getParam('class'), 'extConfig'), 'Kwc_Directories_Item_Directory_ExtConfigEditButtons') || is_instance_of(Kwc_Abstract::getSetting($this->_getParam('class'), 'extConfigControllerIndex'), 'Kwc_Directories_Item_Directory_ExtConfigEditButtons')) {
         $url = Kwc_Admin::getInstance($this->_getParam('class'))->getControllerUrl('Form');
         $editDialog = array('autoForm' => 'Kwc.Directories.Item.Directory.EditFormPanel', 'controllerUrl' => $url);
         if (!empty($this->_editDialog['width'])) {
             $editDialog['width'] = $this->_editDialog['width'];
         }
         if (!empty($this->_editDialog['height'])) {
             $editDialog['height'] = $this->_editDialog['height'];
         }
         $this->_editDialog = $editDialog;
     }
     if ($this->_columns[0] instanceof Kwf_Grid_Column_Button) {
         throw new Kwf_Exception("Override Controller and add at least one column (button must not be first)");
     }
     if ($this->_columns[0] instanceof Kwf_Grid_Column && $this->_columns[0]->getName() == 'component_class') {
         throw new Kwf_Exception("Override Controller and add at least one column (component_class must not be first)");
     }
 }
 public function preDispatch()
 {
     parent::preDispatch();
     $this->_getModel()->setComponentId($this->_getParam('componentId'));
 }
Exemple #5
0
 public function preDispatch()
 {
     $masterComponentClass = Kwc_Abstract::getSetting($this->_getParam('class'), 'masterComponentClass');
     $this->setModel(Kwc_Columns_ModelFactory::getModelInstance(array('componentClass' => $masterComponentClass)));
     parent::preDispatch();
 }
 public function preDispatch()
 {
     $this->setModel($this->_getComponent()->getComponent()->getChildModel());
     parent::preDispatch();
 }