for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
declare(strict_types=1);
/*
* This file is part of the G.L.S.R. Apps package.
*
* (c) Dev-Int Création <[email protected]>.
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace Administration\Infrastructure\DoctrineMigrations;
use Doctrine\DBAL\Schema\Schema;
use Doctrine\Migrations\AbstractMigration;
/**
* Auto-generated Migration: Please modify to your needs!
final class Version20201219174027 extends AbstractMigration
{
public function getDescription(): string
return 'Create user table';
}
public function up(Schema $schema): void
// this up() migration is auto-generated, please modify it to your needs
$this->addSql(
'CREATE TABLE user (' .
'uuid CHAR(36) NOT NULL COMMENT \'(DC2Type:guid)\', ' .
'username VARCHAR(150) NOT NULL, ' .
'email VARCHAR(255) NOT NULL, ' .
'password VARCHAR(36) NOT NULL, ' .
'roles LONGTEXT NOT NULL COMMENT \'(DC2Type:array)\', ' .
'PRIMARY KEY(uuid)' .
') 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 user');