added account number field to user (#2671)

This commit is contained in:
Kevin Papst
2021-07-19 00:13:39 +02:00
committed by GitHub
parent 7d052eba00
commit 828b9c8b4a
12 changed files with 106 additions and 6 deletions

View File

@@ -0,0 +1,38 @@
<?php
declare(strict_types=1);
/*
* This file is part of the Kimai time-tracking app.
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
namespace DoctrineMigrations;
use Doctrine\DBAL\Schema\Schema;
use Doctrine\Migrations\AbstractMigration;
/**
* @version 1.15
*/
final class Version20210717211144 extends AbstractMigration
{
public function getDescription(): string
{
return '';
}
public function up(Schema $schema): void
{
$users = $schema->getTable('kimai2_users');
$users->addColumn('account', 'string', ['length' => 30, 'notnull' => false, 'default' => null]);
}
public function down(Schema $schema): void
{
$users = $schema->getTable('kimai2_users');
$users->dropColumn('account');
}
}