Esempio n. 1
0
 /** {@inheritDoc} */
 public function initialize()
 {
     if (!$this->modx->hasPermission($this->permission)) {
         return $this->modx->lexicon('access_denied');
     }
     return parent::initialize();
 }
 public function initialize()
 {
     if (!($restore = $this->modx->msrevaluation->restoreProcess($this->getProperty('id')))) {
         $this->failure($this->modx->msrevaluation->error);
     }
     return parent::initialize();
 }
Esempio n. 3
0
 /**
  * @return bool|null|string
  */
 public function initialize()
 {
     $parent = parent::initialize();
     if ($this->checkRemovePermission && !$this->modx->hasPermission($this->permission)) {
         return $this->modx->lexicon('access_denied');
     }
     return $parent;
 }
Esempio n. 4
0
 public function initialize()
 {
     if (!($id = (int) $this->getProperty('order_id'))) {
         return 'Не был получен ID заявки';
     }
     $this->setProperty('id', $id);
     return parent::initialize();
 }
Esempio n. 5
0
 /** {@inheritDoc} */
 public function initialize()
 {
     if (!$this->modx->hasPermission($this->permission)) {
         return $this->modx->lexicon('access_denied');
     }
     /** @var mlmsystem $mlmsystem */
     $this->MlmSystem = $this->modx->getService('mlmsystem');
     $this->MlmSystem->initialize($this->getProperty('context', $this->modx->context->key));
     return parent::initialize();
 }
Esempio n. 6
0
 /** {@inheritDoc} */
 public function initialize()
 {
     if (!$this->modx->hasPermission($this->permission)) {
         return $this->modx->lexicon('access_denied');
     }
     if ($event = $this->modx->getObject('vpEvent', array('id' => $this->getProperty('event')))) {
         $this->eventName = $event->get('name');
     }
     return parent::initialize();
 }
Esempio n. 7
0
 public function initialize()
 {
     if (!$this->modx->hasPermission('delete_comments')) {
         return 'Access denied';
     }
     if (!($comment_id = (int) $this->getProperty('comment_id'))) {
         return 'Не был получен ID комментария';
     }
     $this->setProperty('id', $comment_id);
     return parent::initialize();
 }