<?php
declare(strict_types=1);
namespace CoreMigrations;
use Doctrine\DBAL\Schema\Schema;
use Doctrine\Migrations\AbstractMigration;
/**
* Auto-generated Migration: Please modify to your needs!
*/
final class Version20220304134753 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 currency CHANGE change_rate change_rate NUMERIC(20, 12) DEFAULT \'1\' NOT NULL');
$this->addSql('ALTER TABLE customers_bundle__customer ADD context_id BINARY(16) DEFAULT NULL COMMENT \'(DC2Type:uuid)\'');
$this->addSql('ALTER TABLE customers_bundle__customer ADD CONSTRAINT FK_1FD6BD956B00C1CF FOREIGN KEY (context_id) REFERENCES context (id)');
$this->addSql('CREATE INDEX IDX_1FD6BD956B00C1CF ON customers_bundle__customer (context_id)');
}
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->addSql('ALTER TABLE currency CHANGE change_rate change_rate NUMERIC(20, 12) DEFAULT \'1.000000000000\' NOT NULL');
$this->addSql('ALTER TABLE customers_bundle__customer DROP FOREIGN KEY FK_1FD6BD956B00C1CF');
$this->addSql('DROP INDEX IDX_1FD6BD956B00C1CF ON customers_bundle__customer');
$this->addSql('ALTER TABLE customers_bundle__customer DROP context_id');
}
}