<?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 Version20251210154641 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('CREATE TABLE product_price_form_batch (id INT AUTO_INCREMENT NOT NULL, seller_id INT NOT NULL, employee_id INT NOT NULL, category_id INT DEFAULT NULL, product_base_id INT DEFAULT NULL, created_at DATETIME NOT NULL, updated_at DATETIME DEFAULT NULL, price_action VARCHAR(20) NOT NULL, target VARCHAR(20) NOT NULL, amount INT NOT NULL, INDEX IDX_41489DEF8DE820D9 (seller_id), INDEX IDX_41489DEF8C03F15C (employee_id), INDEX IDX_41489DEF12469DE2 (category_id), INDEX IDX_41489DEFB8BEC4F1 (product_base_id), PRIMARY KEY(id)) DEFAULT CHARACTER SET utf8mb4 COLLATE `utf8mb4_unicode_ci` ENGINE = InnoDB');
$this->addSql('ALTER TABLE product_price_form_batch ADD CONSTRAINT FK_41489DEF8DE820D9 FOREIGN KEY (seller_id) REFERENCES seller (id)');
$this->addSql('ALTER TABLE product_price_form_batch ADD CONSTRAINT FK_41489DEF8C03F15C FOREIGN KEY (employee_id) REFERENCES user (id)');
$this->addSql('ALTER TABLE product_price_form_batch ADD CONSTRAINT FK_41489DEF12469DE2 FOREIGN KEY (category_id) REFERENCES category (id)');
$this->addSql('ALTER TABLE product_price_form_batch ADD CONSTRAINT FK_41489DEFB8BEC4F1 FOREIGN KEY (product_base_id) REFERENCES product_base (id)');
}
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->addSql('DROP TABLE product_price_form_batch');
}
}