예제 #1
0
 public function beforeSave()
 {
     $isStatic = intval($this->getProperty('static', 0));
     if ($isStatic == 1) {
         $staticFile = $this->getProperty('static_file');
         if (empty($staticFile)) {
             $this->addFieldError('static_file', $this->modx->lexicon('static_file_ns'));
         }
     }
     return parent::beforeSave();
 }
예제 #2
0
 public function afterSave()
 {
     $this->saveEvents();
     return parent::afterSave();
 }
예제 #3
0
 public function afterSave()
 {
     $this->saveTemplateVariables();
     return parent::afterSave();
 }
예제 #4
0
 /**
  * Add post-saving options to TVs
  * 
  * {@inheritDoc}
  * @return boolean
  */
 public function afterSave()
 {
     $this->setTemplateAccess();
     $this->setResourceGroupAccess();
     $this->setMediaSources();
     return parent::afterSave();
 }