@@ -22,8 +22,8 @@ |
||
| 22 | 22 | 'Bass Guitars', |
| 23 | 23 | 'Double-neck Guitars', |
| 24 | 24 | ]); |
| 25 | - $makes->each(function ($name) { |
|
| 26 | - factory(App\Make::class)->create(['name' => $name]); |
|
| 25 | + $makes->each(function($name) { |
|
| 26 | + factory(App\Make::class)->create([ 'name' => $name ]); |
|
| 27 | 27 | }); |
| 28 | 28 | } |
| 29 | 29 | } |
@@ -96,7 +96,7 @@ |
||
| 96 | 96 | | |
| 97 | 97 | */ |
| 98 | 98 | |
| 99 | - 'lottery' => [2, 100], |
|
| 99 | + 'lottery' => [ 2, 100 ], |
|
| 100 | 100 | |
| 101 | 101 | /* |
| 102 | 102 | |-------------------------------------------------------------------------- |
@@ -54,7 +54,7 @@ |
||
| 54 | 54 | | |
| 55 | 55 | */ |
| 56 | 56 | |
| 57 | - 'from' => ['address' => null, 'name' => null], |
|
| 57 | + 'from' => [ 'address' => null, 'name' => null ], |
|
| 58 | 58 | |
| 59 | 59 | /* |
| 60 | 60 | |-------------------------------------------------------------------------- |
@@ -12,7 +12,7 @@ |
||
| 12 | 12 | */ |
| 13 | 13 | public function up() |
| 14 | 14 | { |
| 15 | - Schema::create('notifications', function (Blueprint $table) { |
|
| 15 | + Schema::create('notifications', function(Blueprint $table) { |
|
| 16 | 16 | $table->increments('id'); |
| 17 | 17 | $table->string('icon')->nullable(); |
| 18 | 18 | $table->string('link')->nullable(); |
@@ -38,7 +38,7 @@ discard block |
||
| 38 | 38 | { |
| 39 | 39 | $this->validate($request, $this->rules($request->input('supplier_id'))); |
| 40 | 40 | $purchase = $this->getSupplier($request)->makePurchase( |
| 41 | - $request->only(['id', 'make_id', 'quantity', 'price', 'date_purchased', 'delivery_date']) |
|
| 41 | + $request->only([ 'id', 'make_id', 'quantity', 'price', 'date_purchased', 'delivery_date' ]) |
|
| 42 | 42 | ); |
| 43 | 43 | event(new PurchaseWasCreated($purchase)); |
| 44 | 44 | } |
@@ -75,7 +75,7 @@ discard block |
||
| 75 | 75 | 'supplier.location' => 'required_if:supplier_id,new|string|max:255' |
| 76 | 76 | ]; |
| 77 | 77 | if ($supplierId != 'new') { |
| 78 | - $rules += ['supplier_id' => 'required|integer|exists:suppliers,id']; |
|
| 78 | + $rules += [ 'supplier_id' => 'required|integer|exists:suppliers,id' ]; |
|
| 79 | 79 | } |
| 80 | 80 | |
| 81 | 81 | return $rules; |
@@ -38,7 +38,7 @@ |
||
| 38 | 38 | 'name' => 'required|string|max:255' |
| 39 | 39 | ]); |
| 40 | 40 | |
| 41 | - $make = Make::create($request->only(['name'])); |
|
| 41 | + $make = Make::create($request->only([ 'name' ])); |
|
| 42 | 42 | event(new MakeWasCreated($make)); |
| 43 | 43 | } |
| 44 | 44 | |
@@ -39,7 +39,7 @@ |
||
| 39 | 39 | 'location' => 'required|string|max:255', |
| 40 | 40 | ]); |
| 41 | 41 | |
| 42 | - $supplier = Supplier::create($request->only(['name', 'location'])); |
|
| 42 | + $supplier = Supplier::create($request->only([ 'name', 'location' ])); |
|
| 43 | 43 | event(new SupplierWasCreated($supplier)); |
| 44 | 44 | } |
| 45 | 45 | |
@@ -11,7 +11,7 @@ discard block |
||
| 11 | 11 | * |
| 12 | 12 | * @var array |
| 13 | 13 | */ |
| 14 | - protected $guarded = []; |
|
| 14 | + protected $guarded = [ ]; |
|
| 15 | 15 | |
| 16 | 16 | /** |
| 17 | 17 | * @return \Illuminate\Database\Eloquent\Relations\MorphTo |
@@ -47,6 +47,6 @@ discard block |
||
| 47 | 47 | */ |
| 48 | 48 | public function dismiss() |
| 49 | 49 | { |
| 50 | - return $this->update(['dismissed' => true]); |
|
| 50 | + return $this->update([ 'dismissed' => true ]); |
|
| 51 | 51 | } |
| 52 | 52 | } |
@@ -40,7 +40,7 @@ |
||
| 40 | 40 | $purchase = Purchase::findOrFail($id); |
| 41 | 41 | |
| 42 | 42 | return fractal()->item($purchase, new PurchaseTransformer) |
| 43 | - ->parseIncludes(['guitars', 'supplier']) |
|
| 43 | + ->parseIncludes([ 'guitars', 'supplier' ]) |
|
| 44 | 44 | ->toArray(); |
| 45 | 45 | } |
| 46 | 46 | } |