<?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 Version20221012150132 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 exposition_artwork (id INT AUTO_INCREMENT NOT NULL, exposition_id INT NOT NULL, artwork_id INT NOT NULL, INDEX IDX_11DB78C788ED476F (exposition_id), INDEX IDX_11DB78C7DB8FFA4 (artwork_id), PRIMARY KEY(id)) DEFAULT CHARACTER SET utf8mb4 COLLATE `utf8mb4_unicode_ci` ENGINE = InnoDB');
$this->addSql('ALTER TABLE exposition_artwork ADD CONSTRAINT FK_11DB78C788ED476F FOREIGN KEY (exposition_id) REFERENCES exposition (id)');
$this->addSql('ALTER TABLE exposition_artwork ADD CONSTRAINT FK_11DB78C7DB8FFA4 FOREIGN KEY (artwork_id) REFERENCES artwork (id)');
}
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->addSql('DROP TABLE exposition_artwork');
}
}