<?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 Version20230504124833 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 job_daily_routine ADD avatar_picture_id INT DEFAULT NULL, ADD avatar_position VARCHAR(100) DEFAULT NULL');
$this->addSql('ALTER TABLE job_daily_routine ADD CONSTRAINT FK_3FC957EE44C0F5C3 FOREIGN KEY (avatar_picture_id) REFERENCES media__media (id)');
$this->addSql('CREATE INDEX IDX_3FC957EE44C0F5C3 ON job_daily_routine (avatar_picture_id)');
}
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->addSql('ALTER TABLE job_daily_routine DROP FOREIGN KEY FK_3FC957EE44C0F5C3');
$this->addSql('DROP INDEX IDX_3FC957EE44C0F5C3 ON job_daily_routine');
$this->addSql('ALTER TABLE job_daily_routine DROP avatar_picture_id, DROP avatar_position');
}
}