merge from 1.7.3.5(r13153:r13167)

git-svn-id: http://xe-core.googlecode.com/svn/trunk@13168 201d5d3c-b55e-5fd7-737f-ddc643e51545
This commit is contained in:
ngleader 2013-09-29 23:32:39 +00:00
parent cc47d2b247
commit 2d3f149b5a
2042 changed files with 129266 additions and 126243 deletions

View file

@ -1,39 +1,52 @@
<?php
/**
* adminloggingController class
* controller class of adminlogging module
*
* @author NHN (developers@xpressengine.com)
* @package /modules/adminlogging
* @version 0.1
*/
class adminloggingController extends adminlogging
{
/**
* adminloggingController class
* controller class of adminlogging module
*
* @author NHN (developers@xpressengine.com)
* @package /modules/adminlogging
* @version 0.1
* Initialization
* @return void
*/
class adminloggingController extends adminlogging {
/**
* Initialization
* @return void
*/
function init() {
// forbit access if the user is not an administrator
$oMemberModel = &getModel('member');
$logged_info = $oMemberModel->getLoggedInfo();
if($logged_info->is_admin!='Y') return $this->stop("msg_is_not_administrator");
}
/**
* Insert log
* @return void
*/
function insertLog($module, $act)
function init()
{
// forbit access if the user is not an administrator
$oMemberModel = getModel('member');
$logged_info = $oMemberModel->getLoggedInfo();
if($logged_info->is_admin != 'Y')
{
if(!$module || !$act) return;
$args->module = $module;
$args->act = $act;
$args->ipaddress = $_SERVER['REMOTE_ADDR'];
$args->regdate = date('YmdHis');
$args->requestVars = print_r(Context::getRequestVars(), true);
$output = executeQuery('adminlogging.insertLog', $args);
return $this->stop("msg_is_not_administrator");
}
}
?>
}
/**
* Insert log
* @return void
*/
function insertLog($module, $act)
{
if(!$module || !$act)
{
return;
}
$args = new stdClass();
$args->module = $module;
$args->act = $act;
$args->ipaddress = $_SERVER['REMOTE_ADDR'];
$args->regdate = date('YmdHis');
$args->requestVars = print_r(Context::getRequestVars(), TRUE);
$output = executeQuery('adminlogging.insertLog', $args);
}
}
/* End of file adminlogging.controller.php */
/* Location: ./modules/adminlogging/adminlogging.controller.php */