<?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 Version20230918133253 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 client_company ADD sales_rep_id INT DEFAULT NULL');
$this->addSql('ALTER TABLE client_company ADD CONSTRAINT FK_1D824D3276311BE2 FOREIGN KEY (sales_rep_id) REFERENCES collaborator (id)');
$this->addSql('CREATE INDEX IDX_1D824D3276311BE2 ON client_company (sales_rep_id)');
}
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->addSql('ALTER TABLE client_company DROP FOREIGN KEY FK_1D824D3276311BE2');
$this->addSql('DROP INDEX IDX_1D824D3276311BE2 ON client_company');
$this->addSql('ALTER TABLE client_company DROP sales_rep_id');
}
}