Fixing installation migration, it needs to actually create tables.

This commit is contained in:
Dan Cryer 2014-05-19 10:46:23 +01:00
parent c2b3461262
commit 16b44220d5

View file

@ -52,6 +52,10 @@ class InitialMigration extends AbstractMigration
{
$table = $this->table('build');
if (!$this->hasTable('build')) {
$table->create();
}
if (!$table->hasColumn('project_id')) {
$table->addColumn('project_id', 'integer');
}
@ -115,6 +119,10 @@ class InitialMigration extends AbstractMigration
{
$table = $this->table('build_meta');
if (!$this->hasTable('build_meta')) {
$table->create();
}
if (!$table->hasColumn('project_id')) {
$table->addColumn('project_id', 'integer');
}
@ -142,6 +150,10 @@ class InitialMigration extends AbstractMigration
{
$table = $this->table('project');
if (!$this->hasTable('project')) {
$table->create();
}
if (!$table->hasColumn('title')) {
$table->addColumn('title', 'string', array('limit' => 250));
}
@ -193,6 +205,10 @@ class InitialMigration extends AbstractMigration
{
$table = $this->table('user');
if (!$this->hasTable('user')) {
$table->create();
}
if (!$table->hasColumn('email')) {
$table->addColumn('email', 'string', array('limit' => 250));
}
@ -215,4 +231,4 @@ class InitialMigration extends AbstractMigration
$table->save();
}
}
}