@@ -83,7 +83,7 @@ discard block |
||
83 | 83 | /** |
84 | 84 | * Store a newly created resource in storage. |
85 | 85 | * |
86 | - * @return Response |
|
86 | + * @return \Illuminate\Http\RedirectResponse |
|
87 | 87 | */ |
88 | 88 | public function store(ClientRequest $request) |
89 | 89 | { |
@@ -143,7 +143,7 @@ discard block |
||
143 | 143 | * |
144 | 144 | * @param int $id |
145 | 145 | * |
146 | - * @return Response |
|
146 | + * @return \Illuminate\Http\RedirectResponse |
|
147 | 147 | */ |
148 | 148 | public function update($id, ClientRequest $request) |
149 | 149 | { |
@@ -156,7 +156,6 @@ discard block |
||
156 | 156 | /** |
157 | 157 | * Remove the specified resource from storage. |
158 | 158 | * |
159 | - * @param int $id |
|
160 | 159 | * |
161 | 160 | * @return Response |
162 | 161 | */ |
@@ -46,24 +46,24 @@ discard block |
||
46 | 46 | //dd($user); |
47 | 47 | |
48 | 48 | return \Datatable::collection($user) |
49 | - ->addColumn('#', function ($model) { |
|
50 | - return "<input type='checkbox' value=".$model->id.' name=select[] id=check>'; |
|
49 | + ->addColumn('#', function($model) { |
|
50 | + return "<input type='checkbox' value=" . $model->id . ' name=select[] id=check>'; |
|
51 | 51 | }) |
52 | - ->addColumn('first_name', function ($model) { |
|
53 | - return '<a href='.url('clients/'.$model->id).'>'.ucfirst($model->first_name).' '.ucfirst($model->last_name).'</a>'; |
|
52 | + ->addColumn('first_name', function($model) { |
|
53 | + return '<a href=' . url('clients/' . $model->id) . '>' . ucfirst($model->first_name) . ' ' . ucfirst($model->last_name) . '</a>'; |
|
54 | 54 | }) |
55 | 55 | |
56 | 56 | ->showColumns('email') |
57 | 57 | |
58 | - ->addColumn('active', function ($model) { |
|
58 | + ->addColumn('active', function($model) { |
|
59 | 59 | if ($model->active == 1) { |
60 | 60 | return "<span style='color:green'>Activated</span>"; |
61 | 61 | } else { |
62 | 62 | return "<span style='color:red'>Not activated</span>"; |
63 | 63 | } |
64 | 64 | }) |
65 | - ->addColumn('action', function ($model) { |
|
66 | - return '<a href='.url('clients/'.$model->id.'/edit')." class='btn btn-sm btn-primary'>Edit</a>"; |
|
65 | + ->addColumn('action', function($model) { |
|
66 | + return '<a href=' . url('clients/' . $model->id . '/edit') . " class='btn btn-sm btn-primary'>Edit</a>"; |
|
67 | 67 | }) |
68 | 68 | ->searchColumns('first_name', 'email') |
69 | 69 | ->orderColumns('first_name', 'email') |
@@ -95,7 +95,7 @@ discard block |
||
95 | 95 | $token = str_random(40); |
96 | 96 | $this->activate->create(['email' => $user->email, 'token' => $token]); |
97 | 97 | |
98 | - \Mail::send('emails.welcome', ['token' => $token, 'email' => $user->email, 'pass' => $str], function ($message) use ($user) { |
|
98 | + \Mail::send('emails.welcome', ['token' => $token, 'email' => $user->email, 'pass' => $str], function($message) use ($user) { |
|
99 | 99 | $message->to($user->email, $user->first_name)->subject('Welcome!'); |
100 | 100 | }); |
101 | 101 | |
@@ -171,25 +171,25 @@ discard block |
||
171 | 171 | } else { |
172 | 172 | echo "<div class='alert alert-success alert-dismissable'> |
173 | 173 | <i class='fa fa-ban'></i> |
174 | - <b>".\Lang::get('message.alert').'!</b> '.\Lang::get('message.success').' |
|
174 | + <b>".\Lang::get('message.alert') . '!</b> ' . \Lang::get('message.success') . ' |
|
175 | 175 | <button type=button class=close data-dismiss=alert aria-hidden=true>×</button> |
176 | - '.\Lang::get('message.no-record').' |
|
176 | + '.\Lang::get('message.no-record') . ' |
|
177 | 177 | </div>'; |
178 | 178 | //echo \Lang::get('message.no-record') . ' [id=>' . $id . ']'; |
179 | 179 | } |
180 | 180 | } |
181 | 181 | echo "<div class='alert alert-success alert-dismissable'> |
182 | 182 | <i class='fa fa-ban'></i> |
183 | - <b>".\Lang::get('message.alert').'!</b> '.\Lang::get('message.success').' |
|
183 | + <b>".\Lang::get('message.alert') . '!</b> ' . \Lang::get('message.success') . ' |
|
184 | 184 | <button type=button class=close data-dismiss=alert aria-hidden=true>×</button> |
185 | - '.\Lang::get('message.deleted-successfully').' |
|
185 | + '.\Lang::get('message.deleted-successfully') . ' |
|
186 | 186 | </div>'; |
187 | 187 | } else { |
188 | 188 | echo "<div class='alert alert-success alert-dismissable'> |
189 | 189 | <i class='fa fa-ban'></i> |
190 | - <b>".\Lang::get('message.alert').'!</b> '.\Lang::get('message.success').' |
|
190 | + <b>".\Lang::get('message.alert') . '!</b> ' . \Lang::get('message.success') . ' |
|
191 | 191 | <button type=button class=close data-dismiss=alert aria-hidden=true>×</button> |
192 | - '.\Lang::get('message.select-a-row').' |
|
192 | + '.\Lang::get('message.select-a-row') . ' |
|
193 | 193 | </div>'; |
194 | 194 | //echo \Lang::get('message.select-a-row'); |
195 | 195 | } |
@@ -39,6 +39,9 @@ |
||
39 | 39 | |
40 | 40 | //*********** Padding Function ********************* |
41 | 41 | |
42 | + /** |
|
43 | + * @param integer $blockSize |
|
44 | + */ |
|
42 | 45 | public function pkcs5_pad($plainText, $blockSize) |
43 | 46 | { |
44 | 47 | $pad = $blockSize - (strlen($plainText) % $blockSize); |
@@ -39,12 +39,12 @@ |
||
39 | 39 | |
40 | 40 | //*********** Padding Function ********************* |
41 | 41 | |
42 | - public function pkcs5_pad($plainText, $blockSize) |
|
43 | - { |
|
44 | - $pad = $blockSize - (strlen($plainText) % $blockSize); |
|
42 | + public function pkcs5_pad($plainText, $blockSize) |
|
43 | + { |
|
44 | + $pad = $blockSize - (strlen($plainText) % $blockSize); |
|
45 | 45 | |
46 | - return $plainText.str_repeat(chr($pad), $pad); |
|
47 | - } |
|
46 | + return $plainText.str_repeat(chr($pad), $pad); |
|
47 | + } |
|
48 | 48 | |
49 | 49 | //********** Hexadecimal to Binary function for php 4.0 version ******** |
50 | 50 |
@@ -43,7 +43,7 @@ |
||
43 | 43 | { |
44 | 44 | $pad = $blockSize - (strlen($plainText) % $blockSize); |
45 | 45 | |
46 | - return $plainText.str_repeat(chr($pad), $pad); |
|
46 | + return $plainText . str_repeat(chr($pad), $pad); |
|
47 | 47 | } |
48 | 48 | |
49 | 49 | //********** Hexadecimal to Binary function for php 4.0 version ******** |
@@ -12,7 +12,7 @@ |
||
12 | 12 | */ |
13 | 13 | |
14 | 14 | $app = new Illuminate\Foundation\Application( |
15 | - realpath(__DIR__.'/../') |
|
15 | + realpath(__DIR__ . '/../') |
|
16 | 16 | ); |
17 | 17 | |
18 | 18 | /* |
@@ -14,7 +14,7 @@ discard block |
||
14 | 14 | | |
15 | 15 | */ |
16 | 16 | |
17 | -require __DIR__.'/../vendor/autoload.php'; |
|
17 | +require __DIR__ . '/../vendor/autoload.php'; |
|
18 | 18 | |
19 | 19 | /* |
20 | 20 | |-------------------------------------------------------------------------- |
@@ -27,8 +27,8 @@ discard block |
||
27 | 27 | | |
28 | 28 | */ |
29 | 29 | |
30 | -if (file_exists($compiledPath = __DIR__.'/cache/compiled.php')) { |
|
30 | +if (file_exists($compiledPath = __DIR__ . '/cache/compiled.php')) { |
|
31 | 31 | require $compiledPath; |
32 | -} elseif (file_exists($compiledPath = __DIR__.'/cache/compiled.php')) { |
|
32 | +} elseif (file_exists($compiledPath = __DIR__ . '/cache/compiled.php')) { |
|
33 | 33 | require $compiledPath; |
34 | 34 | } |
@@ -11,8 +11,8 @@ |
||
11 | 11 | // This file allows us to emulate Apache's "mod_rewrite" functionality from the |
12 | 12 | // built-in PHP web server. This provides a convenient way to test a Laravel |
13 | 13 | // application without having installed a "real" web server software here. |
14 | -if ($uri !== '/' && file_exists(__DIR__.'/public'.$uri)) { |
|
14 | +if ($uri !== '/' && file_exists(__DIR__ . '/public' . $uri)) { |
|
15 | 15 | return false; |
16 | 16 | } |
17 | 17 | |
18 | -require_once __DIR__.'/public/index.php'; |
|
18 | +require_once __DIR__ . '/public/index.php'; |
@@ -45,7 +45,7 @@ |
||
45 | 45 | |
46 | 46 | 'local' => [ |
47 | 47 | 'driver' => 'local', |
48 | - 'root' => storage_path().'/app', |
|
48 | + 'root' => storage_path() . '/app', |
|
49 | 49 | ], |
50 | 50 | |
51 | 51 | 's3' => [ |
@@ -44,7 +44,7 @@ |
||
44 | 44 | |
45 | 45 | 'file' => [ |
46 | 46 | 'driver' => 'file', |
47 | - 'path' => storage_path().'/framework/cache', |
|
47 | + 'path' => storage_path() . '/framework/cache', |
|
48 | 48 | ], |
49 | 49 | |
50 | 50 | 'memcached' => [ |
@@ -28,6 +28,6 @@ |
||
28 | 28 | | |
29 | 29 | */ |
30 | 30 | |
31 | - 'compiled' => realpath(storage_path().'/framework/views'), |
|
31 | + 'compiled' => realpath(storage_path() . '/framework/views'), |
|
32 | 32 | |
33 | 33 | ]; |
@@ -57,7 +57,7 @@ |
||
57 | 57 | | |
58 | 58 | */ |
59 | 59 | |
60 | - 'files' => storage_path().'/framework/sessions', |
|
60 | + 'files' => storage_path() . '/framework/sessions', |
|
61 | 61 | |
62 | 62 | /* |
63 | 63 | |-------------------------------------------------------------------------- |