<?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 Version20230117170929 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 media_object_new_student_enrollment ADD new_student_enrollment_id INT DEFAULT NULL, ADD file_key VARCHAR(255) DEFAULT NULL');
$this->addSql('ALTER TABLE media_object_new_student_enrollment ADD CONSTRAINT FK_EC1F6834C1172ECE FOREIGN KEY (new_student_enrollment_id) REFERENCES new_student_enrollment (id)');
$this->addSql('CREATE INDEX IDX_EC1F6834C1172ECE ON media_object_new_student_enrollment (new_student_enrollment_id)');
}
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->addSql('ALTER TABLE media_object_new_student_enrollment DROP FOREIGN KEY FK_EC1F6834C1172ECE');
$this->addSql('DROP INDEX IDX_EC1F6834C1172ECE ON media_object_new_student_enrollment');
$this->addSql('ALTER TABLE media_object_new_student_enrollment DROP new_student_enrollment_id, DROP file_key');
}
}