From 01f82ce0b79e9b29b76eed915805050c892bb464 Mon Sep 17 00:00:00 2001 From: Ludovic CANDELLIER Date: Wed, 15 Apr 2020 15:51:19 +0200 Subject: [PATCH] Remove existing migration in packages --- .../2014_01_07_073615_create_tagged_table.php | 25 ------ .../2014_01_07_073615_create_tags_table.php | 24 ----- .../2014_10_12_000000_create_users_table.php | 36 -------- ...12_100000_create_password_resets_table.php | 32 ------- ...6_06_29_073615_create_tag_groups_table.php | 21 ----- .../2016_06_29_073615_update_tags_table.php | 24 ----- ..._070520_add_verification_to_user_table.php | 50 ----------- ...000000_create_authentication_log_table.php | 35 -------- ..._08_19_000000_create_failed_jobs_table.php | 35 -------- .../2020_03_28_223351_create_media_table.php | 38 -------- ...020_03_28_223351_teamwork_setup_tables.php | 87 ------------------- ...03_29_100655_create_activity_log_table.php | 38 -------- 12 files changed, 445 deletions(-) delete mode 100644 database/migrations/2014_01_07_073615_create_tagged_table.php delete mode 100644 database/migrations/2014_01_07_073615_create_tags_table.php delete mode 100644 database/migrations/2014_10_12_000000_create_users_table.php delete mode 100644 database/migrations/2014_10_12_100000_create_password_resets_table.php delete mode 100644 database/migrations/2016_06_29_073615_create_tag_groups_table.php delete mode 100644 database/migrations/2016_06_29_073615_update_tags_table.php delete mode 100644 database/migrations/2016_09_13_070520_add_verification_to_user_table.php delete mode 100644 database/migrations/2017_09_01_000000_create_authentication_log_table.php delete mode 100644 database/migrations/2019_08_19_000000_create_failed_jobs_table.php delete mode 100644 database/migrations/2020_03_28_223351_create_media_table.php delete mode 100644 database/migrations/2020_03_28_223351_teamwork_setup_tables.php delete mode 100644 database/migrations/2020_03_29_100655_create_activity_log_table.php diff --git a/database/migrations/2014_01_07_073615_create_tagged_table.php b/database/migrations/2014_01_07_073615_create_tagged_table.php deleted file mode 100644 index ce36b565..00000000 --- a/database/migrations/2014_01_07_073615_create_tagged_table.php +++ /dev/null @@ -1,25 +0,0 @@ -increments('id'); - if(config('tagging.primary_keys_type') == 'string') { - $table->string('taggable_id', 36)->index(); - } else { - $table->integer('taggable_id')->unsigned()->index(); - } - $table->string('taggable_type', 125)->index(); - $table->string('tag_name', 125); - $table->string('tag_slug', 125)->index(); - }); - } - - public function down() { - Schema::drop('tagging_tagged'); - } -} diff --git a/database/migrations/2014_01_07_073615_create_tags_table.php b/database/migrations/2014_01_07_073615_create_tags_table.php deleted file mode 100644 index 1a3a7474..00000000 --- a/database/migrations/2014_01_07_073615_create_tags_table.php +++ /dev/null @@ -1,24 +0,0 @@ -increments('id'); - $table->string('slug', 125)->index(); - $table->string('name', 125); - $table->boolean('suggest')->default(false); - $table->integer('count')->unsigned()->default(0); // count of how many times this tag was used - $table->integer('tag_group_id')->unsigned()->nullable(); - }); - } - - public function down() - { - Schema::drop('tagging_tags'); - } -} diff --git a/database/migrations/2014_10_12_000000_create_users_table.php b/database/migrations/2014_10_12_000000_create_users_table.php deleted file mode 100644 index a91e1d3c..00000000 --- a/database/migrations/2014_10_12_000000_create_users_table.php +++ /dev/null @@ -1,36 +0,0 @@ -bigIncrements('id'); - $table->string('name'); - $table->string('email')->unique(); - $table->timestamp('email_verified_at')->nullable(); - $table->string('password'); - $table->rememberToken(); - $table->timestamps(); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::dropIfExists('users'); - } -} diff --git a/database/migrations/2014_10_12_100000_create_password_resets_table.php b/database/migrations/2014_10_12_100000_create_password_resets_table.php deleted file mode 100644 index 0ee0a36a..00000000 --- a/database/migrations/2014_10_12_100000_create_password_resets_table.php +++ /dev/null @@ -1,32 +0,0 @@ -string('email')->index(); - $table->string('token'); - $table->timestamp('created_at')->nullable(); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::dropIfExists('password_resets'); - } -} diff --git a/database/migrations/2016_06_29_073615_create_tag_groups_table.php b/database/migrations/2016_06_29_073615_create_tag_groups_table.php deleted file mode 100644 index 558e85f3..00000000 --- a/database/migrations/2016_06_29_073615_create_tag_groups_table.php +++ /dev/null @@ -1,21 +0,0 @@ -increments('id'); - $table->string('slug', 125)->index(); - $table->string('name', 125); - }); - } - - public function down() - { - Schema::drop('tagging_tag_groups'); - } -} diff --git a/database/migrations/2016_06_29_073615_update_tags_table.php b/database/migrations/2016_06_29_073615_update_tags_table.php deleted file mode 100644 index 7c58ec76..00000000 --- a/database/migrations/2016_06_29_073615_update_tags_table.php +++ /dev/null @@ -1,24 +0,0 @@ -foreign('tag_group_id')->references('id')->on('tagging_tag_groups'); - }); - - } - - - public function down() - { - Schema::disableForeignKeyConstraints(); - Schema::table('tagging_tags', function ($table) { - $table->dropForeign('tagging_tags_tag_group_id_foreign'); - }); - } -} diff --git a/database/migrations/2016_09_13_070520_add_verification_to_user_table.php b/database/migrations/2016_09_13_070520_add_verification_to_user_table.php deleted file mode 100644 index f3d1ff1a..00000000 --- a/database/migrations/2016_09_13_070520_add_verification_to_user_table.php +++ /dev/null @@ -1,50 +0,0 @@ - - */ - -use Illuminate\Database\Migrations\Migration; -use Illuminate\Database\Schema\Blueprint; - -class AddVerificationToUserTable extends Migration -{ - /** - * Determine the user table name. - * - * @return string - */ - public function getUserTableName() - { - $user_model = config('auth.providers.users.model', App\User::class); - - return (new $user_model)->getTable(); - } - - /** - * Run the migrations. - * - * @return void - */ - public function up() - { - Schema::table($this->getUserTableName(), function (Blueprint $table) { - $table->boolean('verified')->default(false); - $table->string('verification_token')->nullable(); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::table($this->getUserTableName(), function (Blueprint $table) { - $table->dropColumn('verified'); - $table->dropColumn('verification_token'); - }); - } -} diff --git a/database/migrations/2017_09_01_000000_create_authentication_log_table.php b/database/migrations/2017_09_01_000000_create_authentication_log_table.php deleted file mode 100644 index 412f821e..00000000 --- a/database/migrations/2017_09_01_000000_create_authentication_log_table.php +++ /dev/null @@ -1,35 +0,0 @@ -bigIncrements('id'); - $table->morphs('authenticatable'); - $table->string('ip_address', 45)->nullable(); - $table->text('user_agent')->nullable(); - $table->timestamp('login_at')->nullable(); - $table->timestamp('logout_at')->nullable(); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::dropIfExists('authentication_log'); - } -} diff --git a/database/migrations/2019_08_19_000000_create_failed_jobs_table.php b/database/migrations/2019_08_19_000000_create_failed_jobs_table.php deleted file mode 100644 index 389bdf76..00000000 --- a/database/migrations/2019_08_19_000000_create_failed_jobs_table.php +++ /dev/null @@ -1,35 +0,0 @@ -bigIncrements('id'); - $table->text('connection'); - $table->text('queue'); - $table->longText('payload'); - $table->longText('exception'); - $table->timestamp('failed_at')->useCurrent(); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::dropIfExists('failed_jobs'); - } -} diff --git a/database/migrations/2020_03_28_223351_create_media_table.php b/database/migrations/2020_03_28_223351_create_media_table.php deleted file mode 100644 index 139ec806..00000000 --- a/database/migrations/2020_03_28_223351_create_media_table.php +++ /dev/null @@ -1,38 +0,0 @@ -bigIncrements('id'); - $table->morphs('model'); - $table->string('collection_name'); - $table->string('name'); - $table->string('file_name'); - $table->string('mime_type')->nullable(); - $table->string('disk'); - $table->unsignedBigInteger('size'); - $table->json('manipulations'); - $table->json('custom_properties'); - $table->json('responsive_images'); - $table->unsignedInteger('order_column')->nullable(); - $table->nullableTimestamps(); - }); - } - - /** - * Reverse the migrations. - */ - public function down() - { - Schema::dropIfExists('media'); - } -} diff --git a/database/migrations/2020_03_28_223351_teamwork_setup_tables.php b/database/migrations/2020_03_28_223351_teamwork_setup_tables.php deleted file mode 100644 index 5e2fdca1..00000000 --- a/database/migrations/2020_03_28_223351_teamwork_setup_tables.php +++ /dev/null @@ -1,87 +0,0 @@ -integer( 'current_team_id' )->unsigned()->nullable(); - } ); - - - Schema::create( \Config::get( 'teamwork.teams_table' ), function ( Blueprint $table ) - { - $table->increments( 'id' )->unsigned(); - $table->integer( 'owner_id' )->unsigned()->nullable(); - $table->string( 'name' ); - $table->timestamps(); - } ); - - Schema::create( \Config::get( 'teamwork.team_user_table' ), function ( Blueprint $table ) - { - $table->bigInteger( 'user_id' )->unsigned(); - $table->integer( 'team_id' )->unsigned(); - $table->timestamps(); - - $table->foreign( 'user_id' ) - ->references( \Config::get( 'teamwork.user_foreign_key' ) ) - ->on( \Config::get( 'teamwork.users_table' ) ) - ->onUpdate( 'cascade' ) - ->onDelete( 'cascade' ); - - $table->foreign( 'team_id' ) - ->references( 'id' ) - ->on( \Config::get( 'teamwork.teams_table' ) ) - ->onDelete( 'cascade' ); - } ); - - Schema::create( \Config::get( 'teamwork.team_invites_table' ), function(Blueprint $table) - { - $table->increments('id'); - $table->bigInteger('user_id')->unsigned(); - $table->integer('team_id')->unsigned(); - $table->enum('type', ['invite', 'request']); - $table->string('email'); - $table->string('accept_token'); - $table->string('deny_token'); - $table->timestamps(); - $table->foreign( 'team_id' ) - ->references( 'id' ) - ->on( \Config::get( 'teamwork.teams_table' ) ) - ->onDelete( 'cascade' ); - }); - } - - /** - * Reverse the migrations. - * - * @return void - */ - public function down() - { - Schema::table(\Config::get( 'teamwork.users_table' ), function(Blueprint $table) - { - $table->dropColumn('current_team_id'); - }); - - Schema::table(\Config::get('teamwork.team_user_table'), function (Blueprint $table) { - $table->dropForeign(\Config::get('teamwork.team_user_table').'_user_id_foreign'); - $table->dropForeign(\Config::get('teamwork.team_user_table').'_team_id_foreign'); - }); - - Schema::drop(\Config::get('teamwork.team_user_table')); - Schema::drop(\Config::get('teamwork.team_invites_table')); - Schema::drop(\Config::get('teamwork.teams_table')); - - } -} diff --git a/database/migrations/2020_03_29_100655_create_activity_log_table.php b/database/migrations/2020_03_29_100655_create_activity_log_table.php deleted file mode 100644 index 4f0f9432..00000000 --- a/database/migrations/2020_03_29_100655_create_activity_log_table.php +++ /dev/null @@ -1,38 +0,0 @@ -create(config('activitylog.table_name'), function (Blueprint $table) { - $table->bigIncrements('id'); - $table->string('log_name')->nullable(); - $table->text('description'); - $table->unsignedBigInteger('subject_id')->nullable(); - $table->string('subject_type')->nullable(); - $table->unsignedBigInteger('causer_id')->nullable(); - $table->string('causer_type')->nullable(); - $table->json('properties')->nullable(); - $table->timestamps(); - - $table->index('log_name'); - $table->index(['subject_id', 'subject_type'], 'subject'); - $table->index(['causer_id', 'causer_type'], 'causer'); - }); - } - - /** - * Reverse the migrations. - */ - public function down() - { - Schema::connection(config('activitylog.database_connection'))->dropIfExists(config('activitylog.table_name')); - } -}