@@ -121,10 +121,10 @@ |
||
| 121 | 121 | $fullName = 'system'; |
| 122 | 122 | } elseif ($this->attributes['nickname']) { |
| 123 | 123 | $fullName = $this->attributes['last_name'] |
| 124 | - .', '.$this->attributes['first_name'] |
|
| 125 | - .' ('.$this->attributes['nickname'].')'; |
|
| 124 | + .', ' . $this->attributes['first_name'] |
|
| 125 | + .' (' . $this->attributes['nickname'] . ')'; |
|
| 126 | 126 | } else { |
| 127 | - $fullName = $this->attributes['last_name'].', '.$this->attributes['first_name']; |
|
| 127 | + $fullName = $this->attributes['last_name'] . ', ' . $this->attributes['first_name']; |
|
| 128 | 128 | } |
| 129 | 129 | |
| 130 | 130 | return $fullName; |
@@ -29,7 +29,7 @@ |
||
| 29 | 29 | public function scopePublishedNews($query) |
| 30 | 30 | { |
| 31 | 31 | return $query->where('publish_date', '<=', Carbon::today()) |
| 32 | - ->where(function ($q) { |
|
| 32 | + ->where(function($q) { |
|
| 33 | 33 | $q->where('expire_date', '>=', Carbon::today()) |
| 34 | 34 | ->orWhere('expire_date', null); |
| 35 | 35 | }); |
@@ -60,12 +60,12 @@ |
||
| 60 | 60 | Mail::send( |
| 61 | 61 | 'emails.training', |
| 62 | 62 | ['user' => $user, 'training' => $training, 'due_date' => $dueDate, 'trainingUser' => $trainingUser], |
| 63 | - function ($m) use ($user, $training) { |
|
| 64 | - $m->to($user->email, $user->userFullName)->subject($training->name.' was assigned to you.'); |
|
| 63 | + function($m) use ($user, $training) { |
|
| 64 | + $m->to($user->email, $user->userFullName)->subject($training->name . ' was assigned to you.'); |
|
| 65 | 65 | |
| 66 | 66 | //ATTACH FILES |
| 67 | 67 | foreach ($training->attachments as $file) { |
| 68 | - $path = 'app/training_'.$file->imageable_id.'/'.$file->filename; |
|
| 68 | + $path = 'app/training_' . $file->imageable_id . '/' . $file->filename; |
|
| 69 | 69 | $m->attach(storage_path($path), ['as' => $file->filename, 'mime' => $file->mime]); |
| 70 | 70 | } |
| 71 | 71 | } // end $m function |