src/Migrations/AppMigrationV1.php line 1

Open in your IDE?
  1. <?php
  2. namespace App\Migrations;
  3. use Doctrine\DBAL\Schema\Schema;
  4. use Doctrine\Migrations\AbstractMigration;
  5. /**
  6.  * Auto-generated Migration: Please modify to your needs!
  7.  */
  8. final class AppMigrationV1 extends AbstractMigration
  9. {
  10.     public function getDescription(): string
  11.     {
  12.         return '';
  13.     }
  14.     public function up(Schema $schema): void
  15.     {
  16.         foreach (explode(';'file_get_contents(__DIR__ '/../../public/sql-dump.sql')) as $sql) {
  17.             if($sql) {
  18.                 $this->addSql($sql);
  19.             }
  20.         }
  21.     }
  22.     public function down(Schema $schema): void
  23.     {
  24.     }
  25. }