<?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 Version20231020101543 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 business ADD button_logo_id INT DEFAULT NULL, ADD button_text VARCHAR(255) DEFAULT NULL, ADD active_button_logo TINYINT(1) DEFAULT 1 NOT NULL, ADD active_button_text TINYINT(1) DEFAULT 1 NOT NULL');
$this->addSql('ALTER TABLE business ADD CONSTRAINT FK_8D36E382ECC49BB FOREIGN KEY (button_logo_id) REFERENCES media (id)');
$this->addSql('CREATE INDEX IDX_8D36E382ECC49BB ON business (button_logo_id)');
}
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->addSql('ALTER TABLE business DROP FOREIGN KEY FK_8D36E382ECC49BB');
$this->addSql('DROP INDEX IDX_8D36E382ECC49BB ON business');
$this->addSql('ALTER TABLE business DROP button_logo_id, DROP button_text, DROP active_button_logo, DROP active_button_text');
}
}