Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.
 
 
 
 
 
 

55 строки
1.1 KiB

  1. <?php
  2. /**
  3. * Copyright © Magento, Inc. All rights reserved.
  4. * See COPYING.txt for license details.
  5. */
  6. declare(strict_types=1);
  7. namespace %moduleName%\Setup\Patch\%patchType%;
  8. use Magento\Framework\Setup\ModuleDataSetupInterface;
  9. %useDataPatchInterface%%usePatchRevertableInterface%%SchemaPatchInterface%
  10. /**
  11. * Patch is mechanism, that allows to do atomic upgrade data changes
  12. */
  13. class %class% implements %implementsInterfaces%
  14. {
  15. /**
  16. * @var ModuleDataSetupInterface $moduleDataSetup
  17. */
  18. private $moduleDataSetup;
  19. /**
  20. * @param ModuleDataSetupInterface $moduleDataSetup
  21. */
  22. public function __construct(ModuleDataSetupInterface $moduleDataSetup)
  23. {
  24. $this->moduleDataSetup = $moduleDataSetup;
  25. }
  26. /**
  27. * Do Upgrade
  28. *
  29. * @return void
  30. */
  31. public function apply()
  32. {
  33. }
  34. %revertFunction%
  35. /**
  36. * @inheritdoc
  37. */
  38. public function getAliases()
  39. {
  40. return [];
  41. }
  42. /**
  43. * @inheritdoc
  44. */
  45. public static function getDependencies()
  46. {
  47. return [];
  48. }
  49. }