예제 #1
0
 /**
  * @param ScrollData $scrollData
  * @param string     $html
  */
 protected function addCategoryBlock(ScrollData $scrollData, $html)
 {
     $blockLabel = $this->translator->trans('orob2b.catalog.product.section.catalog');
     $blockId = $scrollData->addBlock($blockLabel);
     $subBlockId = $scrollData->addSubBlock($blockId);
     $scrollData->addSubBlockData($blockId, $subBlockId, $html);
 }
 /**
  * @param ScrollData $scrollData
  * @param string $html
  */
 protected function addShoppingListBlock(ScrollData $scrollData, $html)
 {
     $blockLabel = $this->translator->trans('orob2b.shoppinglist.product.add_to_shopping_list.label');
     $blockId = $scrollData->addBlock($blockLabel);
     $subBlockId = $scrollData->addSubBlock($blockId);
     $scrollData->addSubBlockData($blockId, $subBlockId, $html);
 }
예제 #3
0
 /**
  * @param ScrollData $scrollData
  * @param string $html
  */
 protected function addProductPricesBlock(ScrollData $scrollData, $html)
 {
     $blockLabel = $this->translator->trans('orob2b.pricing.productprice.entity_plural_label');
     $blockId = $scrollData->addBlock($blockLabel);
     $subBlockId = $scrollData->addSubBlock($blockId);
     $scrollData->addSubBlockData($blockId, $subBlockId, $html);
 }
 /**
  * @param ScrollData $scrollData
  * @param string $html
  */
 protected function addSalesOrdersBlock(ScrollData $scrollData, $html)
 {
     $blockLabel = $this->translator->trans('orob2b.order.sales_orders.label');
     $blockId = $scrollData->addBlock($blockLabel);
     $subBlockId = $scrollData->addSubBlock($blockId);
     $scrollData->addSubBlockData($blockId, $subBlockId, $html);
 }
예제 #5
0
 /**
  * @expectedException \LogicException
  * @expectedExceptionMessage Block 0 is not defined
  */
 public function testAddSubBlockException()
 {
     $this->scrollData->setData([ScrollData::DATA_BLOCKS => []]);
     $this->scrollData->addSubBlock(0);
 }