Update 20251125120000_create_warehouse_project_journal.php
This commit is contained in:
@@ -9,10 +9,10 @@ final class CreateWarehouseProjectJournal extends AbstractMigration
|
||||
{
|
||||
if ($this->getEnvironment() == "thetool") {
|
||||
$table = $this->table('WarehouseProjectJournal');
|
||||
$table->addColumn('projectId', 'integer')
|
||||
$table->addColumn('projectId', 'integer', ['signed' => false]) // Fixed: Matches unsigned ID
|
||||
->addColumn('text', 'text', ['null' => true])
|
||||
->addColumn('data', 'json', ['null' => true, 'comment' => 'Stores changes/diffs'])
|
||||
->addColumn('createBy', 'integer')
|
||||
->addColumn('createBy', 'integer', ['signed' => false]) // Fixed: Best practice for User IDs
|
||||
->addColumn('create', 'integer')
|
||||
->addForeignKey('projectId', 'WarehouseProject', 'id', ['delete' => 'CASCADE', 'update' => 'CASCADE'])
|
||||
->create();
|
||||
|
||||
Reference in New Issue
Block a user