Completed
Push — master ( a89556...fd22b2 )
by Ariel
14:18 queued 02:32
created
src/Vacancy/VacancyTemplateBuilder.php 1 patch
Doc Comments   +3 added lines patch added patch discarded remove patch
@@ -33,6 +33,9 @@
 block discarded – undo
33 33
         $this->addStatement('  '.$startAt.' - '.$finishAt);
34 34
     }
35 35
 
36
+    /**
37
+     * @param string $statement
38
+     */
36 39
     protected function addStatement($statement)
37 40
     {
38 41
         $this->statement[] = $statement;
Please login to merge, or discard this patch.
migrations/2016_03_18_000001_create_humanresources_table.php 1 patch
Spacing   +1 added lines, -1 removed lines patch added patch discarded remove patch
@@ -12,7 +12,7 @@
 block discarded – undo
12 12
      */
13 13
     public function up()
14 14
     {
15
-        Schema::create('humanresources', function (Blueprint $table) {
15
+        Schema::create('humanresources', function(Blueprint $table) {
16 16
             $table->increments('id');
17 17
             $table->string('name');
18 18
             $table->string('slug', 50)->index();
Please login to merge, or discard this patch.
src/Models/Vacancy.php 1 patch
Indentation   +11 added lines, -11 removed lines patch added patch discarded remove patch
@@ -221,11 +221,11 @@  discard block
 block discarded – undo
221 221
     public function hasRoomBetween(Carbon $startAt, Carbon $finishAt)
222 222
     {
223 223
         return $this->capacity > $this->business
224
-                                      ->bookings()
225
-                                      ->active()
226
-                                      ->affectingInterval($startAt, $finishAt)
227
-                                      ->affectingHumanresource($this->humanresource_id)
228
-                                      ->count() &&
224
+                                        ->bookings()
225
+                                        ->active()
226
+                                        ->affectingInterval($startAt, $finishAt)
227
+                                        ->affectingHumanresource($this->humanresource_id)
228
+                                        ->count() &&
229 229
             ($this->start_at <= $startAt && $this->finish_at >= $finishAt);
230 230
     }
231 231
 
@@ -241,12 +241,12 @@  discard block
 block discarded – undo
241 241
         }
242 242
 
243 243
         $count = $this->business
244
-                      ->bookings()
245
-                      ->with('humanresource')
246
-                      ->active()
247
-                      ->affectingHumanresource($this->humanresource_id)
248
-                      ->affectingInterval($startAt, $finishAt)
249
-                      ->count();
244
+                        ->bookings()
245
+                        ->with('humanresource')
246
+                        ->active()
247
+                        ->affectingHumanresource($this->humanresource_id)
248
+                        ->affectingInterval($startAt, $finishAt)
249
+                        ->count();
250 250
 
251 251
         return $this->capacity - intval($count);
252 252
     }
Please login to merge, or discard this patch.
src/Duration.php 1 patch
Doc Comments   +4 added lines, -3 removed lines patch added patch discarded remove patch
@@ -34,7 +34,7 @@  discard block
 block discarded – undo
34 34
     /**
35 35
      * @param int $interval timestamp interval
36 36
      * @param DateTime $interval the first date
37
-     * @param DateTime $last_date the last date so we can find the interval of 
37
+     * @param \DateTime $last_date the last date so we can find the interval of 
38 38
      * the first and the last date
39 39
      *
40 40
      * @return self object
@@ -118,7 +118,7 @@  discard block
 block discarded – undo
118 118
      * @param string $format rounding method after we reveal the readable 
119 119
      * interval. You can use PHP_ROUND_HALF_UP and PHP_ROUND_HALF_DOWN
120 120
      *
121
-     * @return well formatted output
121
+     * @return string formatted output
122 122
      */
123 123
     public function format($format = [])
124 124
     {
@@ -160,6 +160,7 @@  discard block
 block discarded – undo
160 160
     /**
161 161
      * @param int $round_method rounding method after we reveal the readable 
162 162
      * interval. You can use PHP_ROUND_HALF_UP and PHP_ROUND_HALF_DOWN
163
+     * @param integer $result
163 164
      *
164 165
      * @return float current number of the result. if it is using $round_method,
165 166
      * it will rounded up or down
@@ -176,7 +177,7 @@  discard block
 block discarded – undo
176 177
     }
177 178
 
178 179
     /**
179
-     * @return well formatted output
180
+     * @return string formatted output
180 181
      */
181 182
     public function __toString()
182 183
     {
Please login to merge, or discard this patch.
src/Models/Appointment.php 1 patch
Spacing   +6 added lines, -6 removed lines patch added patch discarded remove patch
@@ -440,11 +440,11 @@  discard block
 block discarded – undo
440 440
         $carbon = Carbon::parse('today midnight')->timezone('UTC');
441 441
 
442 442
         return $query
443
-            ->where(function ($query) use ($carbon) {
443
+            ->where(function($query) use ($carbon) {
444 444
 
445 445
                 $query->whereIn('status', [Self::STATUS_RESERVED, Self::STATUS_CONFIRMED])
446 446
                     ->where('start_at', '<=', $carbon)
447
-                    ->orWhere(function ($query) use ($carbon) {
447
+                    ->orWhere(function($query) use ($carbon) {
448 448
                         $query->where('start_at', '>=', $carbon);
449 449
                     });
450 450
             });
@@ -532,17 +532,17 @@  discard block
 block discarded – undo
532 532
         $finishAt->timezone('UTC');
533 533
 
534 534
         return $query
535
-            ->where(function ($query) use ($startAt, $finishAt) {
535
+            ->where(function($query) use ($startAt, $finishAt) {
536 536
 
537
-                $query->where(function ($query) use ($startAt, $finishAt) {
537
+                $query->where(function($query) use ($startAt, $finishAt) {
538 538
                     $query->where('finish_at', '>=', $finishAt)
539 539
                             ->where('start_at', '<', $startAt);
540 540
                 })
541
-                ->orWhere(function ($query) use ($startAt, $finishAt) {
541
+                ->orWhere(function($query) use ($startAt, $finishAt) {
542 542
                     $query->where('finish_at', '<=', $finishAt)
543 543
                             ->where('finish_at', '>', $startAt);
544 544
                 })
545
-                ->orWhere(function ($query) use ($startAt, $finishAt) {
545
+                ->orWhere(function($query) use ($startAt, $finishAt) {
546 546
                     $query->where('start_at', '>=', $startAt)
547 547
                             ->where('start_at', '<', $finishAt);
548 548
                 });
Please login to merge, or discard this patch.
src/Presenters/BusinessPresenter.php 1 patch
Spacing   +2 added lines, -3 removed lines patch added patch discarded remove patch
@@ -23,7 +23,7 @@  discard block
 block discarded – undo
23 23
     {
24 24
         $url = parse_url($this->wrappedObject->social_facebook);
25 25
 
26
-        if(!$this->wrappedObject->social_facebook || !array_key_exists('path', $url)){
26
+        if (!$this->wrappedObject->social_facebook || !array_key_exists('path', $url)) {
27 27
             return "<img class=\"img-thumbnail\" src=\"//placehold.it/100x100\" alt=\"{$this->wrappedObject->name}\"/>";
28 28
         }
29 29
 
@@ -69,8 +69,7 @@  discard block
 block discarded – undo
69 69
      */
70 70
     public function industryIcon()
71 71
     {
72
-        $src = ($this->wrappedObject->pref('cover_photo_url')) ?:
73
-            asset('/img/industries/'.$this->wrappedObject->category->slug.'.png');
72
+        $src = ($this->wrappedObject->pref('cover_photo_url')) ?: asset('/img/industries/'.$this->wrappedObject->category->slug.'.png');
74 73
 
75 74
         return "<img class=\"img-responsive center-block\" src=\"{$src}\"/>";
76 75
     }
Please login to merge, or discard this patch.
src/Concierge.php 1 patch
Indentation   +5 added lines, -5 removed lines patch added patch discarded remove patch
@@ -73,11 +73,11 @@
 block discarded – undo
73 73
         $comments = $request['comments'];
74 74
 
75 75
         $vacancies = $this->calendar()
76
-                          ->forService($service->id)
77
-                          ->withDuration($service->duration)
78
-                          ->forDate($request['date'])
79
-                          ->atTime($request['time'], $request['timezone'])
80
-                          ->find();
76
+                            ->forService($service->id)
77
+                            ->withDuration($service->duration)
78
+                            ->forDate($request['date'])
79
+                            ->atTime($request['time'], $request['timezone'])
80
+                            ->find();
81 81
 
82 82
         if ($vacancies->count() == 0) {
83 83
             // TODO: Log failure feedback message / raise exception
Please login to merge, or discard this patch.
src/Presenters/AppointmentPresenter.php 1 patch
Indentation   +8 added lines, -8 removed lines patch added patch discarded remove patch
@@ -66,16 +66,16 @@
 block discarded – undo
66 66
         }
67 67
 
68 68
         $fromTime = $this->wrappedObject
69
-                         ->vacancy
70
-                         ->start_at
71
-                         ->timezone($this->timezone)
72
-                         ->format($timeFormat);
69
+                            ->vacancy
70
+                            ->start_at
71
+                            ->timezone($this->timezone)
72
+                            ->format($timeFormat);
73 73
 
74 74
         $toTime = $this->wrappedObject
75
-                       ->vacancy
76
-                       ->finish_at
77
-                       ->timezone($this->timezone)
78
-                       ->format($timeFormat);
75
+                        ->vacancy
76
+                        ->finish_at
77
+                        ->timezone($this->timezone)
78
+                        ->format($timeFormat);
79 79
 
80 80
         return ['from' => $fromTime, 'to' => $toTime];
81 81
     }
Please login to merge, or discard this patch.