<?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 Version20230926101714 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 jms_job_dependencies DROP FOREIGN KEY FK_8DCFE92C32CF8D4C');
$this->addSql('ALTER TABLE jms_job_dependencies DROP FOREIGN KEY FK_8DCFE92CBD1F6B4F');
$this->addSql('ALTER TABLE jms_job_related_entities DROP FOREIGN KEY FK_E956F4E2BE04EA9');
$this->addSql('ALTER TABLE jms_jobs DROP FOREIGN KEY FK_704ADB9349C447F1');
$this->addSql('DROP TABLE jms_job_dependencies');
$this->addSql('DROP TABLE migration_versions');
$this->addSql('DROP TABLE jms_job_related_entities');
$this->addSql('DROP TABLE jms_jobs');
$this->addSql('DROP TABLE jms_job_statistics');
$this->addSql('DROP TABLE jms_cron_jobs');
$this->addSql('ALTER TABLE task ADD resident_id INT DEFAULT NULL');
$this->addSql('ALTER TABLE task ADD CONSTRAINT FK_527EDB258012C5B0 FOREIGN KEY (resident_id) REFERENCES residents (id) ON DELETE SET NULL');
$this->addSql('CREATE INDEX IDX_527EDB258012C5B0 ON task (resident_id)');
$this->addSql('ALTER TABLE task_history ADD resident_id INT DEFAULT NULL');
$this->addSql('ALTER TABLE task_history ADD CONSTRAINT FK_385B5AA18012C5B0 FOREIGN KEY (resident_id) REFERENCES residents (id) ON DELETE SET NULL');
$this->addSql('CREATE INDEX IDX_385B5AA18012C5B0 ON task_history (resident_id)');
}
public function down(Schema $schema): void
{
}
}