<?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 Version20220609173623 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 cal_user ADD onboarding_email DATETIME DEFAULT NULL');
$this->addSql('ALTER TABLE cal_workflow_project ADD accommodation_id INT DEFAULT NULL');
$this->addSql('ALTER TABLE cal_workflow_project ADD CONSTRAINT FK_85F54F338F3692CD FOREIGN KEY (accommodation_id) REFERENCES cal_accommodation (id)');
$this->addSql('CREATE UNIQUE INDEX UNIQ_85F54F338F3692CD ON cal_workflow_project (accommodation_id)');
$this->addSql('ALTER TABLE cal_workflow_status ADD accommodation_default TINYINT(1) DEFAULT NULL');
}
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->addSql('ALTER TABLE cal_user DROP onboarding_email');
$this->addSql('ALTER TABLE cal_workflow_project DROP FOREIGN KEY FK_85F54F338F3692CD');
$this->addSql('DROP INDEX UNIQ_85F54F338F3692CD ON cal_workflow_project');
$this->addSql('ALTER TABLE cal_workflow_project DROP accommodation_id');
$this->addSql('ALTER TABLE cal_workflow_status DROP accommodation_default');
}
}