CreateGoogleUsersTable::up()   B
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 29
Code Lines 26

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 26
nc 1
nop 0
dl 0
loc 29
rs 8.8571
c 0
b 0
f 0
1
<?php
2
3
use Illuminate\Support\Facades\Schema;
4
use Illuminate\Database\Schema\Blueprint;
5
use Illuminate\Database\Migrations\Migration;
6
7
/**
8
 * Class CreateProgressBatchesTable.
9
 */
10
class CreateGoogleUsersTable extends Migration
0 ignored issues
show
Coding Style Compatibility introduced by
PSR1 recommends that each class must be in a namespace of at least one level to avoid collisions.

You can fix this by adding a namespace to your class:

namespace YourVendor;

class YourClass { }

When choosing a vendor namespace, try to pick something that is not too generic to avoid conflicts with other libraries.

Loading history...
11
{
12
    /**
13
     * Run the migrations.
14
     *
15
     * @return void
16
     */
17
    public function up()
18
    {
19
        Schema::create('google_users', function (Blueprint $table) {
20
            $table->increments('id');
21
            $table->string('customerId');
22
            $table->string('kind');
23
            $table->integer('google_id')->unsigned()->nullable();
24
            $table->string('etag');
25
            $table->string('primaryEmail')->unique();
26
            $table->string('givenName');
27
            $table->string('familyName');
28
            $table->string('fullName');
29
            $table->string('orgUnitPath');
30
            $table->json('organizations')->nullable();
31
            $table->boolean('isAdmin');
32
            $table->boolean('isDelegatedAdmin');
33
            $table->dateTime('lastLoginTime');
34
            $table->dateTime('creationTime');
35
            $table->dateTime('deletionTime')->nullable();
36
            $table->dateTime('agreedToTerms');
37
            $table->string('password')->nullable();
38
            $table->string('hashFunction')->nullable();
39
            $table->boolean('suspended');
40
            $table->string('suspensionReason')->nullable();
41
            $table->boolean('changePasswordAtNextLogin');
42
            $table->json('emails');
43
            $table->timestamps();
44
        });
45
    }
46
47
    /**
48
     * Reverse the migrations.
49
     *
50
     * @return void
51
     */
52
    public function down()
53
    {
54
        Schema::dropIfExists('google_users');
55
    }
56
}
57