예제 #1
0
파일: Redirect.php 프로젝트: nja78/magento2
 /**
  * {@inheritdoc}
  *
  * @param array $arguments
  * @return array
  */
 public function updatePathParams(array $arguments)
 {
     if ($this->_session->getCookieShouldBeReceived() && $this->_sidResolver->getUseSessionInUrl() && $this->_canUseSessionIdInParam) {
         $arguments += ['_query' => [$this->_sidResolver->getSessionIdQueryParam($this->_session) => $this->_session->getSessionId()]];
     }
     return $arguments;
 }
예제 #2
0
 /**
  * Set redirect into response
  *
  * @param \Magento\Framework\App\ResponseInterface $response
  * @param string $path
  * @param array $arguments
  * @return void
  */
 public function redirect(\Magento\Framework\App\ResponseInterface $response, $path, $arguments = array())
 {
     if ($this->_session->getCookieShouldBeReceived() && $this->_urlBuilder->getUseSession() && $this->_canUseSessionIdInParam) {
         $arguments += array('_query' => array($this->_sidResolver->getSessionIdQueryParam($this->_session) => $this->_session->getSessionId()));
     }
     $response->setRedirect($this->_urlBuilder->getUrl($path, $arguments));
 }