migrations/Version20231003081606.php line 1

Open in your IDE?
  1. <?php
  2. declare(strict_types=1);
  3. namespace DoctrineMigrations;
  4. use Doctrine\DBAL\Schema\Schema;
  5. use Doctrine\Migrations\AbstractMigration;
  6. /**
  7.  * Auto-generated Migration: Please modify to your needs!
  8.  */
  9. final class Version20231003081606 extends AbstractMigration
  10. {
  11.     public function getDescription(): string
  12.     {
  13.         return '';
  14.     }
  15.     public function up(Schema $schema): void
  16.     {
  17.         // this up() migration is auto-generated, please modify it to your needs
  18.         
  19.         $this->addSql("
  20.             INSERT IGNORE INTO `std_config` (`machine_name`, `created_by`, `updated_by`, `description_machine_name`, `details_machine_name`, `parent_name`, `variable_type`, `order_value`, `is_hidden`, `created_date`, `updated_date`, `label`, `language_code`)
  21.             VALUES 
  22.                 ('bottom_image', '1', '1', 'bottom_image', 'bottom_image', 'Bottom', 'IMAGE', '1', '0', now(), now(), 'Image', 'pt'),
  23.                 ('bottom_image', '1', '1', 'bottom_image', 'bottom_image', 'Bottom', 'IMAGE', '1', '0', now(), now(), 'Image', 'en'),
  24.                 ('bottom_image', '1', '1', 'bottom_image', 'bottom_image', 'Bottom', 'IMAGE', '1', '0', now(), now(), 'Image', 'es'),
  25.                 ('bottom_image', '1', '1', 'bottom_image', 'bottom_image', 'Bottom', 'IMAGE', '1', '0', now(), now(), 'Image', 'fr'),
  26.                 ('bottom_image', '1', '1', 'bottom_image', 'bottom_image', 'Bottom', 'IMAGE', '1', '0', now(), now(), 'Image', 'it'),
  27.                 ('bottom_image', '1', '1', 'bottom_image', 'bottom_image', 'Bottom', 'IMAGE', '1', '0', now(), now(), 'Image', 'de');
  28.         ");
  29.         $this->addSql("
  30.             INSERT IGNORE INTO `std_config` (`machine_name`, `created_by`, `updated_by`, `description_machine_name`, `details_machine_name`, `parent_name`, `variable_type`, `order_value`, `is_hidden`, `created_date`, `updated_date`, `label`, `language_code`)
  31.             VALUES 
  32.                 ('bottom_url', '1', '1', 'bottom_url', 'bottom_url', 'Bottom', 'INPUT', '2', '0', now(), now(), 'URL', 'pt'),
  33.                 ('bottom_url', '1', '1', 'bottom_url', 'bottom_url', 'Bottom', 'INPUT', '2', '0', now(), now(), 'URL', 'en'),
  34.                 ('bottom_url', '1', '1', 'bottom_url', 'bottom_url', 'Bottom', 'INPUT', '2', '0', now(), now(), 'URL', 'es'),
  35.                 ('bottom_url', '1', '1', 'bottom_url', 'bottom_url', 'Bottom', 'INPUT', '2', '0', now(), now(), 'URL', 'fr'),
  36.                 ('bottom_url', '1', '1', 'bottom_url', 'bottom_url', 'Bottom', 'INPUT', '2', '0', now(), now(), 'URL', 'it'),
  37.                 ('bottom_url', '1', '1', 'bottom_url', 'bottom_url', 'Bottom', 'INPUT', '2', '0', now(), now(), 'URL', 'de');                
  38.         ");
  39.         $this->addSql("
  40.             INSERT INTO `std_config` (`machine_name`, `created_by`, `updated_by`, `value`, `description_machine_name`, `details_machine_name`, `parent_name`, `variable_type`, `order_value`, `is_hidden`, `label`, `content`, `language_code`) 
  41.             VALUES             
  42.                 ('bottom_image_align', '1', '1', 'bottom_image_align', 'bottom_image_align', 'bottom_image_align', 'Bottom', 'SELECT', '3', '0', 'Align', '{\"query\": \"SELECT \'Left\' AS label,\'start\' AS `id` UNION SELECT \'Right\' AS label,\'end\' AS `id` UNION SELECT \'Center\' AS label,\'center\' AS `id`\"}','pt'),
  43.                 ('bottom_image_align', '1', '1', 'bottom_image_align', 'bottom_image_align', 'bottom_image_align', 'Bottom', 'SELECT', '3', '0', 'Align', '{\"query\": \"SELECT \'Left\' AS label,\'start\' AS `id` UNION SELECT \'Right\' AS label,\'end\' AS `id` UNION SELECT \'Center\' AS label,\'center\' AS `id`\"}','en'),
  44.                 ('bottom_image_align', '1', '1', 'bottom_image_align', 'bottom_image_align', 'bottom_image_align', 'Bottom', 'SELECT', '3', '0', 'Align', '{\"query\": \"SELECT \'Left\' AS label,\'start\' AS `id` UNION SELECT \'Right\' AS label,\'end\' AS `id` UNION SELECT \'Center\' AS label,\'center\' AS `id`\"}','es'),
  45.                 ('bottom_image_align', '1', '1', 'bottom_image_align', 'bottom_image_align', 'bottom_image_align', 'Bottom', 'SELECT', '3', '0', 'Align', '{\"query\": \"SELECT \'Left\' AS label,\'start\' AS `id` UNION SELECT \'Right\' AS label,\'end\' AS `id` UNION SELECT \'Center\' AS label,\'center\' AS `id`\"}','fr'),
  46.                 ('bottom_image_align', '1', '1', 'bottom_image_align', 'bottom_image_align', 'bottom_image_align', 'Bottom', 'SELECT', '3', '0', 'Align', '{\"query\": \"SELECT \'Left\' AS label,\'start\' AS `id` UNION SELECT \'Right\' AS label,\'end\' AS `id` UNION SELECT \'Center\' AS label,\'center\' AS `id`\"}','it'),
  47.                 ('bottom_image_align', '1', '1', 'bottom_image_align', 'bottom_image_align', 'bottom_image_align', 'Bottom', 'SELECT', '3', '0', 'Align', '{\"query\": \"SELECT \'Left\' AS label,\'start\' AS `id` UNION SELECT \'Right\' AS label,\'end\' AS `id` UNION SELECT \'Center\' AS label,\'center\' AS `id`\"}','de');
  48.         ");
  49.         
  50.         
  51.     }
  52.     public function down(Schema $schema): void
  53.     {
  54.         // this down() migration is auto-generated, please modify it to your needs
  55.         $this->addSql("DELETE FROM `std_config` WHERE `machine_name` IN ('bottom_image', 'bottom_url', 'bottom_image_align');");
  56.     }
  57. }