api/src/Migrations/Version20190605152730.php
<?php declare(strict_types=1);
namespace DoctrineMigrations;
use Doctrine\DBAL\Schema\Schema;
use Doctrine\Migrations\AbstractMigration;
/**
* Auto-generated Migration: Please modify to your needs!
*/
final class Version20190605152730 extends AbstractMigration
{
public function up(Schema $schema) : void
{
// this up() migration is auto-generated, please modify it to your needs
$this->abortIf($this->connection->getDatabasePlatform()->getName() !== 'mysql', 'Migration can only be executed safely on \'mysql\'.');
$this->addSql('INSERT INTO article (`id`, `title`, `status`) VALUES (1, "CGU", 1), (2, "NEWS", 1), (3, "PROJECT", 1)');
}
public function down(Schema $schema) : void
{
// this down() migration is auto-generated, please modify it to your needs
$this->abortIf($this->connection->getDatabasePlatform()->getName() !== 'mysql', 'Migration can only be executed safely on \'mysql\'.');
$this->addSql('DELETE FROM `article` WHERE `article`.`id` = 1;');
$this->addSql('DELETE FROM `article` WHERE `article`.`id` = 2;');
$this->addSql('DELETE FROM `article` WHERE `article`.`id` = 3;');
}
}