@@ -37,7 +37,7 @@ discard block |
||
| 37 | 37 | public function adminlte_image() |
| 38 | 38 | { |
| 39 | 39 | $urlPicture = $this->path_picture != "" ? asset('storage/'.str_replace('app/public/', '', $this->path_picture)) : null; |
| 40 | - if(!isset($urlPicture) || $urlPicture === ""){ |
|
| 40 | + if (!isset($urlPicture) || $urlPicture === "") { |
|
| 41 | 41 | $urlPicture = url('').'/'.config('adminlte.logo_img'); |
| 42 | 42 | } |
| 43 | 43 | return $urlPicture; |
@@ -46,7 +46,7 @@ discard block |
||
| 46 | 46 | public function adminlte_desc() |
| 47 | 47 | { |
| 48 | 48 | $desc = $this->firstname.' '.$this->lastname; |
| 49 | - if($this->organization_id !== null){ |
|
| 49 | + if ($this->organization_id !== null) { |
|
| 50 | 50 | $organization = app(OrganizationRepository::class)->get($this->organization_id); |
| 51 | 51 | $desc .= ' - organisme : '.$organization->name(); |
| 52 | 52 | } |
@@ -85,9 +85,9 @@ discard block |
||
| 85 | 85 | |
| 86 | 86 | public function addCharacteristics(array $characteristics) |
| 87 | 87 | { |
| 88 | - foreach($characteristics as $characteristicUuid){ |
|
| 89 | - $characteristic = CharacteristicsModel::where('uuid', (string)$characteristicUuid)->first(); |
|
| 90 | - if(isset($characteristic)) { |
|
| 88 | + foreach ($characteristics as $characteristicUuid) { |
|
| 89 | + $characteristic = CharacteristicsModel::where('uuid', (string) $characteristicUuid)->first(); |
|
| 90 | + if (isset($characteristic)) { |
|
| 91 | 91 | $this->characteristics()->save($characteristic); |
| 92 | 92 | } |
| 93 | 93 | } |
@@ -96,9 +96,9 @@ discard block |
||
| 96 | 96 | public function syncCharacteristics(array $characteristics) |
| 97 | 97 | { |
| 98 | 98 | $characteristicsToSync = []; |
| 99 | - foreach($characteristics as $characteristicUuid){ |
|
| 100 | - $characteristicModel = CharacteristicsModel::where('uuid', (string)$characteristicUuid)->first(); |
|
| 101 | - if(isset($characteristicModel)) { |
|
| 99 | + foreach ($characteristics as $characteristicUuid) { |
|
| 100 | + $characteristicModel = CharacteristicsModel::where('uuid', (string) $characteristicUuid)->first(); |
|
| 101 | + if (isset($characteristicModel)) { |
|
| 102 | 102 | $characteristicsToSync[] = $characteristicModel->id; |
| 103 | 103 | } |
| 104 | 104 | } |
@@ -44,7 +44,7 @@ |
||
| 44 | 44 | $farmingType = $request->input('farming_type') !== null ? $request->input('farming_type') : []; |
| 45 | 45 | |
| 46 | 46 | $fillWikiUserProfile->fill(Auth::user()->uuid, $role, $firstname, $lastname, $email, $postalCode, $farmingType); |
| 47 | - if(session()->has('wiki_callback')){ |
|
| 47 | + if (session()->has('wiki_callback')) { |
|
| 48 | 48 | return $this->redirectToWiki(); |
| 49 | 49 | } |
| 50 | 50 | return redirect(config('neayi.wiki_url')); |