migrations/Version20250607182211.php line 1
<?phpdeclare(strict_types=1);namespace DoctrineMigrations;use Doctrine\DBAL\Schema\Schema;use Doctrine\Migrations\AbstractMigration;/*** Auto-generated Migration: Please modify to your needs!*/final class Version20250607182211 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(<<<'SQL'ALTER TABLE category_product_attribut ADD CONSTRAINT FK_34353B4E639A3624 FOREIGN KEY (category_product_id) REFERENCES categoryproduct (id) ON DELETE CASCADESQL);$this->addSql(<<<'SQL'ALTER TABLE product ADD CONSTRAINT FK_D34A04AD796A8F92 FOREIGN KEY (parent_category_id) REFERENCES categoryproduct (id)SQL);$this->addSql(<<<'SQL'ALTER TABLE product_category_product ADD CONSTRAINT FK_9A1E202F639A3624 FOREIGN KEY (category_product_id) REFERENCES categoryproduct (id) ON DELETE CASCADESQL);}public function down(Schema $schema): void{// this down() migration is auto-generated, please modify it to your needs$this->addSql(<<<'SQL'ALTER TABLE category_product_attribut DROP FOREIGN KEY FK_34353B4E639A3624SQL);$this->addSql(<<<'SQL'ALTER TABLE product DROP FOREIGN KEY FK_D34A04AD796A8F92SQL);$this->addSql(<<<'SQL'ALTER TABLE product_category_product DROP FOREIGN KEY FK_9A1E202F639A3624SQL);}}