<?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 Version20240724093824 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 tracking_eleve_qcm ADD score_eleve_id INT DEFAULT NULL');
$this->addSql('ALTER TABLE tracking_eleve_qcm ADD CONSTRAINT FK_1430588FFD6F18CA FOREIGN KEY (score_eleve_id) REFERENCES score_eleve (id)');
$this->addSql('CREATE INDEX IDX_1430588FFD6F18CA ON tracking_eleve_qcm (score_eleve_id)');
}
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->addSql('ALTER TABLE tracking_eleve_qcm DROP FOREIGN KEY FK_1430588FFD6F18CA');
$this->addSql('DROP INDEX IDX_1430588FFD6F18CA ON tracking_eleve_qcm');
$this->addSql('ALTER TABLE tracking_eleve_qcm DROP score_eleve_id');
}
}