@@ -161,7 +161,7 @@ discard block |
||
161 | 161 | * @throws Alpha\Exception\ResourceNotFoundException |
162 | 162 | * @throws Alpha\Exception\IllegalArguementException |
163 | 163 | * |
164 | - * @return Alpha\Util\Http\Response |
|
164 | + * @return Response |
|
165 | 165 | * |
166 | 166 | * @since 2.0 |
167 | 167 | */ |
@@ -348,7 +348,7 @@ discard block |
||
348 | 348 | * @throws Alpha\Exception\IllegalArguementException |
349 | 349 | * @throws Alpha\Exception\SecurityException |
350 | 350 | * |
351 | - * @return Alpha\Util\Http\Response |
|
351 | + * @return Response |
|
352 | 352 | * |
353 | 353 | * @since 2.0 |
354 | 354 | * |
@@ -438,7 +438,7 @@ discard block |
||
438 | 438 | * @throws Alpha\Exception\IllegalArguementException |
439 | 439 | * @throws Alpha\Exception\SecurityException |
440 | 440 | * |
441 | - * @return Alpha\Util\Http\Response |
|
441 | + * @return Response |
|
442 | 442 | * |
443 | 443 | * @since 2.0 |
444 | 444 | * |
@@ -532,7 +532,7 @@ discard block |
||
532 | 532 | * @throws Alpha\Exception\IllegalArguementException |
533 | 533 | * @throws Alpha\Exception\SecurityException |
534 | 534 | * |
535 | - * @return Alpha\Util\Http\Response |
|
535 | + * @return Response |
|
536 | 536 | * |
537 | 537 | * @since 2.0 |
538 | 538 | */ |
@@ -690,7 +690,7 @@ discard block |
||
690 | 690 | $body = ''; |
691 | 691 | |
692 | 692 | // the index of the last record displayed on this page |
693 | - $last = $this->start + $config->get('app.list.page.amount'); |
|
693 | + $last = $this->start+$config->get('app.list.page.amount'); |
|
694 | 694 | |
695 | 695 | // ensure that the last index never overruns the total record count |
696 | 696 | if ($last > $this->recordCount) { |
@@ -710,9 +710,9 @@ discard block |
||
710 | 710 | if ($this->start > 0) { |
711 | 711 | // handle secure URLs |
712 | 712 | if ($this->request->getParam('token', null) != null) { |
713 | - $body .= '<li><a href="'.FrontController::generateSecureURL('act=Alpha\Controller\ActiveRecordController&ActiveRecordType='.$this->request->getParam('ActiveRecordType').'&start='.($this->start - $this->limit).'&limit='.$this->limit).'"><<-Previous</a></li>'; |
|
713 | + $body .= '<li><a href="'.FrontController::generateSecureURL('act=Alpha\Controller\ActiveRecordController&ActiveRecordType='.$this->request->getParam('ActiveRecordType').'&start='.($this->start-$this->limit).'&limit='.$this->limit).'"><<-Previous</a></li>'; |
|
714 | 714 | } else { |
715 | - $body .= '<li><a href="/records/'.urlencode($this->request->getParam('ActiveRecordType')).'/'.($this->start - $this->limit).'/'.$this->limit.'"><<-Previous</a></li>'; |
|
715 | + $body .= '<li><a href="/records/'.urlencode($this->request->getParam('ActiveRecordType')).'/'.($this->start-$this->limit).'/'.$this->limit.'"><<-Previous</a></li>'; |
|
716 | 716 | } |
717 | 717 | } elseif ($this->recordCount > $this->limit) { |
718 | 718 | $body .= '<li class="disabled"><a href="#"><<-Previous</a></li>'; |
@@ -742,9 +742,9 @@ discard block |
||
742 | 742 | if ($this->recordCount > $last) { |
743 | 743 | // handle secure URLs |
744 | 744 | if ($this->request->getParam('token', null) != null) { |
745 | - $body .= '<li><a href="'.FrontController::generateSecureURL('act=Alpha\Controller\ActiveRecordController&ActiveRecordType='.$this->request->getParam('ActiveRecordType').'&start='.($this->start + $this->limit).'&limit='.$this->limit).'">Next->></a></li>'; |
|
745 | + $body .= '<li><a href="'.FrontController::generateSecureURL('act=Alpha\Controller\ActiveRecordController&ActiveRecordType='.$this->request->getParam('ActiveRecordType').'&start='.($this->start+$this->limit).'&limit='.$this->limit).'">Next->></a></li>'; |
|
746 | 746 | } else { |
747 | - $body .= '<li><a href="/records/'.urlencode($this->request->getParam('ActiveRecordType')).'/'.($this->start + $this->limit.'/'.$this->limit). |
|
747 | + $body .= '<li><a href="/records/'.urlencode($this->request->getParam('ActiveRecordType')).'/'.($this->start+$this->limit.'/'.$this->limit). |
|
748 | 748 | '">Next->></a></li>'; |
749 | 749 | } |
750 | 750 | } elseif ($this->recordCount > $this->limit) { |
@@ -99,7 +99,7 @@ discard block |
||
99 | 99 | * |
100 | 100 | * @param Alpha\Util\Http\Request |
101 | 101 | * |
102 | - * @return Alpha\Util\Http\Response |
|
102 | + * @return Response |
|
103 | 103 | * |
104 | 104 | * @throws Alpha\Exception\ResourceNotFoundException |
105 | 105 | * |
@@ -311,7 +311,7 @@ discard block |
||
311 | 311 | * |
312 | 312 | * @param Alpha\Util\Http\Request |
313 | 313 | * |
314 | - * @return Alpha\Util\Http\Response |
|
314 | + * @return Response |
|
315 | 315 | * |
316 | 316 | * @since 1.0 |
317 | 317 | */ |
@@ -425,7 +425,7 @@ discard block |
||
425 | 425 | * |
426 | 426 | * @param Alpha\Util\Http\Request |
427 | 427 | * |
428 | - * @return Alpha\Util\Http\Response |
|
428 | + * @return Response |
|
429 | 429 | * |
430 | 430 | * @since 2.0 |
431 | 431 | */ |
@@ -104,7 +104,7 @@ discard block |
||
104 | 104 | * |
105 | 105 | * @throws Alpha\Exception\IllegalArguementException |
106 | 106 | * |
107 | - * @return Alpha\Util\Http\Response |
|
107 | + * @return Response |
|
108 | 108 | * |
109 | 109 | * @since 1.0 |
110 | 110 | */ |
@@ -185,7 +185,7 @@ discard block |
||
185 | 185 | * @throws Alpha\Exception\SecurityException |
186 | 186 | * @throws Alpha\Exception\IllegalArguementException |
187 | 187 | * |
188 | - * @return Alpha\Util\Http\Response |
|
188 | + * @return Response |
|
189 | 189 | * |
190 | 190 | * @since 1.0 |
191 | 191 | */ |
@@ -999,7 +999,7 @@ discard block |
||
999 | 999 | /** |
1000 | 1000 | * Method to return an access error for trespassing users. HTTP response header code will be 403. |
1001 | 1001 | * |
1002 | - * @return Alpha\Util\Http\Response |
|
1002 | + * @return Response |
|
1003 | 1003 | * |
1004 | 1004 | * @since 1.0 |
1005 | 1005 | */ |
@@ -1179,7 +1179,7 @@ discard block |
||
1179 | 1179 | /** |
1180 | 1180 | * Generates the two security fields to prevent remote form processing. |
1181 | 1181 | * |
1182 | - * @return array An array containing the two fields |
|
1182 | + * @return string[] An array containing the two fields |
|
1183 | 1183 | * |
1184 | 1184 | * @since 1.0 |
1185 | 1185 | */ |
@@ -1531,7 +1531,7 @@ discard block |
||
1531 | 1531 | * |
1532 | 1532 | * @param Alpha\Util\Http\Request $request |
1533 | 1533 | * |
1534 | - * @return Alpha\Util\Http\Response |
|
1534 | + * @return Response |
|
1535 | 1535 | * |
1536 | 1536 | * @since 2.0 |
1537 | 1537 | */ |
@@ -511,19 +511,19 @@ discard block |
||
511 | 511 | } |
512 | 512 | // found the current job |
513 | 513 | if ($this->name == $jobs[$i]) { |
514 | - if (isset($jobs[$i - 1])) { |
|
514 | + if (isset($jobs[$i-1])) { |
|
515 | 515 | // set the previous job if it exists |
516 | - $this->previousJob = $jobs[$i - 1]; |
|
516 | + $this->previousJob = $jobs[$i-1]; |
|
517 | 517 | self::$logger->debug('Previous job ['.$this->previousJob.']'); |
518 | 518 | } |
519 | - if (isset($jobs[$i + 1])) { |
|
519 | + if (isset($jobs[$i+1])) { |
|
520 | 520 | // set the next job if it exists |
521 | - $this->nextJob = $jobs[$i + 1]; |
|
521 | + $this->nextJob = $jobs[$i+1]; |
|
522 | 522 | self::$logger->debug('Next job ['.$this->nextJob.']'); |
523 | 523 | } |
524 | 524 | } |
525 | 525 | // the last job in the sequence |
526 | - if ($i == ($numOfJobs - 1)) { |
|
526 | + if ($i == ($numOfJobs-1)) { |
|
527 | 527 | $this->lastJob = $jobs[$i]; |
528 | 528 | } |
529 | 529 | } |
@@ -687,9 +687,9 @@ discard block |
||
687 | 687 | $this->unitEndTime->getYear() |
688 | 688 | ); |
689 | 689 | |
690 | - self::$logger->debug('<<getUnitDuration ['.$intEndTime - $intStartTime.']'); |
|
690 | + self::$logger->debug('<<getUnitDuration ['.$intEndTime-$intStartTime.']'); |
|
691 | 691 | |
692 | - return $intEndTime - $intStartTime; |
|
692 | + return $intEndTime-$intStartTime; |
|
693 | 693 | } |
694 | 694 | |
695 | 695 | /** |
@@ -1159,7 +1159,7 @@ discard block |
||
1159 | 1159 | */ |
1160 | 1160 | |
1161 | 1161 | // the server hostname + today's date less 1 hour (i.e. yesterday where time is < 1:00AM) |
1162 | - $var1 = base64_encode(SecurityUtils::encrypt($host.date('Ymd', (time() - 3600)))); |
|
1162 | + $var1 = base64_encode(SecurityUtils::encrypt($host.date('Ymd', (time()-3600)))); |
|
1163 | 1163 | // the server's IP plus $var1 |
1164 | 1164 | $var2 = base64_encode(SecurityUtils::encrypt($ip.$var1)); |
1165 | 1165 | |
@@ -1505,7 +1505,7 @@ discard block |
||
1505 | 1505 | */ |
1506 | 1506 | public function doOPTIONS($request) |
1507 | 1507 | { |
1508 | - $HTTPMethods = array('HEAD','GET','POST','PUT','PATCH','DELETE','OPTIONS'); |
|
1508 | + $HTTPMethods = array('HEAD', 'GET', 'POST', 'PUT', 'PATCH', 'DELETE', 'OPTIONS'); |
|
1509 | 1509 | $supported = array(); |
1510 | 1510 | |
1511 | 1511 | foreach ($HTTPMethods as $HTTPMethod) { |
@@ -62,37 +62,36 @@ discard block |
||
62 | 62 | /** |
63 | 63 | * Handles GET HTTP requests. |
64 | 64 | * |
65 | - * @param Alpha\Util\Http\Request $request |
|
66 | 65 | * |
67 | 66 | * @since Alpha\Util\Http\Response |
68 | 67 | * @since 1.0 |
68 | + * @return \Alpha\Util\Http\Response|null |
|
69 | 69 | */ |
70 | 70 | public function doGET($params); |
71 | 71 | |
72 | 72 | /** |
73 | 73 | * Handles POST HTTP requests. |
74 | 74 | * |
75 | - * @param Alpha\Util\Http\Request $request |
|
76 | 75 | * |
77 | 76 | * @since Alpha\Util\Http\Response |
78 | 77 | * @since 1.0 |
78 | + * @return \Alpha\Util\Http\Response|null |
|
79 | 79 | */ |
80 | 80 | public function doPOST($params); |
81 | 81 | |
82 | 82 | /** |
83 | 83 | * Handles PUT HTTP requests. |
84 | 84 | * |
85 | - * @param Alpha\Util\Http\Request $request |
|
86 | 85 | * |
87 | 86 | * @since Alpha\Util\Http\Response |
88 | 87 | * @since 1.0 |
88 | + * @return \Alpha\Util\Http\Response |
|
89 | 89 | */ |
90 | 90 | public function doPUT($params); |
91 | 91 | |
92 | 92 | /** |
93 | 93 | * Handles PATCH HTTP requests. |
94 | 94 | * |
95 | - * @param Alpha\Util\Http\Request $request |
|
96 | 95 | * |
97 | 96 | * @since Alpha\Util\Http\Response |
98 | 97 | * @since 1.0 |
@@ -102,20 +101,20 @@ discard block |
||
102 | 101 | /** |
103 | 102 | * Handles DELETE HTTP requests. |
104 | 103 | * |
105 | - * @param Alpha\Util\Http\Request $request |
|
106 | 104 | * |
107 | 105 | * @since Alpha\Util\Http\Response |
108 | 106 | * @since 1.0 |
107 | + * @return \Alpha\Util\Http\Response |
|
109 | 108 | */ |
110 | 109 | public function doDELETE($params); |
111 | 110 | |
112 | 111 | /** |
113 | 112 | * Handles OPTIONS HTTP requests. |
114 | 113 | * |
115 | - * @param Alpha\Util\Http\Request $request |
|
116 | 114 | * |
117 | 115 | * @since Alpha\Util\Http\Response |
118 | 116 | * @since 1.0 |
117 | + * @return \Alpha\Util\Http\Response |
|
119 | 118 | */ |
120 | 119 | public function doOPTIONS($params); |
121 | 120 | } |
@@ -90,7 +90,7 @@ discard block |
||
90 | 90 | * |
91 | 91 | * @param Alpha\Util\Http\Request $request |
92 | 92 | * |
93 | - * @return Alpha\Util\Http\Response |
|
93 | + * @return Response |
|
94 | 94 | * |
95 | 95 | * @since 1.0 |
96 | 96 | */ |
@@ -180,7 +180,7 @@ discard block |
||
180 | 180 | * |
181 | 181 | * @param Alpha\Util\Http\Request $request |
182 | 182 | * |
183 | - * @return Alpha\Util\Http\Response |
|
183 | + * @return Response |
|
184 | 184 | * |
185 | 185 | * @throws Alpha\Exception\SecurityException |
186 | 186 | * |
@@ -85,7 +85,7 @@ |
||
85 | 85 | * |
86 | 86 | * @param Alpha\Util\Http\Request $request |
87 | 87 | * |
88 | - * @return Alpha\Util\Http\Response |
|
88 | + * @return Response |
|
89 | 89 | * |
90 | 90 | * @throws Alpha\Exception\ResourceNotFoundException |
91 | 91 | * |
@@ -144,7 +144,7 @@ |
||
144 | 144 | * |
145 | 145 | * @param Alpha\Util\Http\Request $request |
146 | 146 | * |
147 | - * @return Alpha\Util\Http\Response |
|
147 | + * @return Response |
|
148 | 148 | * |
149 | 149 | * @since 1.0 |
150 | 150 | * |
@@ -551,7 +551,7 @@ discard block |
||
551 | 551 | * |
552 | 552 | * @throws Alpha\Exception\IllegalArguementException |
553 | 553 | * |
554 | - * @return Alpha\Controller\Front\FrontController |
|
554 | + * @return FrontController |
|
555 | 555 | * |
556 | 556 | * @since 2.0 |
557 | 557 | */ |
@@ -573,7 +573,7 @@ discard block |
||
573 | 573 | * @param string $param The param name (as defined on the route between {} braces) |
574 | 574 | * @param mixed $defaultValue The value to use |
575 | 575 | * |
576 | - * @return Alpha\Controller\Front\FrontController |
|
576 | + * @return FrontController |
|
577 | 577 | * |
578 | 578 | * @since 2.0 |
579 | 579 | */ |
@@ -637,7 +637,7 @@ discard block |
||
637 | 637 | * |
638 | 638 | * @param Alpha\Util\Http\Request $request The request to process |
639 | 639 | * |
640 | - * @return Alpha\Util\Http\Response |
|
640 | + * @return Response |
|
641 | 641 | * |
642 | 642 | * @throws Alpha\Exception\ResourceNotFoundException |
643 | 643 | * @throws Alpha\Exception\ResourceNotAllowedException |
@@ -615,7 +615,7 @@ |
||
615 | 615 | } |
616 | 616 | } |
617 | 617 | |
618 | - // route URIs with params missing (will attempt to layer on defaults later on in Request class) |
|
618 | + // route URIs with params missing (will attempt to layer on defaults later on in Request class) |
|
619 | 619 | foreach ($this->routes as $route => $callback) { |
620 | 620 | $pattern = '#^'.$route.'$#s'; |
621 | 621 | $pattern = preg_replace('#\/\{\S+\}#', '\/?', $pattern); |
@@ -175,145 +175,145 @@ discard block |
||
175 | 175 | throw new BadRequestException('Request character encoding does not match expected UTF-8'); |
176 | 176 | } |
177 | 177 | |
178 | - $this->addRoute('/', function ($request) { |
|
178 | + $this->addRoute('/', function($request) { |
|
179 | 179 | $controller = new IndexController(); |
180 | 180 | |
181 | 181 | return $controller->process($request); |
182 | 182 | }); |
183 | 183 | |
184 | - $this->addRoute('/a/{title}/{view}', function ($request) { |
|
184 | + $this->addRoute('/a/{title}/{view}', function($request) { |
|
185 | 185 | $controller = new ArticleController(); |
186 | 186 | |
187 | 187 | return $controller->process($request); |
188 | 188 | })->value('title', null)->value('view', 'detailed'); |
189 | 189 | |
190 | - $this->addRoute('/articles/{start}/{limit}', function ($request) { |
|
190 | + $this->addRoute('/articles/{start}/{limit}', function($request) { |
|
191 | 191 | $controller = new ArticleController(); |
192 | 192 | |
193 | 193 | return $controller->process($request); |
194 | 194 | })->value('start', 0)->value('limit', $config->get('app.list.page.amount')); |
195 | 195 | |
196 | - $this->addRoute('/attach/{articleOID}/{filename}', function ($request) { |
|
196 | + $this->addRoute('/attach/{articleOID}/{filename}', function($request) { |
|
197 | 197 | $controller = new AttachmentController(); |
198 | 198 | |
199 | 199 | return $controller->process($request); |
200 | 200 | }); |
201 | 201 | |
202 | - $this->addRoute('/cache', function ($request) { |
|
202 | + $this->addRoute('/cache', function($request) { |
|
203 | 203 | $controller = new CacheController(); |
204 | 204 | |
205 | 205 | return $controller->process($request); |
206 | 206 | }); |
207 | 207 | |
208 | - $this->addRoute('/denum/{denumOID}', function ($request) { |
|
208 | + $this->addRoute('/denum/{denumOID}', function($request) { |
|
209 | 209 | $controller = new DEnumController(); |
210 | 210 | |
211 | 211 | return $controller->process($request); |
212 | 212 | })->value('denumOID', null); |
213 | 213 | |
214 | - $this->addRoute('/excel/{ActiveRecordType}/{ActiveRecordOID}', function ($request) { |
|
214 | + $this->addRoute('/excel/{ActiveRecordType}/{ActiveRecordOID}', function($request) { |
|
215 | 215 | $controller = new ExcelController(); |
216 | 216 | |
217 | 217 | return $controller->process($request); |
218 | 218 | })->value('ActiveRecordOID', null); |
219 | 219 | |
220 | - $this->addRoute('/feed/{ActiveRecordType}/{type}', function ($request) { |
|
220 | + $this->addRoute('/feed/{ActiveRecordType}/{type}', function($request) { |
|
221 | 221 | $controller = new FeedController(); |
222 | 222 | |
223 | 223 | return $controller->process($request); |
224 | 224 | })->value('type', 'Atom'); |
225 | 225 | |
226 | - $this->addRoute('/gensecure', function ($request) { |
|
226 | + $this->addRoute('/gensecure', function($request) { |
|
227 | 227 | $controller = new GenSecureQueryStringController(); |
228 | 228 | |
229 | 229 | return $controller->process($request); |
230 | 230 | }); |
231 | 231 | |
232 | - $this->addRoute('/image/{source}/{width}/{height}/{type}/{quality}/{scale}/{secure}/{var1}/{var2}', function ($request) { |
|
232 | + $this->addRoute('/image/{source}/{width}/{height}/{type}/{quality}/{scale}/{secure}/{var1}/{var2}', function($request) { |
|
233 | 233 | $controller = new ImageController(); |
234 | 234 | |
235 | 235 | return $controller->process($request); |
236 | 236 | })->value('var1', null)->value('var2', null); |
237 | 237 | |
238 | - $this->addRoute('/listactiverecords', function ($request) { |
|
238 | + $this->addRoute('/listactiverecords', function($request) { |
|
239 | 239 | $controller = new ListActiveRecordsController(); |
240 | 240 | |
241 | 241 | return $controller->process($request); |
242 | 242 | }); |
243 | 243 | |
244 | - $this->addRoute('/log/{logPath}', function ($request) { |
|
244 | + $this->addRoute('/log/{logPath}', function($request) { |
|
245 | 245 | $controller = new LogController(); |
246 | 246 | |
247 | 247 | return $controller->process($request); |
248 | 248 | }); |
249 | 249 | |
250 | - $this->addRoute('/login', function ($request) { |
|
250 | + $this->addRoute('/login', function($request) { |
|
251 | 251 | $controller = new LoginController(); |
252 | 252 | |
253 | 253 | return $controller->process($request); |
254 | 254 | }); |
255 | 255 | |
256 | - $this->addRoute('/logout', function ($request) { |
|
256 | + $this->addRoute('/logout', function($request) { |
|
257 | 257 | $controller = new LogoutController(); |
258 | 258 | |
259 | 259 | return $controller->process($request); |
260 | 260 | }); |
261 | 261 | |
262 | - $this->addRoute('/metric', function ($request) { |
|
262 | + $this->addRoute('/metric', function($request) { |
|
263 | 263 | $controller = new MetricController(); |
264 | 264 | |
265 | 265 | return $controller->process($request); |
266 | 266 | }); |
267 | 267 | |
268 | - $this->addRoute('/recordselector/12m/{ActiveRecordOID}/{field}/{relatedClass}/{relatedClassField}/{relatedClassDisplayField}/{relationType}', function ($request) { |
|
268 | + $this->addRoute('/recordselector/12m/{ActiveRecordOID}/{field}/{relatedClass}/{relatedClassField}/{relatedClassDisplayField}/{relationType}', function($request) { |
|
269 | 269 | $controller = new RecordSelectorController(); |
270 | 270 | |
271 | 271 | return $controller->process($request); |
272 | 272 | })->value('relationType', 'ONE-TO-MANY'); |
273 | 273 | |
274 | - $this->addRoute('/recordselector/m2m/{ActiveRecordOID}/{field}/{relatedClassLeft}/{relatedClassLeftDisplayField}/{relatedClassRight}/{relatedClassRightDisplayField}/{accessingClassName}/{lookupOIDs}/{relationType}', function ($request) { |
|
274 | + $this->addRoute('/recordselector/m2m/{ActiveRecordOID}/{field}/{relatedClassLeft}/{relatedClassLeftDisplayField}/{relatedClassRight}/{relatedClassRightDisplayField}/{accessingClassName}/{lookupOIDs}/{relationType}', function($request) { |
|
275 | 275 | $controller = new RecordSelectorController(); |
276 | 276 | |
277 | 277 | return $controller->process($request); |
278 | 278 | })->value('relationType', 'MANY-TO-MANY'); |
279 | 279 | |
280 | - $this->addRoute('/search/{query}/{start}/{limit}', function ($request) { |
|
280 | + $this->addRoute('/search/{query}/{start}/{limit}', function($request) { |
|
281 | 281 | $controller = new SearchController(); |
282 | 282 | |
283 | 283 | return $controller->process($request); |
284 | 284 | })->value('start', 0)->value('limit', $config->get('app.list.page.amount')); |
285 | 285 | |
286 | - $this->addRoute('/sequence/{start}/{limit}', function ($request) { |
|
286 | + $this->addRoute('/sequence/{start}/{limit}', function($request) { |
|
287 | 287 | $controller = new SequenceController(); |
288 | 288 | |
289 | 289 | return $controller->process($request); |
290 | 290 | })->value('start', 0)->value('limit', $config->get('app.list.page.amount')); |
291 | 291 | |
292 | - $this->addRoute('/tag/{ActiveRecordType}/{ActiveRecordOID}', function ($request) { |
|
292 | + $this->addRoute('/tag/{ActiveRecordType}/{ActiveRecordOID}', function($request) { |
|
293 | 293 | $controller = new TagController(); |
294 | 294 | |
295 | 295 | return $controller->process($request); |
296 | 296 | }); |
297 | 297 | |
298 | - $this->addRoute('/install', function ($request) { |
|
298 | + $this->addRoute('/install', function($request) { |
|
299 | 299 | $controller = new InstallController(); |
300 | 300 | |
301 | 301 | return $controller->process($request); |
302 | 302 | }); |
303 | 303 | |
304 | - $this->addRoute('/record/{ActiveRecordType}/{ActiveRecordOID}/{view}', function ($request) { |
|
304 | + $this->addRoute('/record/{ActiveRecordType}/{ActiveRecordOID}/{view}', function($request) { |
|
305 | 305 | $controller = new ActiveRecordController(); |
306 | 306 | |
307 | 307 | return $controller->process($request); |
308 | 308 | })->value('ActiveRecordOID', null)->value('view', 'detailed'); |
309 | 309 | |
310 | - $this->addRoute('/records/{ActiveRecordType}/{start}/{limit}', function ($request) { |
|
310 | + $this->addRoute('/records/{ActiveRecordType}/{start}/{limit}', function($request) { |
|
311 | 311 | $controller = new ActiveRecordController(); |
312 | 312 | |
313 | 313 | return $controller->process($request); |
314 | 314 | })->value('start', 0)->value('limit', $config->get('app.list.page.amount')); |
315 | 315 | |
316 | - $this->addRoute('/tk/{token}', function ($request) { |
|
316 | + $this->addRoute('/tk/{token}', function($request) { |
|
317 | 317 | $params = self::getDecodeQueryParams($request->getParam('token')); |
318 | 318 | |
319 | 319 | if (isset($params['act'])) { |
@@ -340,7 +340,7 @@ discard block |
||
340 | 340 | return new Response(404, 'Resource not found'); |
341 | 341 | }); |
342 | 342 | |
343 | - $this->addRoute('/alpha/service', function ($request) { |
|
343 | + $this->addRoute('/alpha/service', function($request) { |
|
344 | 344 | $controller = new LoginController(); |
345 | 345 | $controller->setUnitOfWork(array('Alpha\Controller\LoginController', 'Alpha\Controller\ListActiveRecordsController')); |
346 | 346 | |
@@ -487,7 +487,7 @@ discard block |
||
487 | 487 | */ |
488 | 488 | private static function multipleExplode($string, $delimiters = array()) |
489 | 489 | { |
490 | - $mainDelim = $delimiters[count($delimiters) - 1]; |
|
490 | + $mainDelim = $delimiters[count($delimiters)-1]; |
|
491 | 491 | |
492 | 492 | array_pop($delimiters); |
493 | 493 |