add role to users
This commit is contained in:
parent
143d3bc82f
commit
06eaa1b464
2 changed files with 34 additions and 3 deletions
5
motorradig/.idea/workspace.xml
generated
5
motorradig/.idea/workspace.xml
generated
|
|
@ -2,9 +2,8 @@
|
|||
<project version="4">
|
||||
<component name="ChangeListManager">
|
||||
<list default="true" id="eed7de89-f054-487c-bf59-36356758942b" name="Default Changelist" comment="">
|
||||
<change afterPath="$PROJECT_DIR$/app/Http/Controllers/AuthController.php" afterDir="false" />
|
||||
<change afterPath="$PROJECT_DIR$/database/migrations/2020_01_21_084547_add_role_to_users.php" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/.idea/workspace.xml" beforeDir="false" afterPath="$PROJECT_DIR$/.idea/workspace.xml" afterDir="false" />
|
||||
<change beforePath="$PROJECT_DIR$/routes/api.php" beforeDir="false" afterPath="$PROJECT_DIR$/routes/api.php" afterDir="false" />
|
||||
</list>
|
||||
<option name="SHOW_DIALOG" value="false" />
|
||||
<option name="HIGHLIGHT_CONFLICTS" value="true" />
|
||||
|
|
@ -207,7 +206,7 @@
|
|||
<workItem from="1575965115540" duration="593000" />
|
||||
<workItem from="1575966299565" duration="383000" />
|
||||
<workItem from="1579075615585" duration="8354000" />
|
||||
<workItem from="1579595422946" duration="450000" />
|
||||
<workItem from="1579595422946" duration="957000" />
|
||||
</task>
|
||||
<servers />
|
||||
</component>
|
||||
|
|
|
|||
|
|
@ -0,0 +1,32 @@
|
|||
<?php
|
||||
|
||||
use Illuminate\Database\Migrations\Migration;
|
||||
use Illuminate\Database\Schema\Blueprint;
|
||||
use Illuminate\Support\Facades\Schema;
|
||||
|
||||
class AddRoleToUsers extends Migration
|
||||
{
|
||||
/**
|
||||
* Run the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function up()
|
||||
{
|
||||
Schema::table('users', function (Blueprint $table) {
|
||||
$table->string('role')->default('GUEST');
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* Reverse the migrations.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function down()
|
||||
{
|
||||
Schema::table('users', function (Blueprint $table) {
|
||||
//
|
||||
});
|
||||
}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue