mirror of
https://github.com/NNTmux/newznab-tmux.git
synced 2026-08-28 17:01:16 +00:00
Remove tags related migrations
This commit is contained in:
@@ -1,27 +0,0 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
|
||||
class CreateTaggedTable extends Migration
|
||||
{
|
||||
public function up()
|
||||
{
|
||||
Schema::create('tagging_tagged', function (Blueprint $table) {
|
||||
$table->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');
|
||||
}
|
||||
}
|
||||
@@ -1,23 +0,0 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
|
||||
class CreateTagsTable extends Migration
|
||||
{
|
||||
public function up()
|
||||
{
|
||||
Schema::create('tagging_tags', function (Blueprint $table) {
|
||||
$table->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
|
||||
});
|
||||
}
|
||||
|
||||
public function down()
|
||||
{
|
||||
Schema::drop('tagging_tags');
|
||||
}
|
||||
}
|
||||
@@ -1,21 +0,0 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
|
||||
class CreateTagGroupsTable extends Migration
|
||||
{
|
||||
public function up()
|
||||
{
|
||||
Schema::create('tagging_tag_groups', function (Blueprint $table) {
|
||||
$table->increments('id');
|
||||
$table->string('slug', 125)->index();
|
||||
$table->string('name', 125);
|
||||
});
|
||||
}
|
||||
|
||||
public function down()
|
||||
{
|
||||
Schema::drop('tagging_tag_groups');
|
||||
}
|
||||
}
|
||||
@@ -1,22 +0,0 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class UpdateTagsTable extends Migration
|
||||
{
|
||||
public function up()
|
||||
{
|
||||
Schema::table('tagging_tags', function ($table) {
|
||||
$table->integer('tag_group_id')->unsigned()->nullable()->after('id');
|
||||
$table->foreign('tag_group_id')->references('id')->on('tagging_tag_groups');
|
||||
});
|
||||
}
|
||||
|
||||
public function down()
|
||||
{
|
||||
Schema::table('tagging_tags', function ($table) {
|
||||
$table->dropForeign('tagging_tags_tag_group_id_foreign');
|
||||
$table->dropColumn('tag_group_id');
|
||||
});
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user