/** * @copydoc Grid::main */ protected function main() { if (!$this->formID) { $this->returnEmptyRecordset(); } else { parent::main(); } }
/** * @copydoc Grid::main */ protected function main() { parent::main(); $params = $this->getStateParams(true); if (!empty($params['tag_id'])) { $this->setProperty('tag_id', urldecode($params['tag_id'])); $tag_ids = explode(TagManager::TAG_SEPARATOR, $params['tag_id']); if ($tag_ids) { $this->addFilterCondition(array(TagManager::TAG_TABLENAME . '.tag_id' => $tag_ids)); } } }
protected function main() { parent::main(); if ($f = $this->getDataDescription()->getFieldDescriptionByName('u_id')) { $f->setType(FieldDescription::FIELD_TYPE_STRING); } if ($f = $this->getDataDescription()->getFieldDescriptionByName('target_id')) { $f->setType(FieldDescription::FIELD_TYPE_STRING); } foreach ($this->commentTables as $i => $table) { //пропускаем текущую таблицу - для неё уже создана нулевая вкладка // посути $this->currTabIndex может быть равен только нулю if ($i == $this->currTabIndex) { continue; } $fd = new FieldDescription($table . '_edit'); $fd->setType(FieldDescription::FIELD_TYPE_HIDDEN); $fd->setProperty('tabName', 'TAB_' . $table); $this->getDataDescription()->addFieldDescription($fd); } }
protected function main() { parent::main(); $params = $this->getStateParams(true); if ($params) { $siteID = $params['site_id']; } else { $siteID = E()->getSiteManager()->getCurrentSite()->id; } $this->setProperty('site', $siteID); $this->setFilter(['site_id' => $siteID]); $this->addTranslation('TXT_DIVISIONS'); }
/** * @copydoc Grid::main */ protected function main() { Grid::main(); }