|
@@ 463-480 (lines=18) @@
|
| 460 |
|
/** |
| 461 |
|
* Generate constructor for application class. |
| 462 |
|
*/ |
| 463 |
|
protected function generateConstructorApplicationClass() |
| 464 |
|
{ |
| 465 |
|
$class = "\n\t" . '/**'; |
| 466 |
|
$class .= "\n\t" . ' * Render materials list with pager'; |
| 467 |
|
$class .= "\n\t" . ' *'; |
| 468 |
|
$class .= "\n\t" . ' * @param string $navigationId Structure identifier'; |
| 469 |
|
$class .= "\n\t" . ' * @param string $search Keywords to filter table'; |
| 470 |
|
$class .= "\n\t" . ' * @param int $page Current table page'; |
| 471 |
|
$class .= "\n\t" . ' * @return array Asynchronous response containing status and materials list with pager on success'; |
| 472 |
|
$class .= "\n\t" . ' * or just status on asynchronous controller failure'; |
| 473 |
|
$class .= "\n\t" . ' */'; |
| 474 |
|
$class .= "\n\t" . 'public function __async_collection($navigationId = \'0\', $search = \'\', $page = 1)'; |
| 475 |
|
$class .= "\n\t" . '{'; |
| 476 |
|
$class .= "\n\t\t" . 'return parent::__async_collection(self::$navigation, $search, $page);'; |
| 477 |
|
$class .= "\n\t" . '}' . "\n"; |
| 478 |
|
|
| 479 |
|
return $class; |
| 480 |
|
} |
| 481 |
|
|
| 482 |
|
/** |
| 483 |
|
* Generate constructor for application class. |
|
@@ 485-502 (lines=18) @@
|
| 482 |
|
/** |
| 483 |
|
* Generate constructor for application class. |
| 484 |
|
*/ |
| 485 |
|
protected function generateConstructorApplicationCollectionClass() |
| 486 |
|
{ |
| 487 |
|
$class = "\n\t" . '/**'; |
| 488 |
|
$class .= "\n\t" . ' * Generic collection constructor'; |
| 489 |
|
$class .= "\n\t" . ' *'; |
| 490 |
|
$class .= "\n\t" . ' * @param RenderInterface $renderer View render object'; |
| 491 |
|
$class .= "\n\t" . ' * @param QueryInterface $query Query object'; |
| 492 |
|
$class .= "\n\t" . ' */'; |
| 493 |
|
$class .= "\n\t" . 'public function __async_collection($renderer, $query = null, $pager = null)'; |
| 494 |
|
$class .= "\n\t" . '{'; |
| 495 |
|
$class .= "\n\t\t" . 'return parent::__async_collection($renderer, $query = null, $pager = null);'; |
| 496 |
|
$class .= "\n\t\t" . '$this->fields = array('; |
| 497 |
|
$class .= "\n\t\t\t" . 'new Control(),'; |
| 498 |
|
$class .= "\n\t\t" . ');'; |
| 499 |
|
$class .= "\n\t" . '}' . "\n"; |
| 500 |
|
|
| 501 |
|
return $class; |
| 502 |
|
} |
| 503 |
|
} |
| 504 |
|
//[PHPCOMPRESSOR(remove,end)] |
| 505 |
|
|