<?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 Version20220419102220 extends AbstractMigration
{
public function getDescription(): string
{
return '';
}
public function up(Schema $schema): void
{
// this up() migration is auto-generated, please modify it to your needs
$this->addSql('DROP TABLE migration_versions');
$this->addSql('ALTER TABLE event ADD created_date DATETIME DEFAULT \'2010-01-01 00:00:00\' NOT NULL');
$this->addSql('ALTER TABLE question ADD created_date DATETIME DEFAULT \'2010-01-01 00:00:00\' NOT NULL');
$this->addSql('ALTER TABLE user ADD created_date DATETIME DEFAULT \'2010-01-01 00:00:00\' NOT NULL');
}
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->addSql('CREATE TABLE migration_versions (version VARCHAR(14) CHARACTER SET utf8 NOT NULL COLLATE `utf8_unicode_ci`, executed_at DATETIME DEFAULT NULL COMMENT \'(DC2Type:datetime_immutable)\', PRIMARY KEY(version)) DEFAULT CHARACTER SET utf8 COLLATE `utf8_unicode_ci` ENGINE = InnoDB COMMENT = \'\' ');
$this->addSql('ALTER TABLE event DROP created_date');
$this->addSql('ALTER TABLE question DROP created_date');
$this->addSql('ALTER TABLE user DROP created_date');
}
}