Beispiel #1
0
 /**
  * Restore form id
  *
  * @return string
  */
 public function restoreFormId()
 {
     $request = \XLite\Core\Request::getInstance();
     if (!empty($request->{\XLite::FORM_ID})) {
         $this->session = \XLite\Core\Database::getEM()->merge($this->session);
         $formId = new \XLite\Model\FormId();
         $formId->setFormId($request->{\XLite::FORM_ID});
         $formId->setSession($this->session);
         $this->session->addFormIds($formId);
         \XLite\Core\Database::getEM()->persist($formId);
         \XLite\Core\Database::getEM()->flush($formId);
         $this->lastFormId = $formId->getFormId();
     }
     return $this->lastFormId;
 }
 /**
  * {@inheritDoc}
  */
 public function addFormIds(\XLite\Model\FormId $formIds)
 {
     $this->__initializer__ && $this->__initializer__->__invoke($this, 'addFormIds', array($formIds));
     return parent::addFormIds($formIds);
 }