migrations/Version20210924132303.php line 1

Open in your IDE?
  1. <?php
  2. declare(strict_types=1);
  3. namespace DoctrineMigrations;
  4. use Doctrine\DBAL\Schema\Schema;
  5. use Doctrine\Migrations\AbstractMigration;
  6. /**
  7.  * Auto-generated Migration: Please modify to your needs!
  8.  */
  9. final class Version20210924132303 extends AbstractMigration
  10. {
  11.     public function getDescription(): string
  12.     {
  13.         return '';
  14.     }
  15.     public function up(Schema $schema): void
  16.     {
  17.         $this->addSql('ALTER TABLE bank_collection ADD inv_id INT DEFAULT NULL');
  18.         $this->addSql('ALTER TABLE bank_collection ADD CONSTRAINT FK_75EDA3846F6FD57F FOREIGN KEY (inv_id) REFERENCES invoice (id)');
  19.         $this->addSql('CREATE INDEX IDX_75EDA3846F6FD57F ON bank_collection (inv_id)');
  20.         $this->addSql('ALTER TABLE bank_collection RENAME INDEX idx_75eda3846a909013 TO IDX_75EDA38425CD93C3');
  21.     }
  22.     public function down(Schema $schema): void
  23.     {
  24.     }
  25. }