<?php
declare(strict_types=1);
namespace CoreMigrations;
use Doctrine\DBAL\Schema\Schema;
use Doctrine\Migrations\AbstractMigration;
/**
* Auto-generated Migration: Please modify to your needs!
*/
final class Version20230823111322 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 projects_bundle__project ADD site_id BINARY(16) DEFAULT NULL COMMENT \'(DC2Type:uuid)\'');
$this->addSql('ALTER TABLE projects_bundle__project ADD CONSTRAINT FK_9317E9CF6BD1646 FOREIGN KEY (site_id) REFERENCES sites_bundle__site (id)');
$this->addSql('CREATE INDEX IDX_9317E9CF6BD1646 ON projects_bundle__project (site_id)');
}
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->addSql('ALTER TABLE projects_bundle__project DROP FOREIGN KEY FK_9317E9CF6BD1646');
$this->addSql('DROP INDEX IDX_9317E9CF6BD1646 ON projects_bundle__project');
$this->addSql('ALTER TABLE projects_bundle__project DROP site_id');
}
}