mirror of
https://github.com/snipe/snipe-it.git
synced 2024-12-25 05:34:06 -08:00
Migration for for email/username format settings
This commit is contained in:
parent
e0c07d8921
commit
33a35ec7f5
|
@ -0,0 +1,37 @@
|
|||
<?php
|
||||
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
|
||||
class AddEmailDomainAndFormatToSettings extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::table('settings', function (Blueprint $table) {
|
||||
$table->string('email_domain')->nullable()->default(NULL);
|
||||
$table->string('email_format')->nullable()->default('filastname');
|
||||
$table->string('username_format')->nullable()->default('filastname');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::table('settings', function ($table) {
|
||||
$table->dropColumn(
|
||||
'email_domain',
|
||||
'email_format',
|
||||
'username_format'
|
||||
);
|
||||
});
|
||||
}
|
||||
}
|
Loading…
Reference in a new issue