CreateApiManagerTable   A
last analyzed

Complexity

Total Complexity 2

Size/Duplication

Total Lines 21
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

Changes 0
Metric Value
wmc 2
c 0
b 0
f 0
lcom 0
cbo 1
dl 0
loc 21
rs 10

2 Methods

Rating   Name   Duplication   Size   Complexity  
A up() 0 13 1
A down() 0 4 1
1
<?php
2
3
/**
4
 * @Author: bantenprov
5
 * @Date:   2017-11-28 00:54:01
6
 * @Last Modified by:   bantenprov
7
 * @Last Modified time: 2017-11-28 00:54:10
8
 */
9
10
use Illuminate\Support\Facades\Schema;
11
use Illuminate\Database\Migrations\Migration;
12
use Illuminate\Database\Schema\Blueprint;
13
14
class CreateApiManagerTable 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...
15
16
	public function up()
17
	{
18
		Schema::create('api_keys', function(Blueprint $table) {
19
			$table->increments('id');
20
			$table->timestamps();
21
			$table->softDeletes();
22
			$table->integer('user_id');
23
			$table->string('client', 225);
24
			$table->string('api_key', 255);
25
			$table->text('description');
26
			$table->integer('is_published')->default('1');
27
		});
28
	}
29
30
	public function down()
31
	{
32
		Schema::drop('api_keys');
33
	}
34
}
35