Files
SRCMS/Application/Home/Controller/HallController.class.php
Martin Zhou c3e99b9a18 SRCMS V2.2 开发版
[新增] 审核后台单个漏洞报告导出
[新增] 审核后台全部漏洞报告导出为报表
[修复] Ueditor上传路径错误导致的文件上传失败问题
[修复] 用户个人中心礼品无法兑换的问题
[修复] 前台安全应急响应中心名称动态不显示的问题
[修复] 跳转页面LOGO不显示的问题
2017-07-02 22:50:46 +08:00

50 lines
1.3 KiB
PHP

<?php
/**
* @Author: Zhou Yuyang <1009465756@qq.com> 10:28 2017/02/02
* @Copyright 2015-2020 SISMO
* @Project homepage https://github.com/CNSISMO
* @Version 2.0
*/
namespace Home\Controller;
use Think\Controller;
class HallController extends Controller{
public function index()
{
$xuhao = 1;
$model = M('member');
$tmodel= M('setting');
$settings = $tmodel -> where('id=1') -> select();
$user = $model->order('jifen DESC')->where('jifen>0')->select();
$this->assign('settings', $settings);
$this ->assign('xuhao',$xuhao);
$this->assign('user',$user);
$this->display();
}
public function view()
{
$pid = I('get.pid',0,'number_int');
$model = M('member');
$report = M('post');
$tmodel= M('setting');
$settings = $tmodel -> where('id=1') -> select();
$this->assign('settings', $settings);
$user = $model -> where(array('pid'=>$pid)) -> select();
$uid = $user[0]['id'];
if ($uid != null){
$reportnum = $report->where(array('user_id'=>$uid))->count();
$highranknum = $report->where(array('user_id'=>$uid))->where('rank=4')->count();
$this->assign('num',$reportnum);
$this->assign('highranknum',$highranknum);
};
$this->assign('user',$user);
$this->display();
}
}