-
Notifications
You must be signed in to change notification settings - Fork 43
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
8 changed files
with
112 additions
and
5 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
33 changes: 33 additions & 0 deletions
33
app/code/community/Ess/M2ePro/sql/Update/y22_m11/FixWalmartChildListingId.php
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,33 @@ | ||
<?php | ||
|
||
// @codingStandardsIgnoreFile | ||
|
||
class Ess_M2ePro_Sql_Update_y22_m11_FixWalmartChildListingId extends | ||
Ess_M2ePro_Model_Upgrade_Feature_AbstractFeature | ||
{ | ||
public function execute() | ||
{ | ||
$installer = $this->_installer; | ||
$connection = $installer->getConnection(); | ||
$select = $connection->select(); | ||
|
||
$select->join( | ||
array('wlp' => $installer->getFullTableName('walmart_listing_product')), | ||
'lp.id = wlp.listing_product_id', | ||
null | ||
); | ||
$select->join( | ||
array('parent_lp' => $installer->getFullTableName('listing_product')), | ||
'parent_lp.id = wlp.variation_parent_id', | ||
array('listing_id' => 'parent_lp.listing_id') | ||
); | ||
$select->where('lp.listing_id != parent_lp.listing_id'); | ||
|
||
$updateQuery = $connection->updateFromSelect( | ||
$select, | ||
array('lp' => $installer->getFullTableName('listing_product')) | ||
); | ||
|
||
$connection->query($updateQuery); | ||
} | ||
} |
17 changes: 17 additions & 0 deletions
17
app/code/community/Ess/M2ePro/sql/Upgrade/v6_31_0__v6_31_1/Config.php
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,17 @@ | ||
<?php | ||
|
||
/** | ||
* @author M2E Pro Developers Team | ||
* @copyright M2E LTD | ||
* @license Commercial use is forbidden | ||
*/ | ||
|
||
class Ess_M2ePro_Sql_Upgrade_v6_31_0__v6_31_1_Config extends Ess_M2ePro_Model_Upgrade_Feature_AbstractConfig | ||
{ | ||
public function getFeaturesList() | ||
{ | ||
return array( | ||
'@y22_m11/FixWalmartChildListingId' | ||
); | ||
} | ||
} |
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