fix: Определения типов

This commit is contained in:
origami11@yandex.ru 2025-10-01 12:37:39 +03:00
parent 9f6fd74b17
commit dd74a97894
28 changed files with 334 additions and 249 deletions

View file

@ -35,6 +35,7 @@ class Action
public Database $db;
// Фильтры
/** @var ?ActionAccess */
public $access = null; // Обьект хранит параметры доступа
public $logger = null; // Обьект для ведения лога
@ -42,8 +43,10 @@ class Action
private $helpers = array(); // Помошники для действий
public $part = null; // Параметры для ссылки
public $config/*: Registry*/; // Ссылка на настройки
public $user/*: User*/; // Обьект пользователя
/** @var \ctiso\Registry */
public $config; // Ссылка на настройки
/** @var \ctiso\Role\User */
public $user; // Обьект пользователя
// Для Widgets
public $view = null;
@ -214,7 +217,7 @@ class Action
*/
public function nUrl($actionName, array $param = [])
{
$access/*: ActionAccess*/ = $this->access;
$access = $this->access;
$url = new Url();
//print_r([$name, $param]);
@ -337,7 +340,8 @@ class Action
if ($view instanceof View) {
$this->view->assignValues($this->ctrlValues);
$node/*: Composite*/ = null;
/** @var ?Composite $node */
$node = null;
foreach ($this->childNodes as $name => $node) {
$node->make($this);
$this->view->setView($name, $node->view);
@ -376,7 +380,7 @@ class Action
$this->_getActionPath()->getPath($this, ($action) ? $action : $request->getAction());
}
function redirect($action/*: string*/) {
function redirect(string $action) {
header('location: ' . $action);
exit();
}