mirror of
https://github.com/Lastorder-DC/rhymix.git
synced 2026-05-11 13:02:15 +09:00
Fix #1972 게시판 관리자가 최고관리자 보호 기능을 사용할 수 없도록 개선
This commit is contained in:
parent
ba0e0f07d1
commit
a8421268f6
2 changed files with 22 additions and 4 deletions
|
|
@ -24,7 +24,6 @@ class boardAdminController extends board {
|
||||||
{
|
{
|
||||||
// generate module model/controller object
|
// generate module model/controller object
|
||||||
$oModuleController = getController('module');
|
$oModuleController = getController('module');
|
||||||
$oModuleModel = getModel('module');
|
|
||||||
|
|
||||||
// setup the board module infortmation
|
// setup the board module infortmation
|
||||||
$args = Context::getRequestVars();
|
$args = Context::getRequestVars();
|
||||||
|
|
@ -36,7 +35,7 @@ class boardAdminController extends board {
|
||||||
// Get existing module info
|
// Get existing module info
|
||||||
if($args->module_srl)
|
if($args->module_srl)
|
||||||
{
|
{
|
||||||
$module_info = $oModuleModel->getModuleInfoByModuleSrl($args->module_srl);
|
$module_info = ModuleModel::getModuleInfoByModuleSrl($args->module_srl);
|
||||||
}
|
}
|
||||||
|
|
||||||
// setup extra_order_target
|
// setup extra_order_target
|
||||||
|
|
@ -60,8 +59,25 @@ class boardAdminController extends board {
|
||||||
if($args->anonymous_except_admin != 'Y') $args->anonymous_except_admin = 'N';
|
if($args->anonymous_except_admin != 'Y') $args->anonymous_except_admin = 'N';
|
||||||
if($args->consultation != 'Y') $args->consultation = 'N';
|
if($args->consultation != 'Y') $args->consultation = 'N';
|
||||||
if($args->protect_content != 'Y') $args->protect_content = 'N';
|
if($args->protect_content != 'Y') $args->protect_content = 'N';
|
||||||
|
if($this->user->isAdmin())
|
||||||
|
{
|
||||||
if($args->protect_admin_content_update != 'Y') $args->protect_admin_content_update = 'N';
|
if($args->protect_admin_content_update != 'Y') $args->protect_admin_content_update = 'N';
|
||||||
if($args->protect_admin_content_delete != 'Y') $args->protect_admin_content_delete = 'N';
|
if($args->protect_admin_content_delete != 'Y') $args->protect_admin_content_delete = 'N';
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
if($module_info)
|
||||||
|
{
|
||||||
|
$args->protect_admin_content_update = $module_info->protect_admin_content_update;
|
||||||
|
$args->protect_admin_content_delete = $module_info->protect_admin_content_delete;
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
$args->protect_admin_content_update = 'N';
|
||||||
|
$args->protect_admin_content_delete = 'N';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
if(!in_array($args->order_target,$this->order_target) && !array_key_exists($args->order_target, $extra_order_target)) $args->order_target = 'list_order';
|
if(!in_array($args->order_target,$this->order_target) && !array_key_exists($args->order_target, $extra_order_target)) $args->order_target = 'list_order';
|
||||||
if(!in_array($args->order_type, array('asc', 'desc'))) $args->order_type = 'asc';
|
if(!in_array($args->order_type, array('asc', 'desc'))) $args->order_type = 'asc';
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -364,6 +364,7 @@
|
||||||
<p>{$lang->about_protect_comment}</p>
|
<p>{$lang->about_protect_comment}</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<!--@if($this->user->isAdmin())-->
|
||||||
<div class="x_control-group">
|
<div class="x_control-group">
|
||||||
<label class="x_control-label">{$lang->protect_admin_content}</label>
|
<label class="x_control-label">{$lang->protect_admin_content}</label>
|
||||||
<div class="x_controls">
|
<div class="x_controls">
|
||||||
|
|
@ -372,6 +373,7 @@
|
||||||
<p>{$lang->about_protect_admin_content}</p>
|
<p>{$lang->about_protect_admin_content}</p>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<!--@end-->
|
||||||
<div class="x_control-group">
|
<div class="x_control-group">
|
||||||
<label class="x_control-label">{$lang->protect_regdate}</label>
|
<label class="x_control-label">{$lang->protect_regdate}</label>
|
||||||
<div class="x_controls">
|
<div class="x_controls">
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue