some more to allow relative template-names not only for tabs but in general

This commit is contained in:
Ralf Becker 2002-10-06 08:50:23 +00:00
parent 8099197a78
commit 2d2054b6ad
2 changed files with 11 additions and 4 deletions

View File

@ -62,6 +62,13 @@
);
$this->soetemplate();
$tname = &$name;
if (is_array($name))
{
$tname = &$name['name'];
}
$tname = (strstr($tname,'.') === False ? (is_array($load_via) ? $load_via['name'] : $load_via).'.':'').$tname;
if (empty($name) || !$this->read($name,'','',0,'',$load_via))
{
$this->init($name);

View File

@ -212,11 +212,11 @@
$tab->set_attribute('statustext',$helps[$n]);
$child->add_node($tab);
$grid = new xmlnode('grid');
$grid->set_attribute('id',$names[$n]);
$child2->add_node($grid);
$embeded = new etemplate($names[$n]);
$embeded = new etemplate($names[$n],$etempl->as_array());
$this->etempl2grid($embeded,&$root,$embeded_too);
$grid = new xmlnode('grid');
$grid->set_attribute('id',$embeded->name);
$child2->add_node($grid);
unset($embeded);
}
break;