<?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 Version20230517070337 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 quality_level ADD service_package_id INT NOT NULL');
$this->addSql('ALTER TABLE quality_level ADD CONSTRAINT FK_8E440420621D924B FOREIGN KEY (service_package_id) REFERENCES service_package (id)');
$this->addSql('CREATE INDEX IDX_8E440420621D924B ON quality_level (service_package_id)');
}
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->addSql('ALTER TABLE quality_level DROP FOREIGN KEY FK_8E440420621D924B');
$this->addSql('DROP INDEX IDX_8E440420621D924B ON quality_level');
$this->addSql('ALTER TABLE quality_level DROP service_package_id');
}
}