Files
ludikevent_crm/migrations/Version20260115190139.php

39 lines
1.3 KiB
PHP
Raw Normal View History

<?php
declare(strict_types=1);
namespace DoctrineMigrations;
use Doctrine\DBAL\Schema\Schema;
use Doctrine\Migrations\AbstractMigration;
/**
* Auto-generated Migration: Please modify to your needs!
*/
final class Version20260115190139 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 audit_log ADD user_agent VARCHAR(255) NOT NULL');
$this->addSql('ALTER TABLE audit_log ALTER account_id SET NOT NULL');
$this->addSql('ALTER TABLE audit_log ALTER type TYPE VARCHAR(50)');
$this->addSql('ALTER TABLE audit_log ALTER message TYPE TEXT');
}
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->addSql('CREATE SCHEMA public');
$this->addSql('ALTER TABLE audit_log DROP user_agent');
$this->addSql('ALTER TABLE audit_log ALTER account_id DROP NOT NULL');
$this->addSql('ALTER TABLE audit_log ALTER type TYPE VARCHAR(255)');
$this->addSql('ALTER TABLE audit_log ALTER message TYPE VARCHAR(255)');
}
}