-
Notifications
You must be signed in to change notification settings - Fork 9.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'develop' of https://github.corp.ebay.com/magento2/magen…
…to2ce into develop
- Loading branch information
Showing
281 changed files
with
12,290 additions
and
6,255 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
<?php | ||
/** | ||
* Copyright © 2015 Magento. All rights reserved. | ||
* See COPYING.txt for license details. | ||
*/ | ||
namespace Magento\Bundle\Observer; | ||
|
||
class InitOptionRenderer | ||
{ | ||
/** | ||
* Initialize product options renderer with bundle specific params | ||
* | ||
* @param \Magento\Framework\Event\Observer $observer | ||
* @return $this | ||
*/ | ||
public function invoke(\Magento\Framework\Event\Observer $observer) | ||
{ | ||
$block = $observer->getBlock(); | ||
$block->addOptionsRenderCfg('bundle', 'Magento\Bundle\Helper\Catalog\Product\Configuration'); | ||
return $this; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
<?php | ||
/** | ||
* Copyright © 2015 Magento. All rights reserved. | ||
* See COPYING.txt for license details. | ||
*/ | ||
namespace Magento\Bundle\Observer; | ||
|
||
class LoadProductOptions | ||
{ | ||
/** | ||
* Add price index data for catalog product collection | ||
* only for front end | ||
* | ||
* @param \Magento\Framework\Event\Observer $observer | ||
* @return $this | ||
*/ | ||
public function invoke($observer) | ||
{ | ||
$collection = $observer->getEvent()->getCollection(); | ||
/* @var $collection \Magento\Catalog\Model\Resource\Product\Collection */ | ||
$collection->addPriceData(); | ||
|
||
return $this; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
<?php | ||
/** | ||
* Copyright © 2015 Magento. All rights reserved. | ||
* See COPYING.txt for license details. | ||
*/ | ||
namespace Magento\Bundle\Observer; | ||
|
||
class SetAttributeTabBlock | ||
{ | ||
/** | ||
* Catalog helper | ||
* | ||
* @var \Magento\Catalog\Helper\Catalog | ||
*/ | ||
protected $helperCatalog; | ||
|
||
/** | ||
* @param \Magento\Catalog\Helper\Catalog $helperCatalog | ||
*/ | ||
public function __construct(\Magento\Catalog\Helper\Catalog $helperCatalog) | ||
{ | ||
$this->helperCatalog = $helperCatalog; | ||
} | ||
|
||
/** | ||
* Setting attribute tab block for bundle | ||
* | ||
* @param \Magento\Framework\Event\Observer $observer | ||
* @return $this | ||
*/ | ||
public function invoke($observer) | ||
{ | ||
$product = $observer->getEvent()->getProduct(); | ||
if ($product->getTypeId() == \Magento\Catalog\Model\Product\Type::TYPE_BUNDLE) { | ||
$this->helperCatalog->setAttributeTabBlock( | ||
'Magento\Bundle\Block\Adminhtml\Catalog\Product\Edit\Tab\Attributes' | ||
); | ||
} | ||
return $this; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.