<?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 Version20220208104316 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 products (id INT AUTO_INCREMENT NOT NULL, denumire VARCHAR(255) NOT NULL, descriere VARCHAR(255) DEFAULT NULL, tip INT NOT NULL, gestiune INT NOT NULL, pret INT NOT NULL, stoc INT DEFAULT NULL, PRIMARY KEY(id)) DEFAULT CHARACTER SET utf8mb4 COLLATE `utf8mb4_unicode_ci` ENGINE = InnoDB');
}
public function down(Schema $schema): void
{
// this down() migration is auto-generated, please modify it to your needs
$this->addSql('DROP TABLE products');
$this->addSql('ALTER TABLE grid CHANGE test test VARCHAR(255) DEFAULT NULL COLLATE `utf8mb4_unicode_ci`');
$this->addSql('ALTER TABLE prospecti CHANGE denumire denumire VARCHAR(255) NOT NULL COLLATE `utf8mb4_unicode_ci`, CHANGE note note VARCHAR(255) DEFAULT NULL COLLATE `utf8mb4_unicode_ci`, CHANGE contacte contacte LONGTEXT DEFAULT NULL COLLATE `utf8mb4_unicode_ci` COMMENT \'(DC2Type:array)\'');
$this->addSql('ALTER TABLE `user` CHANGE email email VARCHAR(180) NOT NULL COLLATE `utf8mb4_unicode_ci`, CHANGE roles roles LONGTEXT NOT NULL COLLATE `utf8mb4_unicode_ci` COMMENT \'(DC2Type:json)\', CHANGE password password VARCHAR(255) NOT NULL COLLATE `utf8mb4_unicode_ci`, CHANGE nume nume VARCHAR(255) NOT NULL COLLATE `utf8mb4_unicode_ci`, CHANGE prenume prenume VARCHAR(255) NOT NULL COLLATE `utf8mb4_unicode_ci`, CHANGE activ activ VARCHAR(255) NOT NULL COLLATE `utf8mb4_unicode_ci`, CHANGE avatar_link avatar_link VARCHAR(255) DEFAULT NULL COLLATE `utf8mb4_unicode_ci`');
}
}