<?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 Version20230901150041 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 std_notifications_schedule DROP FOREIGN KEY FK_F8A2F88E8CDE5729');
$this->addSql('DROP INDEX fk_std_notifications_schedule_std_notifications_types ON std_notifications_schedule');
$this->addSql('ALTER TABLE std_notifications_schedule ADD types JSON NOT NULL, DROP type');
}
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->addSql('ALTER TABLE std_notifications_schedule ADD type INT UNSIGNED DEFAULT NULL COMMENT \'Notification type unique identifier\', DROP types');
$this->addSql('ALTER TABLE std_notifications_schedule ADD CONSTRAINT FK_F8A2F88E8CDE5729 FOREIGN KEY (type) REFERENCES std_notifications_types (id)');
$this->addSql('CREATE INDEX fk_std_notifications_schedule_std_notifications_types ON std_notifications_schedule (type)');
}
}