From ef86c0273a907f6e43e4f60c5e32ffc18556c447 Mon Sep 17 00:00:00 2001 From: snipe Date: Thu, 23 Jun 2022 17:17:38 -0700 Subject: [PATCH] Added migration to store admin ID Signed-off-by: snipe --- ...2022_06_23_164407_add_user_id_to_users.php | 34 +++++++++++++++++++ 1 file changed, 34 insertions(+) create mode 100644 database/migrations/2022_06_23_164407_add_user_id_to_users.php diff --git a/database/migrations/2022_06_23_164407_add_user_id_to_users.php b/database/migrations/2022_06_23_164407_add_user_id_to_users.php new file mode 100644 index 0000000000..04a7bf68af --- /dev/null +++ b/database/migrations/2022_06_23_164407_add_user_id_to_users.php @@ -0,0 +1,34 @@ +integer('created_by')->after('activated')->nullable()->default(null); + }); + } + + /** + * Reverse the migrations. + * + * @return void + */ + public function down() + { + Schema::table('users', function (Blueprint $table) { + if (Schema::hasColumn('users', 'created_by')) { + $table->dropColumn('created_by'); + } + }); + } +}