0
database/migrations/.gitkeep
Executable file → Normal file
0
database/migrations/.gitkeep
Executable file → Normal file
0
database/migrations/2022_03_07_180241_remove_account_tokens_from_user.php
Executable file → Normal file
0
database/migrations/2022_03_07_180241_remove_account_tokens_from_user.php
Executable file → Normal file
@@ -1,34 +0,0 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::table('users', function (Blueprint $table) {
|
||||
$table->renameColumn('originalIP', 'currentIp');
|
||||
$table->ipAddress('registrationIp')->after('originalIP');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::table('users', function (Blueprint $table) {
|
||||
$table->renameColumn('currentIp', 'originalIP');
|
||||
$table->removeColumn('ipAddress');
|
||||
});
|
||||
}
|
||||
};
|
@@ -1,41 +0,0 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
return new class extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::table('users', function (Blueprint $table) {
|
||||
|
||||
$table->string('password')->nullable()->change(); // social login requires no pw (still required upon normal reg)
|
||||
$table->string('registrationIp')->nullable()->change();
|
||||
|
||||
$table->unsignedBigInteger('discord_user_id')->after('remember_token')->nullable();
|
||||
$table->longText('discord_token')->after('discord_user_id')->nullable();
|
||||
$table->longText('discord_refresh_token')->after('discord_token')->nullable();
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::table('users', function (Blueprint $table) {
|
||||
$table->dropColumn('discord_token', 'discord_refresh_token', 'discord_user_id');
|
||||
|
||||
$table->string('password')->nullable(false)->change();
|
||||
$table->string('registrationIp')->nullable(false)->change();
|
||||
});
|
||||
}
|
||||
};
|
@@ -1,22 +0,0 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
class AddIntProfilePicToUsers extends Migration
|
||||
{
|
||||
public function up()
|
||||
{
|
||||
Schema::table('users', function (Blueprint $table) {
|
||||
$table->longText('discord_pfp')->after('discord_user_id')->nullable();
|
||||
});
|
||||
}
|
||||
|
||||
public function down()
|
||||
{
|
||||
Schema::table('users', function (Blueprint $table) {
|
||||
$table->dropColumn('discord_pfp');
|
||||
});
|
||||
}
|
||||
}
|
@@ -1,22 +0,0 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
class AddLocaleToUsers extends Migration
|
||||
{
|
||||
public function up()
|
||||
{
|
||||
Schema::table('users', function (Blueprint $table) {
|
||||
$table->string('locale')->after('email')->default('en-US');
|
||||
});
|
||||
}
|
||||
|
||||
public function down()
|
||||
{
|
||||
Schema::table('users', function (Blueprint $table) {
|
||||
$table->dropColumn('locale');
|
||||
});
|
||||
}
|
||||
}
|
@@ -1,24 +0,0 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
class UpdateVacancyIntegrationNullable extends Migration
|
||||
{
|
||||
public function up()
|
||||
{
|
||||
Schema::table('vacancies', function (Blueprint $table) {
|
||||
$table->string('permissionGroupName')->nullable()->change();
|
||||
$table->string('discordRoleID')->nullable()->change();
|
||||
});
|
||||
}
|
||||
|
||||
public function down()
|
||||
{
|
||||
Schema::table('vacancies', function (Blueprint $table) {
|
||||
$table->string('permissionGroupName')->nullable(false)->change();
|
||||
$table->string('discordRoleID')->nullable(false)->change();
|
||||
});
|
||||
}
|
||||
}
|
@@ -1,24 +0,0 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
class AddDiscordRequirementToVacancies extends Migration
|
||||
{
|
||||
public function up()
|
||||
{
|
||||
Schema::table('vacancies', function (Blueprint $table) {
|
||||
$table->boolean('requiresDiscord')
|
||||
->default(false)
|
||||
->after('vacancyStatus');
|
||||
});
|
||||
}
|
||||
|
||||
public function down()
|
||||
{
|
||||
Schema::table('vacancies', function (Blueprint $table) {
|
||||
$table->dropColumn('requiresDiscord');
|
||||
});
|
||||
}
|
||||
}
|
@@ -1,22 +0,0 @@
|
||||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
class AddRequiredAgeToVacancies extends Migration
|
||||
{
|
||||
public function up()
|
||||
{
|
||||
Schema::table('vacancies', function (Blueprint $table) {
|
||||
$table->integer('requiredAge')->default(16)->after('vacancyStatus');
|
||||
});
|
||||
}
|
||||
|
||||
public function down()
|
||||
{
|
||||
Schema::table('vacancies', function (Blueprint $table) {
|
||||
$table->dropColumn('requiredAge');
|
||||
});
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user