Skip to content

Commit

Permalink
Create 20191111092900_UpdateFieldsToLogs.php
Browse files Browse the repository at this point in the history
Alterando o tamanho das colunas table_name e database_name.
  • Loading branch information
jeffersonsimaogoncalves committed Nov 11, 2019
1 parent d7651de commit 3451756
Showing 1 changed file with 30 additions and 0 deletions.
30 changes: 30 additions & 0 deletions config/Migrations/20191111092900_UpdateFieldsToLogs.php
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
<?php

use Migrations\AbstractMigration;

class UpdateFieldsToLogs extends AbstractMigration
{
/**
* Change Method.
*
* More information on this method is available here:
* http://docs.phinx.org/en/latest/migrations.html#the-change-method
*
* @return void
*/
public function change()
{
$table = $this->table('logs');
$table->changeColumn('table_name', 'string', [
'default' => null,
'limit' => 255,
'null' => false,
]);
$table->changeColumn('database_name', 'string', [
'default' => null,
'limit' => 255,
'null' => false,
]);
$table->update();
}
}

0 comments on commit 3451756

Please sign in to comment.