Allow more characters for maritalstatus id

This commit is contained in:
2025-05-14 13:56:36 +02:00
parent 4a8d298ae5
commit af36eccfaf
2 changed files with 37 additions and 1 deletions

View File

@@ -0,0 +1,36 @@
<?php
declare(strict_types=1);
namespace Chill\Migrations\Person;
use Doctrine\DBAL\Schema\Schema;
use Doctrine\Migrations\AbstractMigration;
final class Version20250514115009 extends AbstractMigration
{
public function getDescription(): string
{
return 'Allow more characters for maritalstatus id';
}
public function up(Schema $schema): void
{
$this->addSql(<<<'SQL'
ALTER TABLE chill_person_marital_status ALTER id TYPE VARCHAR(15)
SQL);
$this->addSql(<<<'SQL'
ALTER TABLE chill_person_person ALTER maritalstatus_id TYPE VARCHAR(15)
SQL);
}
public function down(Schema $schema): void
{
$this->addSql(<<<'SQL'
ALTER TABLE chill_person_person ALTER maritalStatus_id TYPE VARCHAR(7)
SQL);
$this->addSql(<<<'SQL'
ALTER TABLE chill_person_marital_status ALTER id TYPE VARCHAR(7)
SQL);
}
}