<?php
$conf_basedir	= "../../";	//相对主目录的位置
$conf_where		= "admin";	//选择调用相应模块
$directory		= basename(dirname(__FILE__));	//定义当前所在的目录，引入模块公用函数
include_once($conf_basedir."base.inc.php");
checkAuth('16');	//判断登录和权限

$title = "审核记录查看";

$admin = trim($admin);
$nowdate = date("Y-m-d");
$bdate = date("Y-m-1", strtotime("-1 month"));

//获得数据当前页面数据
if($admin != "")
{
	$sql = "SELECT dateline, admin, SUM(sort0_num) AS sort0_num, SUM(sort1_num) AS sort1_num, SUM(sort2_num) AS sort2_num, SUM(remark_num) AS remark_num FROM admin_house_check_opernum_log WHERE (dateline >= '$bdate' and dateline <= '$nowdate') AND admin = '".$admin."' GROUP BY dateline ORDER BY id DESC ";
}
else
{
	$sql = "SELECT dateline, SUM(sort0_num) AS sort0_num, SUM(sort1_num) AS sort1_num, SUM(sort2_num) AS sort2_num, SUM(remark_num) AS remark_num FROM admin_house_check_opernum_log WHERE (dateline >= '$bdate' and dateline <= '$nowdate') GROUP BY dateline ORDER BY dateline DESC ";
}


$data_info = $dbback->GetAll($sql);

//引用模版文件
include_once(Template("header"));
include_once(Template("broker_house/opernum_manage"));
include_once(Template("footer"));
?>