-
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.
🔃 [EngCom] Public Pull Requests - 2.3-develop
Accepted Public Pull Requests: - #21763: Spelling Correction (by @ansari-krish) - #21740: Removed extra whitespaces (by @yogeshsuhagiya) - #21731: Fixed wrong proxing in the inventory observer (by @VitaliyBoyko) - #21683: Correct spelling (by @ravi-chandra3197) - #21444: Disable dropdown in JavaScript and CSS Settings in developer configuration (by @ananth-iyer) - #21582: Fixed Whitespace issues for related, cross and upsell grids (by @amol2jcommerce) - #21600: Fixed typo mistake (by @yogeshsuhagiya) - #21468: Fix long string display horizontal scroll in all pages in admin (by @mageprince) - #21189: Fix/issue 18761 (by @DenisSaltanahmedov) - #21180: [ForwardPort] #18896 Add Mexico Regions (by @osrecio) - #20001: #13612 Fixed-Quantity_and_stock_status when visibility set to storefront throwing exception (by @aditisinghcedcoss) Fixed GitHub Issues: - #167: Fatal error: Class 'Mage' not found (reported by @clockworkgeek) has been fixed in #21731 by @VitaliyBoyko in 2.3-develop branch Related commits: 1. 3819dc1 - #21384: JS minify field is not disabled in developer configuration (reported by @DanielRuf) has been fixed in #21444 by @ananth-iyer in 2.3-develop branch Related commits: 1. a5bdc38 2. ab2d0e4 - #21541: Whitespace issues for related, cross and upsell grids (reported by @Zyles) has been fixed in #21582 by @amol2jcommerce in 2.3-develop branch Related commits: 1. 9ab463f - #18761: Bug with REPLACE method in Advanced Prices in CSV Import (reported by @kamilmaliszewski) has been fixed in #21189 by @DenisSaltanahmedov in 2.3-develop branch Related commits: 1. a572ae2 2. 6692e08 - #13612: 1 exception(s): Exception #0 (Exception): Warning: Illegal offset type in isset or empty in /home/jewelrynest2/public_html/magento/vendor/magento/module-eav/Model/Entity/Attribute/Source/AbstractSource.php on line 76 (reported by @kamal3294) has been fixed in #20001 by @aditisinghcedcoss in 2.3-develop branch Related commits: 1. 0df7243 2. 887902b
- Loading branch information
Showing
17 changed files
with
228 additions
and
63 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
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
127 changes: 127 additions & 0 deletions
127
app/code/Magento/Directory/Setup/Patch/Data/AddDataForMexico.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,127 @@ | ||
<?php | ||
/** | ||
* Copyright © Magento, Inc. All rights reserved. | ||
* See COPYING.txt for license details. | ||
*/ | ||
|
||
declare(strict_types=1); | ||
|
||
namespace Magento\Directory\Setup\Patch\Data; | ||
|
||
use Magento\Directory\Setup\DataInstaller; | ||
use Magento\Framework\Setup\ModuleDataSetupInterface; | ||
use Magento\Framework\Setup\Patch\DataPatchInterface; | ||
use Magento\Framework\Setup\Patch\PatchVersionInterface; | ||
|
||
/** | ||
* Adds Mexican States | ||
*/ | ||
class AddDataForMexico implements DataPatchInterface, PatchVersionInterface | ||
{ | ||
/** | ||
* @var ModuleDataSetupInterface | ||
*/ | ||
private $moduleDataSetup; | ||
|
||
/** | ||
* @var \Magento\Directory\Setup\DataInstallerFactory | ||
*/ | ||
private $dataInstallerFactory; | ||
|
||
/** | ||
* @param ModuleDataSetupInterface $moduleDataSetup | ||
* @param \Magento\Directory\Setup\DataInstallerFactory $dataInstallerFactory | ||
*/ | ||
public function __construct( | ||
ModuleDataSetupInterface $moduleDataSetup, | ||
\Magento\Directory\Setup\DataInstallerFactory $dataInstallerFactory | ||
) { | ||
$this->moduleDataSetup = $moduleDataSetup; | ||
$this->dataInstallerFactory = $dataInstallerFactory; | ||
} | ||
|
||
/** | ||
* @inheritdoc | ||
*/ | ||
public function apply() | ||
{ | ||
/** @var DataInstaller $dataInstaller */ | ||
$dataInstaller = $this->dataInstallerFactory->create(); | ||
$dataInstaller->addCountryRegions( | ||
$this->moduleDataSetup->getConnection(), | ||
$this->getDataForMexico() | ||
); | ||
} | ||
|
||
/** | ||
* Mexican states data. | ||
* | ||
* @return array | ||
*/ | ||
private function getDataForMexico() | ||
{ | ||
return [ | ||
['MX', 'AGU', 'Aguascalientes'], | ||
['MX', 'BCN', 'Baja California'], | ||
['MX', 'BCS', 'Baja California Sur'], | ||
['MX', 'CAM', 'Campeche'], | ||
['MX', 'CHP', 'Chiapas'], | ||
['MX', 'CHH', 'Chihuahua'], | ||
['MX', 'CMX', 'Ciudad de México'], | ||
['MX', 'COA', 'Coahuila'], | ||
['MX', 'COL', 'Colima'], | ||
['MX', 'DUR', 'Durango'], | ||
['MX', 'MEX', 'Estado de México'], | ||
['MX', 'GUA', 'Guanajuato'], | ||
['MX', 'GRO', 'Guerrero'], | ||
['MX', 'HID', 'Hidalgo'], | ||
['MX', 'JAL', 'Jalisco'], | ||
['MX', 'MIC', 'Michoacán'], | ||
['MX', 'MOR', 'Morelos'], | ||
['MX', 'NAY', 'Nayarit'], | ||
['MX', 'NLE', 'Nuevo León'], | ||
['MX', 'OAX', 'Oaxaca'], | ||
['MX', 'PUE', 'Puebla'], | ||
['MX', 'QUE', 'Querétaro'], | ||
['MX', 'ROO', 'Quintana Roo'], | ||
['MX', 'SLP', 'San Luis Potosí'], | ||
['MX', 'SIN', 'Sinaloa'], | ||
['MX', 'SON', 'Sonora'], | ||
['MX', 'TAB', 'Tabasco'], | ||
['MX', 'TAM', 'Tamaulipas'], | ||
['MX', 'TLA', 'Tlaxcala'], | ||
['MX', 'VER', 'Veracruz'], | ||
['MX', 'YUC', 'Yucatán'], | ||
['MX', 'ZAC', 'Zacatecas'] | ||
]; | ||
} | ||
|
||
/** | ||
* @inheritdoc | ||
*/ | ||
public static function getDependencies() | ||
{ | ||
return [ | ||
InitializeDirectoryData::class, | ||
AddDataForAustralia::class, | ||
AddDataForCroatia::class, | ||
AddDataForIndia::class, | ||
]; | ||
} | ||
|
||
/** | ||
* @inheritdoc | ||
*/ | ||
public static function getVersion() | ||
{ | ||
return '2.0.4'; | ||
} | ||
|
||
/** | ||
* @inheritdoc | ||
*/ | ||
public function getAliases() | ||
{ | ||
return []; | ||
} | ||
} |
Oops, something went wrong.