<?php
declare(strict_types=1);
namespace RecurringInvoicesBundleMigrations;
use Doctrine\DBAL\Schema\Schema;
use Doctrine\Migrations\AbstractMigration;
final class Version20230825082629 extends AbstractMigration
{
public function up(Schema $schema): void
{
$this->addSql('ALTER TABLE recurring_invoices_bundle__recurring_invoice ADD quotation_id BINARY(16) DEFAULT NULL COMMENT \'(DC2Type:uuid)\'');
$this->addSql('ALTER TABLE recurring_invoices_bundle__recurring_invoice ADD CONSTRAINT FK_6B9712EB4EA4E60 FOREIGN KEY (quotation_id) REFERENCES sales_bundle__quotation (id)');
$this->addSql('CREATE INDEX IDX_6B9712EB4EA4E60 ON recurring_invoices_bundle__recurring_invoice (quotation_id)');
}
public function down(Schema $schema): void
{
$this->addSql('ALTER TABLE recurring_invoices_bundle__recurring_invoice DROP FOREIGN KEY FK_6B9712EB4EA4E60');
$this->addSql('DROP INDEX IDX_6B9712EB4EA4E60 ON recurring_invoices_bundle__recurring_invoice');
$this->addSql('ALTER TABLE recurring_invoices_bundle__recurring_invoice DROP quotation_id');
}
}