<?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 Version20230224103501 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 has_concierge DROP FOREIGN KEY FK_7A40C79B1F1F2A24');
$this->addSql('ALTER TABLE has_concierge ADD score VARCHAR(50) DEFAULT NULL, ADD identifier VARCHAR(255) DEFAULT NULL');
$this->addSql('DROP INDEX uniq_7a40c79b1f1f2a24 ON has_concierge');
$this->addSql('CREATE UNIQUE INDEX UNIQ_26AB055F1F1F2A24 ON has_concierge (element_id)');
$this->addSql('ALTER TABLE has_concierge ADD CONSTRAINT FK_7A40C79B1F1F2A24 FOREIGN KEY (element_id) REFERENCES element (id)');
}
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->addSql('ALTER TABLE has_concierge DROP FOREIGN KEY FK_26AB055F1F1F2A24');
$this->addSql('ALTER TABLE has_concierge DROP score, DROP identifier');
$this->addSql('DROP INDEX uniq_26ab055f1f1f2a24 ON has_concierge');
$this->addSql('CREATE UNIQUE INDEX UNIQ_7A40C79B1F1F2A24 ON has_concierge (element_id)');
$this->addSql('ALTER TABLE has_concierge ADD CONSTRAINT FK_26AB055F1F1F2A24 FOREIGN KEY (element_id) REFERENCES element (id)');
}
}