Ejemplo n.º 1
0
 /**
  * @Route("/customer/{id}", name="orocrm_magento_widget_customer_orderplace", requirements={"id"="\d+"}))
  * @AclAncestor("oro_workflow")
  * @Template("OroCRMMagentoBundle:OrderPlace:place.html.twig")
  */
 public function customerAction(Customer $customer)
 {
     $urlGenerator = $this->get('orocrm_magento.service.magento_url_generator')->setChannel($customer->getChannel())->setFlowName('oro_sales_new_order')->setOrigin('customer')->generate($customer->getOriginId(), 'orocrm_magento_orderplace_success', 'orocrm_magento_orderplace_error');
     $translator = $this->get('translator');
     return ['error' => $urlGenerator->isError() ? $translator->trans($urlGenerator->getError()) : false, 'sourceUrl' => $urlGenerator->getSourceUrl(), 'customerId' => $customer->getid()];
 }
Ejemplo n.º 2
0
 protected function getMainEntityId()
 {
     return self::$customer->getid();
 }
Ejemplo n.º 3
0
 protected function getCustomerId()
 {
     return $this->customer->getid();
 }