mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-05-01 08:12:17 +09:00
issue 2625 add about setting of default layout/skin.
git-svn-id: http://xe-core.googlecode.com/svn/branches/maserati@11898 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
parent
afd6f9b5ae
commit
1c3e69f91f
15 changed files with 176 additions and 80 deletions
|
|
@ -136,21 +136,27 @@ class layoutAdminModel extends layout {
|
|||
$this->add('html', $script.$html);
|
||||
}
|
||||
|
||||
function getLayoutAdminSiteDefaultLayout()
|
||||
public function getLayoutAdminSiteDefaultLayout()
|
||||
{
|
||||
$siteSrl = Context::get('site_srl');
|
||||
$type = Context::get('type');
|
||||
|
||||
//TODO remove mock
|
||||
if($type == 'M')
|
||||
{
|
||||
$layoutSrl = 278;
|
||||
}
|
||||
else
|
||||
{
|
||||
$layoutSrl = 62;
|
||||
}
|
||||
$layoutSrl = $this->getSiteDefaultLayout($type, $siteSrl);
|
||||
|
||||
$this->add('layout_srl', $layoutSrl);
|
||||
}
|
||||
|
||||
public function getSiteDefaultLayout($viewType = 'P', $siteSrl = 0)
|
||||
{
|
||||
$target = ($viewType == 'M') ? 'mlayout_srl' : 'layout_srl';
|
||||
$designInfoFile = sprintf(_XE_PATH_.'/files/site_design/design_%s.php', $siteSrl);
|
||||
@include($designInfoFile);
|
||||
|
||||
if(!$designInfo || !$designInfo->{$target})
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
return $designInfo->{$target};
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue