|
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 |
|
|
|
|
|
|
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
|
|
|
|
You can fix this by adding a namespace to your class:
When choosing a vendor namespace, try to pick something that is not too generic to avoid conflicts with other libraries.