@@ -54,7 +54,8 @@ discard block |
||
54 | 54 | Route::group([ |
55 | 55 | 'middleware' => 'web', |
56 | 56 | 'namespace' => $this->namespace, |
57 | - ], function ($router) { |
|
57 | + ], function ($router) |
|
58 | + { |
|
58 | 59 | require base_path('routes/web.php'); |
59 | 60 | }); |
60 | 61 | } |
@@ -72,7 +73,8 @@ discard block |
||
72 | 73 | 'middleware' => 'api', |
73 | 74 | 'namespace' => $this->namespace, |
74 | 75 | 'prefix' => 'api', |
75 | - ], function ($router) { |
|
76 | + ], function ($router) |
|
77 | + { |
|
76 | 78 | require base_path('routes/api.php'); |
77 | 79 | }); |
78 | 80 | } |
@@ -20,7 +20,8 @@ |
||
20 | 20 | /* |
21 | 21 | * Authenticate the user's personal channel... |
22 | 22 | */ |
23 | - Broadcast::channel('App.User.*', function (User $user, $userId) { |
|
23 | + Broadcast::channel('App.User.*', function (User $user, $userId) |
|
24 | + { |
|
24 | 25 | return (int) $user->id === (int) $userId; |
25 | 26 | }); |
26 | 27 | } |
@@ -45,9 +45,11 @@ discard block |
||
45 | 45 | $title = trans('general.add'); |
46 | 46 | $submit_route = route($this->getRouteName().'.postadd'); |
47 | 47 | } else { |
48 | - try { |
|
48 | + try |
|
49 | + { |
|
49 | 50 | $dataset = Room::findOrFail($id); |
50 | - } catch (ModelNotFoundException $e) { |
|
51 | + } catch (ModelNotFoundException $e) |
|
52 | + { |
|
51 | 53 | return Controller::returnBack([ |
52 | 54 | 'message' => trans('general.object_not_found'), |
53 | 55 | 'alert-class' => 'alert-danger', |
@@ -77,7 +79,8 @@ discard block |
||
77 | 79 | [ |
78 | 80 | 'id' => 'number', |
79 | 81 | 'title' => trans('general.number'), |
80 | - 'value' => function (Room $data) { |
|
82 | + 'value' => function (Room $data) |
|
83 | + { |
|
81 | 84 | return $data->number; |
82 | 85 | }, |
83 | 86 | 'type' => 'number', |
@@ -88,7 +91,8 @@ discard block |
||
88 | 91 | [ |
89 | 92 | 'id' => 'floor', |
90 | 93 | 'title' => trans('general.floor'), |
91 | - 'value' => function (Room $data) { |
|
94 | + 'value' => function (Room $data) |
|
95 | + { |
|
92 | 96 | return $data->floor; |
93 | 97 | }, |
94 | 98 | 'type' => 'number', |
@@ -99,7 +103,8 @@ discard block |
||
99 | 103 | [ |
100 | 104 | 'id' => 'capacity', |
101 | 105 | 'title' => trans('general.capacity'), |
102 | - 'value' => function (Room $data) { |
|
106 | + 'value' => function (Room $data) |
|
107 | + { |
|
103 | 108 | return $data->capacity; |
104 | 109 | }, |
105 | 110 | 'type' => 'number', |
@@ -110,7 +115,8 @@ discard block |
||
110 | 115 | [ |
111 | 116 | 'id' => 'price', |
112 | 117 | 'title' => trans('general.price'), |
113 | - 'value' => function (Room $data) { |
|
118 | + 'value' => function (Room $data) |
|
119 | + { |
|
114 | 120 | return $data->price; |
115 | 121 | }, |
116 | 122 | 'type' => 'number', |
@@ -123,7 +129,8 @@ discard block |
||
123 | 129 | [ |
124 | 130 | 'id' => 'comments', |
125 | 131 | 'title' => trans('general.comment'), |
126 | - 'value' => function (Room $data) { |
|
132 | + 'value' => function (Room $data) |
|
133 | + { |
|
127 | 134 | return $data->comments; |
128 | 135 | }, |
129 | 136 | 'type' => 'textarea', |
@@ -136,25 +143,29 @@ discard block |
||
136 | 143 | $dataset = [ |
137 | 144 | [ |
138 | 145 | 'title' => trans('general.number'), |
139 | - 'value' => function (Room $data) { |
|
146 | + 'value' => function (Room $data) |
|
147 | + { |
|
140 | 148 | return $data->number; |
141 | 149 | }, |
142 | 150 | ], |
143 | 151 | [ |
144 | 152 | 'title' => trans('general.floor'), |
145 | - 'value' => function (Room $data) { |
|
153 | + 'value' => function (Room $data) |
|
154 | + { |
|
146 | 155 | return $data->floor; |
147 | 156 | }, |
148 | 157 | ], |
149 | 158 | [ |
150 | 159 | 'title' => trans('general.capacity'), |
151 | - 'value' => function (Room $data) { |
|
160 | + 'value' => function (Room $data) |
|
161 | + { |
|
152 | 162 | return $data->capacity; |
153 | 163 | }, |
154 | 164 | ], |
155 | 165 | [ |
156 | 166 | 'title' => trans('general.price'), |
157 | - 'value' => function (Room $data) { |
|
167 | + 'value' => function (Room $data) |
|
168 | + { |
|
158 | 169 | return $data->price; |
159 | 170 | }, |
160 | 171 | ], |