migrations/Version20220414110100.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 Version20220414110100 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.         $this->addSql("INSERT INTO `role` (`id`, `name`) VALUES
  19. (1, 'ROLE_ADMIN'),
  20. (2, 'ROLE_USER')");
  21.         $this->addSql("INSERT INTO `user` (`id`, `email`, `password`, `name`, `status`, `token`, `date_added`, `date_modified`) VALUES
  22. (1, 'user1@repatriot.ro', '\$argon2id\$v=19\$m=65536,t=4,p=1\$Vy8l7oql0mEIi965appppw\$NqdYtdQ9+fYiBH3TD3NxUoNQSCD8Hvs0AXEky4Wh6Os', 'Repatriot 1', 1, 'a02254dcfc9d02d658c8f97d0fa82d1e', '2019-09-27 05:30:57', '2019-09-27 05:30:57'),
  23. (2, 'user2@repatriot.ro', '\$argon2id\$v=19\$m=65536,t=4,p=1\$NDk+9FgCzgSoepfw3eXGZA\$uSGBKuLED6SU0KgKQy186zYk1bbReyoshnTiLZupbsE', 'Repatriot 2', 1, 'cd31b896edac4e5ea34385f9c14767ec', '2019-09-27 05:31:25', '2019-09-27 05:31:25')");
  24.         $this->addSql("INSERT INTO `user_role` (`user_id`, `role_id`) VALUES
  25. (1, 1),
  26. (2, 2)");
  27.         $this->addSql('INSERT INTO `setting` (name,value, translation_key) VALUES 
  28.                                                          ("logo","/default_logo.png","settings.logo"),
  29.                                                          ("printing_active","0","settings.printing"),
  30.                                                          ("app_name","Aplicatie","settings.app_name"),
  31.                                                          ("favicon", "/favicon.ico", "settings.favicon")');
  32.         $this->addSql("INSERT INTO email_template (id, header_id, footer_id, title, `body`, type, `status`, `email_trigger_id`) VALUES (1, NULL, NULL, 'Default Header', '', 1, 1, NULL);");
  33.         $this->addSql("INSERT INTO email_template (id, header_id, footer_id, title, `body`, type, `status`, `email_trigger_id`) VALUES (2, NULL, NULL, 'Default Footer', '', 2, 1, NULL);");
  34.         $this->addSql("INSERT INTO email_template (id, header_id, footer_id, title, `body`, type, `status`, `email_trigger_id`) VALUES (3, 1, 2, 'Default Body', '<p>###participantName###</p>
  35. <p>###participantCompany###</p>
  36. <p>###participantQRcode###</p>', 3, 1, NULL);");
  37.         $this->addSql("INSERT INTO email_trigger (id, name, `status`) VALUES (1, 'QR', 1);");
  38.         $this->addSql("UPDATE `email_template` SET `email_trigger_id` = '1' WHERE `email_template`.`id` = 3;");
  39.     }
  40.     public function down(Schema $schema): void
  41.     {
  42.         // this down() migration is auto-generated, please modify it to your needs
  43.     }
  44. }