<?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 Version20220316145903 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('CREATE TABLE send_mmlogger (id INT AUTO_INCREMENT NOT NULL, message_id_id INT DEFAULT NULL, status TINYINT(1) DEFAULT NULL, send_date DATETIME DEFAULT NULL, INDEX IDX_47CDF05C80E261BC (message_id_id), PRIMARY KEY(id)) DEFAULT CHARACTER SET utf8mb4 COLLATE `utf8mb4_unicode_ci` ENGINE = InnoDB');
$this->addSql('ALTER TABLE send_mmlogger ADD CONSTRAINT FK_47CDF05C80E261BC FOREIGN KEY (message_id_id) REFERENCES message (id)');
$this->addSql('ALTER TABLE message ADD title LONGTEXT NOT NULL, ADD time TIME NOT NULL');
}
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->addSql('DROP TABLE send_mmlogger');
$this->addSql('ALTER TABLE message DROP title, DROP time');
}
}