Пример #1
0
 public function getTemplateVars()
 {
     $ret = parent::getTemplateVars();
     $ret['options'] = $this->_getSetting('mapOptions');
     if ($this->_getSearchForm()) {
         if (!Kwc_Abstract::getSetting($this->_getSearchForm()->componentClass, 'useAjaxRequest')) {
             throw new Kwf_Exception_NotYetImplemented();
         }
         $ret['options']['searchFormComponentId'] = $this->_getSearchForm()->componentId;
     }
     $ret['options']['baseParams']['componentId'] = $this->getData()->componentId;
     $ret['options']['markers'] = Kwc_Admin::getInstance($this->getData()->componentClass)->getControllerUrl('Markers') . '/json-index';
     return $ret;
 }
Пример #2
0
 public function getTemplateVars()
 {
     $ret = parent::getTemplateVars();
     $cfg = Kwf_Component_Abstract_ExtConfig_Abstract::getInstance($this->getData()->componentClass);
     $ret['config'] = array('controllerUrl' => $cfg->getControllerUrl('View'), 'viewUrl' => $this->getData()->url, 'componentId' => $this->getData()->componentId, 'searchFormComponentId' => $this->_getSearchForm() ? $this->_getSearchForm()->componentId : null, 'placeholder' => array('noEntriesFound' => $this->_getPlaceholder('noEntriesFound')), 'loadMoreBufferPx' => $this->_getSetting('loadMoreBufferPx'), 'loadDetailAjax' => $this->_getSetting('loadDetailAjax'));
     $itemDir = $this->getData()->parent->getComponent()->getItemDirectory();
     if (is_string($itemDir)) {
         $ret['config']['directoryViewComponentId'] = false;
         $ret['config']['directoryComponentId'] = false;
         $ret['config']['directoryComponentClass'] = $itemDir;
     } else {
         $ret['config']['directoryViewComponentId'] = $itemDir->getChildComponent('-view')->componentId;
         $ret['config']['directoryComponentId'] = $itemDir->componentId;
         $ret['config']['directoryComponentClass'] = $itemDir->componentClass;
     }
     $paging = $this->getData()->getChildComponent('-paging');
     if (isset($paging)) {
         $ret['config']['initialPageSize'] = Kwc_Abstract::getSetting($paging->componentClass, 'pagesize');
     }
     return $ret;
 }
Пример #3
0
 public function getTemplateVars(Kwf_Component_Renderer_Abstract $renderer)
 {
     $ret = parent::getTemplateVars($renderer);
     $ret['items'] = $this->_getItems();
     return $ret;
 }
Пример #4
0
class Kwc_Directories_List_View_ComponentNonPartial extends Kwc_Directories_List_View_Component
{
    public function getTemplateVars()
    {
        $ret = parent::getTemplateVars();
        $ret['items'] = $this->_getItems();