mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-01-07 10:41:40 +09:00
issue 70 admin setup modified.
add gnb logo add gnb title git-svn-id: http://xe-core.googlecode.com/svn/branches/1.5.0@8888 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
parent
06e6799316
commit
df4d760117
6 changed files with 112 additions and 37 deletions
|
|
@ -190,6 +190,71 @@
|
||||||
$this->setRedirectUrl($redirectUrl);
|
$this->setRedirectUrl($redirectUrl);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @brief admin config update
|
||||||
|
**/
|
||||||
|
function procAdminUpdateConfig()
|
||||||
|
{
|
||||||
|
$adminTitle = Context::get('adminTitle');
|
||||||
|
$file = $_FILES['adminLogo'];
|
||||||
|
|
||||||
|
$oModuleModel = &getModel('module');
|
||||||
|
$oAdminConfig = $oModuleModel->getModuleConfig('admin');
|
||||||
|
|
||||||
|
if($file['tmp_name'])
|
||||||
|
{
|
||||||
|
$target_path = 'files/attach/images/admin/';
|
||||||
|
FileHandler::makeDir($target_path);
|
||||||
|
|
||||||
|
// Get file information
|
||||||
|
list($width, $height, $type, $attrs) = @getimagesize($file['tmp_name']);
|
||||||
|
if($type == 3) $ext = 'png';
|
||||||
|
elseif($type == 2) $ext = 'jpg';
|
||||||
|
else $ext = 'gif';
|
||||||
|
|
||||||
|
$target_filename = sprintf('%s%s.%s.%s', $target_path, 'adminLogo', date('YmdHis'), $ext);
|
||||||
|
@move_uploaded_file($file['tmp_name'], $target_filename);
|
||||||
|
|
||||||
|
$oAdminConfig->adminLogo = $target_filename;
|
||||||
|
}
|
||||||
|
if($adminTitle) $oAdminConfig->adminTitle = strip_tags($adminTitle);
|
||||||
|
|
||||||
|
if($oAdminConfig)
|
||||||
|
{
|
||||||
|
$oModuleController = &getController('module');
|
||||||
|
$oModuleController->insertModuleConfig('admin', $oAdminConfig);
|
||||||
|
}
|
||||||
|
|
||||||
|
$this->setMessage('success_updated', 'info');
|
||||||
|
if(!in_array(Context::getRequestMethod(),array('XMLRPC','JSON'))) {
|
||||||
|
$returnUrl = Context::get('success_return_url') ? Context::get('success_return_url') : getNotEncodedUrl('', 'module', 'admin', 'act', 'dispAdminMenuSetup');
|
||||||
|
$this->setRedirectUrl($returnUrl);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @brief admin logo delete
|
||||||
|
**/
|
||||||
|
function procAdminDeleteLogo()
|
||||||
|
{
|
||||||
|
$oModuleModel = &getModel('module');
|
||||||
|
$oAdminConfig = $oModuleModel->getModuleConfig('admin');
|
||||||
|
|
||||||
|
FileHandler::removeFile(_XE_PATH_.$oAdminConfig->adminLogo);
|
||||||
|
unset($oAdminConfig->adminLogo);
|
||||||
|
|
||||||
|
$oModuleController = &getController('module');
|
||||||
|
$oModuleController->insertModuleConfig('admin', $oAdminConfig);
|
||||||
|
|
||||||
|
$this->setMessage('success_deleted', 'info');
|
||||||
|
if(!in_array(Context::getRequestMethod(),array('XMLRPC','JSON'))) {
|
||||||
|
$returnUrl = Context::get('success_return_url') ? Context::get('success_return_url') : getNotEncodedUrl('', 'module', 'admin', 'act', 'dispAdminMenuSetup');
|
||||||
|
$this->setRedirectUrl($returnUrl);
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief Insert favorite
|
* @brief Insert favorite
|
||||||
**/
|
**/
|
||||||
|
|
|
||||||
|
|
@ -99,12 +99,19 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// Admin logo, title setup
|
||||||
|
$configObject = $oModuleModel->getModuleConfig('admin');
|
||||||
|
$gnbTitleInfo->adminTitle = $configObject->adminTitle?$configObject->adminTitle:'XE Admin';
|
||||||
|
$gnbTitleInfo->adminLogo = $configObject->adminLogo?$configObject->adminLogo:'modules/admin/tpl/img/xe.h1.png';
|
||||||
|
|
||||||
$browserTitle = 'Dashboard';
|
$browserTitle = 'Dashboard';
|
||||||
if($subMenuTitle) $browserTitle = $subMenuTitle;
|
if($subMenuTitle) $browserTitle = $subMenuTitle;
|
||||||
$browserTitle .= ' - XE Admin';
|
$browserTitle .= ' - '.$gnbTitleInfo->adminTitle;
|
||||||
|
|
||||||
Context::set('gnbUrlList', $menu->list);
|
Context::set('gnbUrlList', $menu->list);
|
||||||
Context::set('parentSrl', $parentSrl);
|
Context::set('parentSrl', $parentSrl);
|
||||||
|
Context::set('gnb_title_info', $gnbTitleInfo);
|
||||||
Context::setBrowserTitle($browserTitle);
|
Context::setBrowserTitle($browserTitle);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -320,10 +327,14 @@
|
||||||
**/
|
**/
|
||||||
function dispAdminMenuSetup()
|
function dispAdminMenuSetup()
|
||||||
{
|
{
|
||||||
|
$oModuleModel = &getModel('module');
|
||||||
|
$configObject = $oModuleModel->getModuleConfig('admin');
|
||||||
|
|
||||||
$oMenuAdminModel = &getAdminModel('menu');
|
$oMenuAdminModel = &getAdminModel('menu');
|
||||||
$output = $oMenuAdminModel->getMenuByTitle('__XE_ADMIN__');
|
$output = $oMenuAdminModel->getMenuByTitle('__XE_ADMIN__');
|
||||||
|
|
||||||
Context::set('menu_srl', $output->menu_srl);
|
Context::set('menu_srl', $output->menu_srl);
|
||||||
|
Context::set('config_object', $configObject);
|
||||||
$this->setTemplateFile('menu_setup');
|
$this->setTemplateFile('menu_setup');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -13,6 +13,8 @@
|
||||||
<action name="procAdminInsertThemeInfo" type="controller" standalone="true" ruleset="insertThemeInfo" />
|
<action name="procAdminInsertThemeInfo" type="controller" standalone="true" ruleset="insertThemeInfo" />
|
||||||
<action name="procAdminToggleFavorite" type="controller" ruleset="toggleFavorite" />
|
<action name="procAdminToggleFavorite" type="controller" ruleset="toggleFavorite" />
|
||||||
<action name="procAdminEnviromentGatheringAgreement" type="controller" standalone="true" />
|
<action name="procAdminEnviromentGatheringAgreement" type="controller" standalone="true" />
|
||||||
|
<action name="procAdminUpdateConfig" type="controller" standalone="true" />
|
||||||
|
<action name="procAdminDeleteLogo" type="controller" standalone="true" />
|
||||||
|
|
||||||
<action name="getAdminFTPList" type="model" standalone="true" />
|
<action name="getAdminFTPList" type="model" standalone="true" />
|
||||||
<action name="getSiteAllList" type="model" standalone="true" />
|
<action name="getSiteAllList" type="model" standalone="true" />
|
||||||
|
|
@ -32,17 +34,17 @@
|
||||||
<title xml:lang="tr">General</title>
|
<title xml:lang="tr">General</title>
|
||||||
</menu>
|
</menu>
|
||||||
<menu name="adminMenuSetup" type="all">
|
<menu name="adminMenuSetup" type="all">
|
||||||
<title xml:lang="en">Admin Menu Setup</title>
|
<title xml:lang="en">Admin Setup</title>
|
||||||
<title xml:lang="ko">관리자 메뉴 설정</title>
|
<title xml:lang="ko">관리자 설정</title>
|
||||||
<title xml:lang="zh-CN">Admin Menu Setup</title>
|
<title xml:lang="zh-CN">Admin Setup</title>
|
||||||
<title xml:lang="jp">Admin Menu Setup</title>
|
<title xml:lang="jp">Admin Setup</title>
|
||||||
<title xml:lang="es">Admin Menu Setup</title>
|
<title xml:lang="es">Admin Setup</title>
|
||||||
<title xml:lang="ru">Admin Menu Setup</title>
|
<title xml:lang="ru">Admin Setup</title>
|
||||||
<title xml:lang="fr">Admin Menu Setup</title>
|
<title xml:lang="fr">Admin Setup</title>
|
||||||
<title xml:lang="zh-TW">Admin Menu Setup</title>
|
<title xml:lang="zh-TW">Admin Setup</title>
|
||||||
<title xml:lang="vi">Admin Menu Setup</title>
|
<title xml:lang="vi">Admin Setup</title>
|
||||||
<title xml:lang="mn">Admin Menu Setup</title>
|
<title xml:lang="mn">Admin Setup</title>
|
||||||
<title xml:lang="tr">Admin Menu Setup</title>
|
<title xml:lang="tr">Admin Setup</title>
|
||||||
</menu>
|
</menu>
|
||||||
<menu name="theme" type="site">
|
<menu name="theme" type="site">
|
||||||
<title xml:lang="en">Theme</title>
|
<title xml:lang="en">Theme</title>
|
||||||
|
|
|
||||||
|
|
@ -1,7 +1,7 @@
|
||||||
<div class="xe">
|
<div class="xe">
|
||||||
<p class="skipNav"><a href="#content">Skip Navigation</a></p>
|
<p class="skipNav"><a href="#content">Skip Navigation</a></p>
|
||||||
<div class="header">
|
<div class="header">
|
||||||
<h1><a href="{getUrl('','module','admin')}"><img src="img/xe.h1.png" width="33" height="32" alt="XE" /> Super Admin</a></h1>
|
<h1><a href="{getUrl('','module','admin')}"><img src="{getUrl('')}{$gnb_title_info->adminLogo}" alt="{$gnb_title_info->adminTitle}" /> {$gnb_title_info->adminTitle}</a></h1>
|
||||||
<div class="siteTool">
|
<div class="siteTool">
|
||||||
<a href="#moveSiteList" class="i tgAnchor" data-effect="slide" data-duration="100">Move to Site</a>
|
<a href="#moveSiteList" class="i tgAnchor" data-effect="slide" data-duration="100">Move to Site</a>
|
||||||
<div class="tgContent" id="moveSiteList">
|
<div class="tgContent" id="moveSiteList">
|
||||||
|
|
@ -17,7 +17,7 @@
|
||||||
</div>
|
</div>
|
||||||
<div class="account">
|
<div class="account">
|
||||||
<ul>
|
<ul>
|
||||||
<li><a href="{getUrl('', 'act', 'dispMemberInfo')}" target="_blank">{$logged_info->email_address}</a></li>
|
<li><a href="{getUrl('', 'module', 'admin', 'act', 'dispMemberAdminInfo', 'is_admin', 'Y', 'member_srl', $logged_info->member_srl)}">{$logged_info->email_address}</a></li>
|
||||||
<li><a href="{getUrl('', 'module','admin','act','procAdminLogout')}">Log-out</a></li>
|
<li><a href="{getUrl('', 'module','admin','act','procAdminLogout')}">Log-out</a></li>
|
||||||
<li><a href="#language" class="tgAnchor language" data-effect="slide" data-duration="100">Language</a>
|
<li><a href="#language" class="tgAnchor language" data-effect="slide" data-duration="100">Language</a>
|
||||||
<ul class="tgContent" id="language">
|
<ul class="tgContent" id="language">
|
||||||
|
|
|
||||||
|
|
@ -4,40 +4,36 @@
|
||||||
<div cond="$XE_VALIDATOR_MESSAGE" class="message {$XE_VALIDATOR_MESSAGE_TYPE}">
|
<div cond="$XE_VALIDATOR_MESSAGE" class="message {$XE_VALIDATOR_MESSAGE_TYPE}">
|
||||||
<p>{$XE_VALIDATOR_MESSAGE}</p>
|
<p>{$XE_VALIDATOR_MESSAGE}</p>
|
||||||
</div>
|
</div>
|
||||||
<form action="" class="form">
|
<form action="./" method="post" enctype="multipart/form-data">
|
||||||
<h1 class="h1">Admin Setting</h1>
|
<input type="hidden" name="act" value="procAdminUpdateConfig" />
|
||||||
<fieldset class="section">
|
<fieldset class="section">
|
||||||
<h2 class="h2">Title</h2>
|
<h2 class="h2">{$lang->title}</h2>
|
||||||
<ul class="form">
|
<ul class="form">
|
||||||
<li>
|
<li>
|
||||||
<p class="q">
|
<p class="q"><label for="adminTitle">관리자 페이지 제목</label></p>
|
||||||
<label for="adminTitle">관리자 페이지 제목</label>
|
<p class="a"><input type="text" name="adminTitle" id="adminTitle" value="{$config_object->adminTitle}" /></p>
|
||||||
</p>
|
|
||||||
<p class="a">
|
|
||||||
<input type="text" id="adminTitle" value="Naradesign">
|
|
||||||
</p>
|
|
||||||
</li>
|
</li>
|
||||||
<li>
|
<li>
|
||||||
<p class="q">
|
<p class="q"><label for="adminLogo">관리자 페이지 로고</label></p>
|
||||||
<label for="adminLogo">관리자 페이지 로고</label>
|
|
||||||
</p>
|
|
||||||
<p class="a"> <img src="http://dece24.xpressengine.com/xeAdmin/img/xe.h1.png">
|
|
||||||
<button type="button" class="text">Delete</button>
|
|
||||||
</p>
|
|
||||||
<p class="a">
|
<p class="a">
|
||||||
<input type="file" id="adminLogo">
|
<!--@if($config_object->adminLogo)-->
|
||||||
|
<img src="{getUrl('').$config_object->adminLogo}" />
|
||||||
|
<button type="submit" value="procAdminDeleteLogo" name="act" class="text">{$lang->cmd_delete}</button>
|
||||||
|
<!--@end-->
|
||||||
</p>
|
</p>
|
||||||
|
<p class="a"><input type="file" name="adminLogo" id="adminLogo" /></p>
|
||||||
</li>
|
</li>
|
||||||
</ul>
|
</ul>
|
||||||
<p class="btnArea"><span class="btn small"><button value="procMenuAdminArrangeItem" name="act" type="submit">{$lang->cmd_save}</button></span></p>
|
<p class="btnArea"><span class="btn small"><button value="procAdminUpdateConfig" name="act" type="submit">{$lang->cmd_save}</button></span></p>
|
||||||
</fieldset>
|
</fieldset>
|
||||||
</form>
|
</form>
|
||||||
<form id="listForm" action="./" class="siteMap" method="post">
|
<form id="listForm" action="./" class="siteMap" method="post">
|
||||||
<input type="hidden" name="act" value="procMenuAdminDeleteItem" />
|
<input type="hidden" name="act" value="procMenuAdminDeleteItem" />
|
||||||
<input type="hidden" name="menu_srl" value="{$menu_srl}" />
|
<input type="hidden" name="menu_srl" value="{$menu_srl}" />
|
||||||
<input type="hidden" name="menu_item_srl" value="" />
|
<input type="hidden" name="menu_item_srl" value="" />
|
||||||
<input type="hidden" name="success_return_url" value="{getUrl('', 'module', 'admin', 'act', 'dispAdminMenuSetup')}" />
|
<input type="hidden" name="success_return_url" value="{getUrl('', 'module', 'admin', 'act', 'dispAdminMenuSetup')}" />
|
||||||
<h2 class="h2">Menu</h2>
|
<fieldset class="section">
|
||||||
|
<h1 class="h1">{$lang->menu_gnb_sub['adminMenuSetup']}</h1>
|
||||||
<div class="adminMenu portlet">
|
<div class="adminMenu portlet">
|
||||||
<ul class="lined">
|
<ul class="lined">
|
||||||
<li class="parent" loop="$gnbUrlList=>$key,$value">
|
<li class="parent" loop="$gnbUrlList=>$key,$value">
|
||||||
|
|
@ -51,6 +47,7 @@
|
||||||
</ul>
|
</ul>
|
||||||
<p class="btnArea"><span class="btn small"><button value="procMenuAdminArrangeItem" name="act" type="submit">{$lang->cmd_save}</button></span></p>
|
<p class="btnArea"><span class="btn small"><button value="procMenuAdminArrangeItem" name="act" type="submit">{$lang->cmd_save}</button></span></p>
|
||||||
</div>
|
</div>
|
||||||
|
</fieldset>
|
||||||
</form>
|
</form>
|
||||||
|
|
||||||
<div class="modal" id="editMenu">
|
<div class="modal" id="editMenu">
|
||||||
|
|
|
||||||
|
|
@ -26,7 +26,7 @@
|
||||||
<action name="dispMemberAdminDeleteForm" type="view" standalone="true" />
|
<action name="dispMemberAdminDeleteForm" type="view" standalone="true" />
|
||||||
<action name="dispMemberAdminGroupList" type="view" standalone="true" />
|
<action name="dispMemberAdminGroupList" type="view" standalone="true" />
|
||||||
<action name="dispMemberAdminJoinFormList" type="view" standalone="true" />
|
<action name="dispMemberAdminJoinFormList" type="view" standalone="true" />
|
||||||
<action name="dispMemberAdminInfo" type="view" standalone="true" />
|
<action name="dispMemberAdminInfo" type="view" standalone="true" menu_name="userList" />
|
||||||
<action name="dispMemberAdminInsertJoinForm" type="view" standalone="true" />
|
<action name="dispMemberAdminInsertJoinForm" type="view" standalone="true" />
|
||||||
<action name="dispMemberAdminDeniedIDList" type="view" standalone="true" />
|
<action name="dispMemberAdminDeniedIDList" type="view" standalone="true" />
|
||||||
<action name="dispMemberAdminManageGroup" type="view" standalone="true" />
|
<action name="dispMemberAdminManageGroup" type="view" standalone="true" />
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue