Version20131205113046_AddPluginTable   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 21
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 2

Test Coverage

Coverage 0%

Importance

Changes 0
Metric Value
wmc 2
lcom 0
cbo 2
dl 0
loc 21
c 0
b 0
f 0
ccs 0
cts 17
cp 0
rs 10

2 Methods

Rating   Name   Duplication   Size   Complexity  
A down() 0 4 1
A up() 0 13 1
1
<?php
2
/**
3
 * AnimeDb package.
4
 *
5
 * @author    Peter Gribanov <[email protected]>
6
 * @copyright Copyright (c) 2011, Peter Gribanov
7
 * @license   http://opensource.org/licenses/GPL-3.0 GPL v3
8
 */
9
namespace AnimeDb\Bundle\AppBundle\DoctrineMigrations;
10
11
use Doctrine\DBAL\Migrations\AbstractMigration;
12
use Doctrine\DBAL\Schema\Schema;
13
14
class Version20131205113046_AddPluginTable extends AbstractMigration
15
{
16
    public function up(Schema $schema)
17
    {
18
        $this->addSql('
19
            CREATE TABLE plugin (
20
                name VARCHAR(255) NOT NULL,
21
                title TEXT NOT NULL,
22
                description TEXT NOT NULL,
23
                logo VARCHAR(256) DEFAULT NULL,
24
                date_install DATETIME NOT NULL,
25
                PRIMARY KEY(name)
26
            )'
27
        );
28
    }
29
30
    public function down(Schema $schema)
31
    {
32
        $schema->dropTable('plugin');
33
    }
34
}
35