Komponenta předání proměnné v akci presenteru

Upozornění: Tohle vlákno je hodně staré a informace nemusí být platné pro současné Nette.
MartinitCZ
Člen | 580
+
0
-

Jak předat proměnnou v akci presenteru?

createComponentGrid($name) {
	..............
}

function actionDefault($id = NULL, $name = NULL) {
	.............. // Zde potřebuji předat $id a $name do komponenty
}

Děkuji.

Jan Tvrdík
Nette guru | 2595
+
0
-

Co třeba

$this['grid']->id = $id;
$this['grid']->name = $name;

Nebo v createComponentGrid

$grid = new Grid();
$grid->id = $this->getParameter('id');
$grid->name = $this->getParameter('name');
return $grid;
MartinitCZ
Člen | 580
+
0
-

Děkuji :)