<?php
declare(strict_types=1);
namespace Boldr\Shop\SurchargeBundle\Migrations;
use Boldr\Cms\CmsBundle\BoldrCmsMigration;
use Doctrine\DBAL\Schema\Schema;
/**
* Auto-generated Migration: Please modify to your needs!
*/
final class Version1_0_3 extends BoldrCmsMigration
{
public function getBundle(): string { return 'boldr/surcharge-bundle'; }
public function getVersion(): ?string { return '1.0.03'; }
public function up(Schema $schema): void
{
// this up() migration is auto-generated, please modify it to your needs
$this->addSql('ALTER TABLE surcharge_surcharge_currency DROP PRIMARY KEY');
$this->addSql('ALTER TABLE surcharge_surcharge_currency CHANGE surcharge_id surcharge_id INT UNSIGNED NOT NULL');
$this->addSql('ALTER TABLE surcharge_surcharge_currency ADD PRIMARY KEY (surcharge_id, currency)');
}
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->addSql('ALTER TABLE surcharge_surcharge_currency DROP PRIMARY KEY');
$this->addSql('ALTER TABLE surcharge_surcharge_currency CHANGE surcharge_id surcharge_id INT UNSIGNED DEFAULT NULL');
$this->addSql('ALTER TABLE surcharge_surcharge_currency ADD PRIMARY KEY (currency)');
}
}