コード例 #1
0
 /**
  * @param mixed $context
  */
 protected function executeAction($context)
 {
     $settingsClass = $this->contextAccessor->getValue($context, $this->processType);
     $settingsClass = $this->processStorage->getProcess($settingsClass)->getSettingsEntityFQCN();
     $email = $this->contextAccessor->getValue($context, $this->email);
     $results = $this->doctrine->getRepository('OroEmailBundle:Mailbox')->findBySettingsClassAndEmail($settingsClass, $email);
     $this->contextAccessor->setValue($context, $this->attribute, $results);
 }
コード例 #2
0
ファイル: MailboxType.php プロジェクト: antrampa/platform
 /**
  * Adds mailbox process form field of proper type
  *
  * @param FormInterface $form
  * @param string|null   $processType
  */
 protected function addProcessField(FormInterface $form, $processType)
 {
     if (!empty($processType)) {
         $process = $this->storage->getProcess($processType);
         if ($process->isEnabled()) {
             $form->add('processSettings', $this->storage->getProcess($processType)->getSettingsFormType(), ['required' => true]);
             return;
         }
     }
     $form->add('processSettings', 'hidden', ['data' => null]);
 }
コード例 #3
0
ファイル: EmailExtension.php プロジェクト: hugeval/platform
 /**
  * @param string $type
  *
  * @return string
  */
 public function getMailboxProcessLabel($type)
 {
     return $this->mailboxProcessStorage->getProcess($type)->getLabel();
 }