|
|
@@ -1,4 +1,5 @@
|
|
|
<?php
|
|
|
+
|
|
|
declare(strict_types=1);
|
|
|
|
|
|
use Phinx\Migration\AbstractMigration;
|
|
|
@@ -19,7 +20,7 @@ final class CreateMemberTable extends AbstractMigration
|
|
|
public function change(): void
|
|
|
{
|
|
|
$table = $this->table('mcard_member', ['id' => false, 'primary_key' => ['id'], 'comment' => '会员表']);
|
|
|
-
|
|
|
+
|
|
|
$table->addColumn('id', 'integer', ['limit' => 11, 'null' => false, 'signed' => false, 'identity' => true, 'comment' => '主键ID'])
|
|
|
->addColumn('user_id', 'integer', ['limit' => 11, 'null' => false, 'signed' => false, 'comment' => '用户ID'])
|
|
|
->addColumn('member_card_id', 'integer', ['limit' => 11, 'null' => false, 'signed' => false, 'comment' => '会员卡ID'])
|
|
|
@@ -43,4 +44,4 @@ final class CreateMemberTable extends AbstractMigration
|
|
|
|
|
|
$table->create();
|
|
|
}
|
|
|
-}
|
|
|
+}
|