Completed
Pull Request — master (#21)
by
unknown
04:25
created

CreateSekolahsTable::up()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 22
Code Lines 19

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 1
eloc 19
nc 1
nop 0
dl 0
loc 22
rs 9.2
c 0
b 0
f 0
1
<?php
2
3
use Illuminate\Database\Migrations\Migration;
4
use Illuminate\Database\Schema\Blueprint;
5
6
class CreateSekolahsTable 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...
7
{
8
    /**
9
     * Run the migrations.
10
     *
11
     * @return void
12
     */
13
	public function up()
14
	{
15
		Schema::create('sekolahs', function(Blueprint $table) {
16
			$table->increments('id');
17
			$table->string('nama');
18
			$table->string('npsn');
19
			$table->integer('jenis_sekolah_id')->nullable();
20
			$table->string('alamat');
21
			$table->string('logo');
22
			$table->string('foto_gedung');
23
			$table->string('province_id')->nullable();
24
			$table->string('city_id')->nullable();
25
			$table->string('district_id')->nullable();
26
			$table->string('village_id')->nullable();
27
			$table->string('no_telp');
28
			$table->string('email');
29
			$table->string('kode_zona')->nullable();
30
			$table->integer('user_id')->nullable();
31
			$table->timestamps();
32
			$table->softDeletes();
33
		});
34
	}
35
36
    /**
37
     * Reverse the migrations.
38
     *
39
     * @return void
40
     */
41
	public function down()
42
	{
43
		Schema::drop('sekolahs');
44
	}
45
}
46