<?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 Version20221130160802 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 raport_opening_line ADD region_alias_id INT DEFAULT NULL');
$this->addSql('ALTER TABLE raport_opening_line ADD CONSTRAINT FK_325335422D914E10 FOREIGN KEY (region_alias_id) REFERENCES admin_structure_region_alias (id) NOT DEFERRABLE INITIALLY IMMEDIATE');
$this->addSql('CREATE INDEX IDX_325335422D914E10 ON raport_opening_line (region_alias_id)');
}
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->addSql('CREATE SCHEMA public');
$this->addSql('ALTER TABLE raport_opening_line DROP CONSTRAINT FK_325335422D914E10');
$this->addSql('DROP INDEX IDX_325335422D914E10');
$this->addSql('ALTER TABLE raport_opening_line DROP region_alias_id');
}
}