Conditions | 1 |
Paths | 1 |
Total Lines | 17 |
Code Lines | 14 |
Lines | 0 |
Ratio | 0 % |
Changes | 2 | ||
Bugs | 0 | Features | 2 |
1 | <?php |
||
13 | public function up() |
||
14 | { |
||
15 | Schema::create('guitars', function (Blueprint $table) { |
||
16 | $table->increments('id'); |
||
17 | $table->integer('purchase_id')->unsigned(); |
||
18 | $table->foreign('purchase_id')->references('id')->on('purchases')->onDelete('cascade'); |
||
19 | $table->integer('rack_id')->unsigned(); |
||
20 | $table->foreign('rack_id')->references('id')->on('racks')->onDelete('cascade'); |
||
21 | $table->integer('make_id')->unsigned(); |
||
22 | $table->foreign('make_id')->references('id')->on('makes')->onDelete('cascade'); |
||
23 | $table->integer('model_id')->unsigned(); |
||
24 | $table->foreign('model_id')->references('id')->on('models')->onDelete('cascade'); |
||
25 | $table->string('colour'); |
||
26 | $table->boolean('damaged')->default(false); |
||
27 | $table->string('condition')->nullable(); |
||
28 | }); |
||
29 | } |
||
30 | |||
41 |
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.