Passed
Push — master ( d1b72a...68b5a8 )
by Anatoly
01:04 queued 11s
created

Version20210203204551::down()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 1

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 1
nc 1
nop 1
dl 0
loc 3
c 1
b 0
f 0
cc 1
rs 10
1
<?php
2
3
declare(strict_types=1);
4
5
namespace DoctrineMigrations;
6
7
use Doctrine\DBAL\Schema\Schema;
8
use Doctrine\Migrations\AbstractMigration;
9
10
/**
11
 * Auto-generated Migration: Please modify to your needs!
12
 */
13
final class Version20210203204551 extends AbstractMigration
14
{
15
    public function getDescription() : string
16
    {
17
        return '';
18
    }
19
20
    public function up(Schema $schema) : void
21
    {
22
        $this->addSql('CREATE TABLE Entry (
23
            id CHAR(36) NOT NULL COMMENT \'(DC2Type:uuid)\',
24
            name VARCHAR(128) NOT NULL,
25
            slug VARCHAR(128) NOT NULL,
26
            createdAt DATETIME NOT NULL,
27
            updatedAt DATETIME DEFAULT NULL,
28
            INDEX IDX_EAE0B27486CA693C (createdAt),
29
            UNIQUE INDEX UNIQ_EAE0B274989D9B62 (slug),
30
            PRIMARY KEY(id)
31
        ) DEFAULT CHARACTER SET utf8mb4 COLLATE `utf8mb4_unicode_ci` ENGINE = InnoDB');
32
    }
33
34
    public function down(Schema $schema) : void
35
    {
36
        $this->addSql('DROP TABLE Entry');
37
    }
38
}
39