<?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 Version20220126094427 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 photo_life (id INT AUTO_INCREMENT NOT NULL, presentation_id INT NOT NULL, position INT NOT NULL, nom VARCHAR(255) NOT NULL, INDEX IDX_98FC8C0AAB627E8B (presentation_id), PRIMARY KEY(id)) DEFAULT CHARACTER SET utf8mb4 COLLATE `utf8mb4_unicode_ci` ENGINE = InnoDB');
$this->addSql('ALTER TABLE photo_life ADD CONSTRAINT FK_98FC8C0AAB627E8B FOREIGN KEY (presentation_id) REFERENCES presentation (id)');
}
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->addSql('DROP TABLE photo_life');
}
}