Пример #1
0
 function getIdValue()
 {
     if (isset($_REQUEST[$this->id_field]) && $_REQUEST[$this->id_field]) {
         return $_REQUEST[$this->id_field];
     }
     return parent::getIdValue();
 }
Пример #2
0
 function __wakeup()
 {
     if (isset($this->_positionList)) {
         $this->_positionList->execute();
     }
     parent::__wakeup();
 }
Пример #3
0
 function _selectAddNull($valueset, $fieldname)
 {
     if ($fieldname != 'target') {
         return parent::_selectAddNull($valueset, $fieldname);
     }
     return $valueset;
 }
Пример #4
0
 function _selectAddNull($valueset, $name)
 {
     $required_selects = array('root_section_id');
     if (array_search($name, $required_selects) === FALSE) {
         return parent::_selectAddNull($valueset, $name);
     }
     return array(AMP_CONTENT_SECTION_ID_ROOT => '-- ' . AMP_SITE_NAME . ' --') + $valueset;
 }
Пример #5
0
 function validate()
 {
     $section_id = isset($_REQUEST['type']) && $_REQUEST['type'] ? $_REQUEST['type'] : false;
     if ($section_id && !AMP_allow('access', 'section', $section_id)) {
         $flash = AMP_System_Flash::instance();
         $flash->add_error(sprintf(AMP_TEXT_ERROR_ACTION_NOT_ALLOWED, AMP_TEXT_SAVE));
         return false;
     }
     return parent::validate();
 }
Пример #6
0
 function _selectAddNull($valueset, $name)
 {
     if ($name != 'parent') {
         return parent::_selectAddNull($valueset, $name);
     }
     $current_gallery_id = isset($_REQUEST['id']) && $_REQUEST['id'] ? $_REQUEST['id'] : false;
     if ($current_gallery_id) {
         unset($valueset[$current_gallery_id]);
     }
     return parent::_selectAddNull($valueset, $name);
 }
Пример #7
0
 function _blankValueSet($value_set, $name)
 {
     if ($name == 'modin') {
         return array('' => 'Create new quiz');
     }
     return parent::_blankValueSet($value_set, $name);
 }
Пример #8
0
 function output()
 {
     $this->verifyOwnedItem();
     return parent::output();
 }
Пример #9
0
 function validate()
 {
     $base = parent::validate();
     return $base && $this->is_article_commentable();
 }
Пример #10
0
 function output()
 {
     $this->registerJavascript($this->swapper->output());
     $this->setJavascript();
     return parent::output();
 }