public function afterSave() { $collectionsTemplate = (int) $this->getProperty('collections_template'); $config = $this->modx->getObject('CollectionSetting', array('collection' => $this->object->id)); if (!$config) { $config = $this->modx->newObject('CollectionSetting'); $config->set('collection', $this->object->id); } $config->set('template', $collectionsTemplate); $config->save(); return parent::afterSave(); }
public function afterSave() { $this->setProperty('clearCache', true); return parent::afterSave(); }
public function afterSave() { $afterSave = parent::afterSave(); if ($this->isPublishing) { $this->object->notifyUpdateServices(); $this->object->sendNotifications(); } $this->clearContainerCache(); return $afterSave; }
/** * Override modResourceUpdateProcessor::afterSave to provide custom functionality * {@inheritDoc} * @return boolean */ public function afterSave() { $this->addContainerId(); $this->removeFromArchivistIds(); $this->setProperty('clearCache', true); $this->object->set('isfolder', true); return parent::afterSave(); }
/** * Override modResourceCreateProcessor::afterSave to provide custom functionality, saving the container settings to a * custom field in the manager * {@inheritDoc} * @return boolean */ public function afterSave() { //$this->modx->log(1, __FILE__ . print_r($this->object->toArray(), true)); $this->object->set('class_key', 'Store'); $this->object->set('cacheable', true); $this->object->set('isfolder', true); // ensure we get a clean uri return parent::afterSave(); }
/** * @return bool */ public function afterSave() { $parent = parent::afterSave(); if ($this->_sendEmails && $this->modx->context->key == 'mgr') { $this->sendTicketMails(); } return $parent; }