Fixed a bug in the Layout where it didnot inherit the layout template of its parent
This commit is contained in:
parent
c7a4c73e6b
commit
d22e96216e
2 changed files with 10 additions and 1 deletions
|
|
@ -97,8 +97,15 @@ sub getEditForm {
|
|||
my $self = shift;
|
||||
my $tabform = $self->SUPER::getEditForm();
|
||||
my $i18n = WebGUI::International->new($self->session,"Asset_Layout");
|
||||
|
||||
my ($templateId);
|
||||
if (($self->get("assetId") eq "new") && ($self->getParent->get('className') eq 'WebGUI::Asset::Wobject::Layout')) {
|
||||
$templateId = $self->getParent->getValue('templateId');
|
||||
} else {
|
||||
$templateId = $self->getValue('templateId');
|
||||
}
|
||||
$tabform->getTab("display")->template(
|
||||
-value=>$self->getValue('templateId'),
|
||||
-value=>$templateId,
|
||||
-label=>$i18n->get('layout template title'),
|
||||
-hoverHelp=>$i18n->get('template description'),
|
||||
-namespace=>"Layout"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue