public function setModel($model) { parent::setModel($model); if ($this->_cards) { foreach ($this->_cards as $c) { $c->getIterator()->current()->setModel($model); } } }
protected function _initFields() { parent::_initFields(); $this->add(new Kwf_Form_Field_TextField('title', trlKwf('Title')))->setAllowBlank(false)->setWidth(300); $this->add(new Kwf_Form_Field_TextArea('teaser', trlKwf('Teaser')))->setWidth(300)->setHeight(100); $this->add(new Kwf_Form_Field_DateField('publish_date', trlKwf('Publish Date')))->setAllowBlank(false); if (Kwc_Abstract::getSetting($this->getDirectoryClass(), 'enableExpireDate')) { $this->add(new Kwf_Form_Field_DateField('expiry_date', trlKwf('Expiry Date'))); } }
protected function _createChildComponentForm($id, $name = null) { $ret = parent::_createChildComponentForm($id, $name); $ret->setIdTemplate('{0}' . $id); return $ret; }
protected function _initFields() { parent::_initFields(); $this->add(new Kwf_Form_Field_TextField('title', trlKwf('Title')))->setAllowBlank(false)->setWidth(300); $this->add(new Kwf_Form_Field_DateField('publish_date', trlKwf('Publish Date')))->setAllowBlank(false); }