migrations/Version20220427141531.php line 1
<?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 Version20220427141531 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('ALTER TABLE game_screenshot DROP FOREIGN KEY FK_B645D9AC4A8B36A0');
$this->addSql('DROP INDEX UNIQ_B645D9AC4A8B36A0 ON game_screenshot');
$this->addSql('ALTER TABLE game_screenshot ADD screenshot VARCHAR(255) DEFAULT NULL, DROP screenshot_id');
}
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->addSql('ALTER TABLE game_screenshot ADD screenshot_id INT DEFAULT NULL, DROP screenshot');
$this->addSql('ALTER TABLE game_screenshot ADD CONSTRAINT FK_B645D9AC4A8B36A0 FOREIGN KEY (screenshot_id) REFERENCES media_file (id)');
$this->addSql('CREATE UNIQUE INDEX UNIQ_B645D9AC4A8B36A0 ON game_screenshot (screenshot_id)');
}
}