From b1ece57b691ef8ab9cf1289a893c9ebafaa222c2 Mon Sep 17 00:00:00 2001 From: zhaoxiang Date: Wed, 8 May 2019 18:28:18 +0800 Subject: [PATCH] =?UTF-8?q?modified=20=E6=B7=BB=E5=8A=A0=E6=95=B0=E6=8D=AE?= =?UTF-8?q?=E5=BA=93=E8=BF=81=E7=A7=BB=E8=84=9A=E6=9C=AC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- ...20190508100337_admin_auth_group_access.php | 1 + .../20190508101122_admin_auth_rule.php | 54 +++++++++++++++++++ 2 files changed, 55 insertions(+) create mode 100644 database/migrations/20190508101122_admin_auth_rule.php diff --git a/database/migrations/20190508100337_admin_auth_group_access.php b/database/migrations/20190508100337_admin_auth_group_access.php index d52c5b3..10bbc3d 100644 --- a/database/migrations/20190508100337_admin_auth_group_access.php +++ b/database/migrations/20190508100337_admin_auth_group_access.php @@ -32,6 +32,7 @@ class AdminAuthGroupAccess extends Migrator { $table->addColumn('uid', 'integer', [ 'limit' => 11, 'default' => 0, + 'signed' => false, 'comment' => '' ])->addColumn('groupId', 'string', [ 'limit' => 255, diff --git a/database/migrations/20190508101122_admin_auth_rule.php b/database/migrations/20190508101122_admin_auth_rule.php new file mode 100644 index 0000000..264ac7b --- /dev/null +++ b/database/migrations/20190508101122_admin_auth_rule.php @@ -0,0 +1,54 @@ +table('admin_auth_rule', [ + 'comment' => '权限细节' + ])->setCollation('utf8mb4_general_ci'); + $table->addColumn('url', 'string', [ + 'limit' => 80, + 'default' => '', + 'comment' => '规则唯一标识' + ])->addColumn('groupId', 'integer', [ + 'limit' => 11, + 'default' => 0, + 'signed' => false, + 'comment' => '权限所属组的ID' + ])->addColumn('auth', 'integer', [ + 'limit' => 11, + 'default' => 0, + 'signed' => false, + 'comment' => '权限数值' + ])->addColumn('status', 'integer', [ + 'limit' => 1, + 'default' => 1, + 'comment' => '状态:为1正常,为0禁用' + ])->create(); + + $table->changeColumn('id', 'integer', ['signed' => false]); + } +}