2018-12-28 18:58:37 +08:00
|
|
|
<?php
|
|
|
|
// +----------------------------------------------------------------------
|
|
|
|
// | ShopXO 国内领先企业级B2C免费开源电商系统
|
|
|
|
// +----------------------------------------------------------------------
|
|
|
|
// | Copyright (c) 2011~2018 http://shopxo.net All rights reserved.
|
|
|
|
// +----------------------------------------------------------------------
|
|
|
|
// | Licensed ( http://www.apache.org/licenses/LICENSE-2.0 )
|
|
|
|
// +----------------------------------------------------------------------
|
|
|
|
// | Author: Devil
|
|
|
|
// +----------------------------------------------------------------------
|
|
|
|
namespace app\admin\controller;
|
|
|
|
|
|
|
|
/**
|
|
|
|
* 首页
|
|
|
|
* @author Devil
|
|
|
|
* @blog http://gong.gg/
|
|
|
|
* @version 0.0.1
|
|
|
|
* @datetime 2016-12-01T21:51:08+0800
|
|
|
|
*/
|
|
|
|
class Index extends Common
|
|
|
|
{
|
|
|
|
/**
|
|
|
|
* 构造方法
|
|
|
|
* @author Devil
|
|
|
|
* @blog http://gong.gg/
|
|
|
|
* @version 0.0.1
|
|
|
|
* @datetime 2016-12-03T12:39:08+0800
|
|
|
|
*/
|
|
|
|
public function __construct()
|
|
|
|
{
|
|
|
|
// 调用父类前置方法
|
|
|
|
parent::__construct();
|
|
|
|
|
|
|
|
// 登录校验
|
2019-02-12 11:46:46 +08:00
|
|
|
$this->IsLogin();
|
2018-12-28 18:58:37 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* [Index 首页]
|
|
|
|
* @author Devil
|
|
|
|
* @blog http://gong.gg/
|
|
|
|
* @version 0.0.1
|
|
|
|
* @datetime 2017-01-05T21:36:13+0800
|
|
|
|
*/
|
|
|
|
public function Index()
|
|
|
|
{
|
|
|
|
return $this->fetch();
|
|
|
|
}
|
|
|
|
|
|
|
|
/**
|
|
|
|
* [Init 初始化页面]
|
|
|
|
* @author Devil
|
|
|
|
* @blog http://gong.gg/
|
|
|
|
* @version 0.0.1
|
|
|
|
* @datetime 2017-01-05T21:36:41+0800
|
|
|
|
*/
|
|
|
|
public function Init()
|
|
|
|
{
|
|
|
|
$mysql_ver = db()->query('SELECT VERSION() AS `ver`');
|
|
|
|
$data = array(
|
|
|
|
'server_ver' => php_sapi_name(),
|
|
|
|
'php_ver' => PHP_VERSION,
|
|
|
|
'mysql_ver' => isset($mysql_ver[0]['ver']) ? $mysql_ver[0]['ver'] : '',
|
|
|
|
'os_ver' => PHP_OS,
|
|
|
|
'host' => isset($_SERVER["HTTP_HOST"]) ? $_SERVER["HTTP_HOST"] : '',
|
|
|
|
'ver' => 'ShopXO'.' '.APPLICATION_VERSION,
|
|
|
|
);
|
|
|
|
$this->assign('data', $data);
|
|
|
|
return $this->fetch();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
?>
|