29 lines
881 B
PHP
29 lines
881 B
PHP
|
|
<?php
|
||
|
|
|
||
|
|
declare(strict_types=1);
|
||
|
|
|
||
|
|
namespace DoctrineMigrations;
|
||
|
|
|
||
|
|
use Doctrine\DBAL\Schema\Schema;
|
||
|
|
use Doctrine\Migrations\AbstractMigration;
|
||
|
|
|
||
|
|
final class Version20260322110000 extends AbstractMigration
|
||
|
|
{
|
||
|
|
public function getDescription(): string
|
||
|
|
{
|
||
|
|
return 'Add offer and commission_rate to organizer_invitation';
|
||
|
|
}
|
||
|
|
|
||
|
|
public function up(Schema $schema): void
|
||
|
|
{
|
||
|
|
$this->addSql('ALTER TABLE organizer_invitation ADD COLUMN IF NOT EXISTS offer VARCHAR(20) DEFAULT NULL');
|
||
|
|
$this->addSql('ALTER TABLE organizer_invitation ADD COLUMN IF NOT EXISTS commission_rate DOUBLE PRECISION DEFAULT NULL');
|
||
|
|
}
|
||
|
|
|
||
|
|
public function down(Schema $schema): void
|
||
|
|
{
|
||
|
|
$this->addSql('ALTER TABLE organizer_invitation DROP COLUMN IF EXISTS offer');
|
||
|
|
$this->addSql('ALTER TABLE organizer_invitation DROP COLUMN IF EXISTS commission_rate');
|
||
|
|
}
|
||
|
|
}
|