Kaynağa Gözat

'续费管理'

Ethan 6 yıl önce
ebeveyn
işleme
0cbf280878

+ 0 - 246
application/user/controller/Admingroup.php

@@ -1,246 +0,0 @@
-<?php
-namespace app\user\controller;
-
-use think\Lang;
-
-class Admingroup extends AdminControl
-{
-    public function _initialize()
-    {
-        parent::_initialize();
-        Lang::load(APP_PATH . 'admin/lang/' . config('default_lang') . '/admingroup.lang.php');
-    }
-
-    /**
-     * 管理权限组
-     * @return mixed
-     */
-    public function index()
-    {
-        $model_admingroup = Model('admingroup');
-        $condition = array();
-        $condition['lang'] = config('default_lang');
-        $condition['suosgs'] = 1;
-        $admingroup_list = $model_admingroup->getAdminGroupList($condition,'*');
-        $allpower = $this->qxhans();
-        $this->assign('allpower',$allpower);
-        $this->assign('admin_group_list', $admingroup_list);
-        $this->setAdminCurItem('index');
-        return $this->fetch();
-    }
-
-    public function getControllers($dir) {
-        $pathList = glob($dir . '/*.php');
-        $res = [];
-        foreach($pathList as $key => $value) {
-            $res[] = basename($value, '.php');
-        }
-        return $res;
-    }
-
-    /**
-     * 添加权限组
-     * @return mixed
-     */
-    public function add()
-    {
-        if (request()->isPost()) {
-            $admin_group_model = model('admingroup');
-            //判断权限组名是否存在
-            $where['group_name'] = input('post.group_name');
-            $where['suosgs'] = 1;
-            if ($admin_group_model->getOneAdmingroup($where)) {
-                $this->error(lang('admin_group_existence'));
-            }
-            var_dump($_POST['permission']);die;
-            $limit_str = '';
-            if (is_array($_POST['permission'])) {
-                $limit_str = implode('|', $_POST['permission']);
-            }
-            $data['group_limits'] = ds_encrypt($limit_str, MD5_KEY . md5(input('post.group_name')));
-            $data['group_name'] = input('post.group_name');
-            $data['lang'] = config('default_lang');
-            $data['addtime'] = TIMESTAMP;
-            if ($admin_group_model->addAdminGroup($data)) {
-                $this->log(lang('ds_add') . lang('ds_admin_group') . '[' . input('post.group_name') . ']', 1);
-                dsLayerOpenSuccess(lang('admin_group_add_succ'));
-            } else {
-                $this->error(lang('admin_group_add_fail'));
-            }
-        } else {
-            $this->assign('admin_array', 'add');
-            $this->assign('limit', $this->permission());
-            $this->setAdminCurItem('add');
-            return $this->fetch('form');
-        }
-    }
-
-    public function edit()
-    {
-        $admin_group_model = model('admingroup');
-        $group_id = intval(input('param.group_id'));
-        $group_info = $admin_group_model->getOneAdmingroup(array('group_id' => $group_id));
-        if (empty($group_info)) {
-            $this->error(lang('admin_set_admin_not_exists'));
-        }
-        if (request()->isPost()) {
-            $limit_str = '';
-            if (is_array($_POST['permission'])) {
-                $limit_str = implode('|', $_POST['permission']);
-            }
-            $limit_str = ds_encrypt($limit_str, MD5_KEY . md5(input('post.group_name')));
-            $data['group_limits'] = $limit_str;
-            $data['group_name'] = input('post.group_name');
-            $update = $admin_group_model->editAdminGroup(array('group_id' => $group_id), $data);
-            if ($update) {
-                $this->log(lang('ds_edit') . lang('group_limits') . '[' . input('post.group_limits') . ']', 1);
-                dsLayerOpenSuccess(lang('admin_group_edit_succ'));
-            } else {
-                $this->error(lang('admin_group_edit_fail'));
-            }
-        } else {
-            //解析已有权限
-            $hlimit = ds_decrypt($group_info['group_limits'], MD5_KEY . md5($group_info['group_name']));
-            $group_info['group_limits'] = explode('|', $hlimit);
-            $this->assign('admin_array', 'edit');
-            $this->assign('group_info', $group_info);
-            $this->assign('limit', $this->permission());
-            $this->setAdminCurItem('edit');
-            return $this->fetch('form');
-        }
-    }
-
-    public function del()
-    {
-        $group_id = input('param.group_id');
-        if (empty($group_id)) {
-            $this->error(lang('param_error'));
-        }
-        $result = db('admingroup')->delete($group_id);
-        if ($result) {
-            ds_json_encode(10000, lang('admin_group_del_succ'));
-        } else {
-            ds_json_encode(10001, lang('admin_group_del_fail'));
-        }
-    }
-
-    /**
-     * 取得所有权限项
-     *
-     * @return array
-     */
-    private function permission()
-    {
-        $limit = $this->limitList();
-        if (is_array($limit)) {
-            foreach ($limit as $k => $v) {
-                if (is_array($v['child'])) {
-                    $tmp = array();
-                    foreach ($v['child'] as $key => $value) {
-                        $controller = (!empty($value['controller'])) ? $value['controller'] : $v['controller'];
-                        if (strpos($controller, '|') == false) {//controller参数不带|
-                            $limit[$k]['child'][$key]['action'] = rtrim($controller . '.' . str_replace('|', '|' . $controller . '.', $value['action']), '.');
-                        } else {//controller参数带|
-                            $tmp_str = '';
-                            if (empty($value['action'])) {
-                                $limit[$k]['child'][$key]['action'] = $controller;
-                            } elseif (strpos($value['action'], '|') == false) {//action参数不带|
-                                foreach (explode('|', $controller) as $v1) {
-                                    $tmp_str .= "$v1.{$value['action']}|";
-                                }
-                                $limit[$k]['child'][$key]['action'] = rtrim($tmp_str, '|');
-                            } elseif (strpos($value['action'], '|') != false && strpos($controller, '|') != false) {//action,controller都带|,交差权限
-                                foreach (explode('|', $controller) as $v1) {
-                                    foreach (explode('|', $value['action']) as $v2) {
-                                        $tmp_str .= "$v1.$v2|";
-                                    }
-                                }
-                                $limit[$k]['child'][$key]['action'] = rtrim($tmp_str, '|');
-                            }
-                        }
-                    }
-                }
-            }
-            return $limit;
-        } else {
-            return array();
-        }
-    }
-
-    /*
-    * 权限选择列表
-    */
-    function limitList()
-    {
-        $_limit = array(
-            array('name' => lang('ds_dashboard_manage'), 'child' => array(
-                array('name' => lang('ds_welcome'), 'action' => null, 'controller' => 'Wlcome'),
-                array('name' => lang('ds_welcome'), 'action' => "index", 'controller' => 'Wlcome'),
-            )),
-            array('name' => lang('ds_config'), 'child' => array(
-                array('name' => lang('ds_config'), 'action' => null, 'controller' => 'Config'),
-                array('name' => lang('ds_wzconfig'), 'action' => "index", 'controller' => 'Config'),
-                // array('name' => lang('ds_fzsconfig'), 'action' => "dump", 'controller' => 'Config'),
-                //array('name' => lang('ds_seoconfig'), 'action' => "seo", 'controller' => 'Config'),
-            )),
-            array('name' => "数据库设置", 'child' => array(
-                array('name' => lang('ds_db'), 'action' => null, 'controller' => 'Db'),
-                array('name' => lang('ds_bfdb'), 'action' => "index", 'controller' => 'Db'),
-                array('name' => lang('ds_hydb'), 'action' => "restore", 'controller' => 'Db'),
-            )),
-            array('name' => lang('ds_adminlog'), 'child' => array(
-                array('name' => lang('ds_adminlog'), 'action' => null, 'controller' => 'AdminLog'),
-                array('name' => lang('ds_adminczlog'), 'action' => 'index', 'controller' => 'AdminLog'),
-            )),
-            array('name' => lang('ds_member'), 'child' => array(
-                array('name' => lang('ds_member'), 'action' => null, 'controller' => 'Member'),
-                array('name' => lang('ds_glmember'), 'action' => "index", 'controller' => 'Member'),
-                array('name' => lang('ds_addmember'), 'action' => "add", 'controller' => 'Member'),
-                array('name' => lang('ds_edmember'), 'action' => "edit", 'controller' => 'Member'),
-                array('name' => lang('ds_dlmember'), 'action' => "del", 'controller' => 'Member'),
-            )),
-            array('name' => lang('ds_admin'), 'child' => array(
-                array('name' => lang('ds_admin'), 'action' => null, 'controller' => 'Admin'),
-                array('name' => lang('ds_gladmin'), 'action' => "index", 'controller' => 'Admin'),
-                array('name' => lang('ds_addadmin'), 'action' => "add", 'controller' => 'Admin'),
-                array('name' => lang('ds_edadmin'), 'action' => "edit", 'controller' => 'Admin'),
-                array('name' => lang('ds_dladmin'), 'action' => "del", 'controller' => 'Admin'),
-            )),
-            array('name' => lang('ds_admin_group'), 'child' => array(
-                array('name' => lang('ds_admin_group'), 'action' => null, 'controller' => 'AdminGroup'),
-                array('name' => lang('ds_admin_glgroup'), 'action' => "index", 'controller' => 'AdminGroup'),
-                array('name' => lang('ds_admin_addgroup'), 'action' => "add", 'controller' => 'AdminGroup'),
-                array('name' => lang('ds_admin_edgroup'), 'action' => "edit", 'controller' => 'AdminGroup'),
-                array('name' => lang('ds_admin_dlgroup'), 'action' => "del", 'controller' => 'AdminGroup'),
-            )),
-            array('name' => lang('ds_product'), 'child' => array(
-                array('name' => lang('ds_product'), 'action' => null, 'controller' => 'Product'),
-                array('name' => lang('ds_product'), 'action' => "index", 'controller' => 'Product'),
-                array('name' => lang('ds_addproduct'), 'action' => 'add', 'controller' => 'Product'),
-                array('name' => lang('ds_edproduct'), 'action' => 'edit', 'controller' => 'Product'),
-                array('name' => lang('ds_dlproduct'), 'action' => 'del', 'controller' => 'Product'),
-            )),
-            array('name' => lang('ds_message'), 'child' => array(
-                array('name' => lang('ds_message'), 'action' => null, 'controller' => 'Message'),
-                array('name' => lang('ds_glmessage'), 'action' => "index", 'controller' => 'Message'),//留言表
-                array('name' => lang('ds_ckmessage'), 'action' => "reply", 'controller' => 'Message'),
-                array('name' => lang('ds_dlmessage'), 'action' => "del", 'controller' => 'Message'),
-            )),
-        );
-
-        return $_limit;
-    }
-
-    protected function getAdminItemList()
-    {
-        $menu_array = array(
-            array(
-                'name' => 'index', 'text' => lang('ds_manage'), 'url' => url('Admingroup/index')
-            ), array(
-                'name' => 'add', 'text' => lang('ds_add'), 'url' => "javascript:dsLayerOpen('".url('Admingroup/add')."','".lang('ds_add')."')"
-
-            ),
-        );
-        return $menu_array;
-    }
-}

+ 0 - 173
application/user/controller/Adminlog.php

@@ -1,173 +0,0 @@
-<?php
-
-namespace app\user\controller;
-
-
-use think\Lang;
-
-class Adminlog extends AdminControl
-{
-    const EXPORT_SIZE = 5000;
-
-    public function _initialize()
-    {
-        parent::_initialize(); // TODO: Change the autogenerated stub
-        Lang::load(APP_PATH . 'admin/lang/' . config('default_lang') . '/adminlog.lang.php');
-    }
-
-    /**
-     * 日志列表
-     *
-     */
-    public function index()
-    {
-        $condition = array();
-        $time1 = '';
-        $time2 = '';
-        if (!empty(input('param.admin_name'))) {
-            $condition['admin_name'] = input('param.admin_name');
-        }
-        if (!empty(input('param.time_from'))) {
-            $time1 = strtotime(input('param.time_from'));
-        }
-        if (!empty(input('param.time_to'))) {
-            $time2 = strtotime(input('param.time_to'));
-            if ($time2 !== false)
-                $time2 = $time2 + 86400;
-        }
-        if ($time1 && $time2) {
-            $condition['createtime'] = array('between', array($time1, $time2));
-        } elseif ($time1) {
-            $condition['createtime'] = array('egt', $time1);
-        } elseif ($time2) {
-            $condition['createtime'] = array('elt', $time2);
-        }
-        $list = db('adminlog')->where($condition)->order('adminlog_id desc')->paginate(9, false, ['query' => request()->param()]);
-        $page = $list->render();
-        $allpower = $this->qxhans();
-        $this->assign('allpower',$allpower);
-        $this->assign('list', $list);
-        $this->assign('page', $page);
-        $this->setAdminCurItem('loglist');
-        return $this->fetch();
-    }
-
-    /**
-     * 删除日志
-     *
-     */
-    public function list_del()
-    {
-        $adminlog_id = input('param.adminlog_id');
-        $adminlog_id_array = ds_delete_param($adminlog_id);
-        if ($adminlog_id_array == FALSE) {
-            $this->error(lang('param_error'));
-        }
-        $condition = array();
-        $condition['adminlog_id'] = array('in', $adminlog_id_array);
-        if (db('adminlog')->where($condition)->delete()) {
-            $this->log(lang('ds_adminlog').'-'.lang('del_succ').'->' .lang('ds_number_id'). '[' . $adminlog_id . ']', null);
-            $this->success(lang('admin_log_del_succ'), url('adminlog/index'));
-        } else {
-            $this->error(lang('admin_log_del_fail'));
-
-        }
-    }
-
-    /**
-     * 导出第一步
-     */
-    public function export_step1()
-    {
-        $time1 = '';
-        $time2 = '';
-        $condition = array();
-        if (!empty(input('param.admin_name'))) {
-            $condition['admin_name'] = input('param.admin_name');
-        }
-        if (!empty(input('param.time_from'))) {
-            $time1 = strtotime(input('param.time_from'));
-        }
-        if (!empty(input('param.time_to'))) {
-            $time2 = strtotime(input('param.time_to'));
-            if ($time2 !== false)
-                $time2 = $time2 + 86400;
-        }
-        if ($time1 && $time2) {
-            $condition['createtime'] = array('between', array($time1, $time2));
-        } elseif ($time1) {
-            $condition['createtime'] = array('egt', $time1);
-        } elseif ($time2) {
-            $condition['createtime'] = array('elt', $time2);
-        }
-        if (!is_numeric(input('param.curpage'))) {
-            $count = db('adminlog')->where($condition)->count();
-            $array = array();
-            if ($count > self::EXPORT_SIZE) {    //显示下载链接
-                $page = ceil($count / self::EXPORT_SIZE);
-                for ($i = 1; $i <= $page; $i++) {
-                    $limit1 = ($i - 1) * self::EXPORT_SIZE + 1;
-                    $limit2 = $i * self::EXPORT_SIZE > $count ? $count : $i * self::EXPORT_SIZE;
-                    $array[$i] = $limit1 . ' ~ ' . $limit2;
-                }
-                $this->assign('list', $array);
-                $this->assign('murl', url('adminlog/list'));
-                return $this->fetch('excel');
-            } else {    //如果数量小,直接下载
-                $data = db('adminlog')->where($condition)->order('adminlog_id desc')->limit(self::EXPORT_SIZE)->select();
-                $this->createExcel($data);
-            }
-        } else {    //下载
-            $limit1 = (input('param.curpage') - 1) * self::EXPORT_SIZE;
-            $limit2 = self::EXPORT_SIZE;
-            $data = db('adminlog')->where($condition)->order('adminlog_id desc')->limit("{$limit1},{$limit2}")->select();
-            $this->createExcel($data);
-        }
-    }
-
-    /**
-     * 生成excel
-     *
-     * @param array $data
-     */
-    private function createExcel($data = array())
-    {
-        Lang::load(APP_PATH . 'admin/lang/zh-cn/export.php');
-        $excel_obj = new \excel\Excel();
-        $excel_data = array();
-        //设置样式
-        $excel_obj->setStyle(array(
-            'id' => 's_title', 'Font' => array('FontName' => '宋体', 'Size' => '12', 'Bold' => '1')
-        ));
-        //header
-        $excel_data[0][] = array('styleid' => 's_title', 'data' => lang('admin_log_man'));
-        $excel_data[0][] = array('styleid' => 's_title', 'data' => lang('admin_log_do'));
-        $excel_data[0][] = array('styleid' => 's_title', 'data' => lang('admin_log_dotime'));
-        $excel_data[0][] = array('styleid' => 's_title', 'data' => 'IP');
-        foreach ((array)$data as $k => $v) {
-            $tmp = array();
-            $tmp[] = array('data' => $v['admin_name']);
-            $tmp[] = array('data' => $v['content']);
-            $tmp[] = array('data' => date('Y-m-d H:i:s', $v['createtime']));
-            $tmp[] = array('data' => $v['ip']);
-            $excel_data[] = $tmp;
-        }
-        $excel_data = $excel_obj->charset($excel_data, CHARSET);
-        $excel_obj->addArray($excel_data);
-        $excel_obj->addWorksheet($excel_obj->charset(lang('admin_log'), CHARSET));
-        $excel_obj->generateXML($excel_obj->charset(lang('admin_log'), CHARSET) . input('param.curpage') . '-' . date('Y-m-d-H', time()));
-    }
-
-    protected function getAdminItemList()
-    {
-        $menu_array = array(
-            array(
-                'name' => 'loglist',
-                'text' => lang('admin_log'),
-                'url' => url('adminlog/loglist')
-            )
-        );
-        return $menu_array;
-
-    }
-}

+ 0 - 96
application/user/controller/Config.php

@@ -1,96 +0,0 @@
-<?php
-
-namespace app\user\controller;
-
-use think\Lang;
-use think\File;
-
-class Config extends AdminControl {
-
-    public function _initialize() {
-        parent::_initialize();
-        Lang::load(APP_PATH . 'admin/lang/' . config('default_lang') . '/config.lang.php');
-    }
-
-    /**
-     * 网站配置
-     * @return mixed
-     */
-    public function index() {
-        // var_dump(PUBLIC_PATH . DS .DIR_STATIC );
-        // var_dump(DS_THEME_STYLE_URL . 'images');
-        $model_config = model('config');
-        $allpower = $this->qxhans();
-        $this->assign('allpower',$allpower);
-        if (!request()->isPost()) {
-            $list_config = $model_config->getListConfig();
-            $this->assign('list_config', $list_config);
-            $this->setAdminCurItem('index');
-            return $this->fetch();
-        } else {
-            $update_array = array();
-            $update_array['site_state'] = isset($_POST['site_state']) ? '1' : '';
-            $update_array['site_name'] = $_POST['site_name'];
-            $update_array['icp_number'] = $_POST['icp_number'];
-            $update_array['site_phone'] = $_POST['site_phone'];
-            $update_array['flow_static_code'] = $_POST['flow_static_code'];
-            $update_array['fax'] = $_POST['fax'];
-
-            $imgurl = DS_THEME_STYLE_URL . 'images';
-            $numurl = '/static/home/images';
-            $file = request()->file('site_logo');
-            if($file){
-                $imgname = "logo";//官网logo
-                $file = $file->setSaveName($imgname);//设置保存文件名
-                $imgo = $file->move($imgurl, $savename = false, $replace = true);
-                if($imgo){
-                    $update_array['site_logo'] = $imgname.'.png';
-                }
-            }
-
-            $files = request()->file('site_logowx');
-            if($files){
-                $wximgname = "code";//微信二维码
-                $files = $files->setSaveName($wximgname);//设置保存文件名
-                $imgt = $files->move($imgurl, $savename = false, $replace = true);
-                if($imgt){
-                    $update_array['site_logowx'] = $wximgname.'.png';
-                }
-            }
-            
-            $files = request()->file('site_logowb');
-            if($files){
-                $wximgname = "blog";//微信二维码
-                $files = $files->setSaveName($wximgname);//设置保存文件名
-                $imgt = $files->move($imgurl, $savename = false, $replace = true);
-                if($imgt){
-                    $update_array['site_logowb'] = $wximgname.'.png';
-                }
-            }
-
-            $result = $model_config->updateConfig($update_array);
-            if ($result === true) {
-                $this->log(lang('ds_edit') . lang('dis_dump'), 1);
-                $this->success('修改成功', 'Config/index');
-            } else {
-                $this->log(lang('ds_edit') . lang('dis_dump'), 0);
-                $this->error(lang('修改失败'));
-            }
-        }
-    }
-
-    /**
-     * 获取卖家栏目列表,针对控制器下的栏目
-     */
-    protected function getAdminItemList() {
-        $menu_array = array(
-            array(
-                'name' => 'base',
-                'text' => lang('site_set'),
-                'url' => url('Admin/Config/index')
-            ),
-        );
-        return $menu_array;
-    }
-
-}

+ 0 - 341
application/user/controller/Db.php

@@ -1,341 +0,0 @@
-<?php
-
-namespace app\user\controller;
-use think\Lang;
-
-//数据库备份根路径
-define('DATA_BACKUP_PATH', 'uploads/sqldata/');
-//数据库备份卷大小  20971520表示为 20M
-//define('DATA_BACKUP_PART_SIZE', 20971520);
-define('DATA_BACKUP_PART_SIZE', 1024 * 1024 * 10);
-//数据库备份文件是否启用压缩
-define('DATA_BACKUP_COMPRESS', 0);
-//数据库备份文件压缩级别
-define('DATA_BACKUP_COMPRESS_LEVEL', 9);
-
-class Db extends AdminControl
-{
-
-    public function _initialize()
-    {
-        parent::_initialize(); // TODO: Change the autogenerated stub
-        Lang::load(APP_PATH . 'admin/lang/' . config('default_lang') . '/db.lang.php');
-
-    }
-
-    public function index()
-    {
-        $dbtables = db('member')->query('SHOW TABLE STATUS');
-        $total = 0;
-        foreach ($dbtables as $k => $v) {
-            $dbtables[$k]['size'] = format_bytes($v['Data_length'] + $v['Index_length']);
-            $total += $v['Data_length'] + $v['Index_length'];
-        }
-        $allpower = $this->qxhans();
-        $this->assign('allpower',$allpower);
-        $this->assign('list', $dbtables);
-        $this->assign('total', format_bytes($total));
-        $this->assign('tableNum', count($dbtables));
-        $this->setAdminCurItem('db');
-        return $this->fetch('db');
-    }
-
-    public function export($tables = null, $id = null, $start = null)
-    {
-        //防止备份数据过程超时
-        function_exists('set_time_limit') && set_time_limit(0);
-        if (request()->isPost() && !empty($tables) && is_array($tables)) { //初始化
-            $path = DATA_BACKUP_PATH;
-            if (!is_dir($path)) {
-                mkdir($path, 0755, true);
-            }
-            //读取备份配置
-            $config = array(
-                'path' => realpath($path) . DIRECTORY_SEPARATOR,
-                'part' => DATA_BACKUP_PART_SIZE,
-                'compress' => DATA_BACKUP_COMPRESS,
-                'level' => DATA_BACKUP_COMPRESS_LEVEL,
-            );
-            //检查是否有正在执行的任务
-            $lock = "{$config['path']}backup.lock";
-            if (is_file($lock)) {
-                return json(array('info' => '检测到有一个备份任务正在执行,请稍后再试!', 'status' => 0, 'url' => ''));
-            } else {
-                //创建锁文件
-                file_put_contents($lock, TIMESTAMP);
-            }
-
-            //检查备份目录是否可写
-            if (!is_writeable($config['path'])) {
-                return json(array('info' => '备份目录不存在或不可写,请检查后重试!', 'status' => 0, 'url' => ''));
-            }
-            session('backup_config', $config);
-
-            //生成备份文件信息
-            $file = array(
-                'name' => date('Ymd-His', $_SERVER['REQUEST_TIME']),
-                'part' => 1,
-            );
-            session('backup_file', $file);
-            //缓存要备份的表
-            session('backup_tables', $tables);
-            //创建备份文件
-            $Database = new \mall\Backup($file, $config);
-            if (false !== $Database->create()) {
-                $tab = array('id' => 0, 'start' => 0);
-                return json(array('tables' => $tables, 'tab' => $tab, 'info' => '初始化成功!', 'status' => 1, 'url' => ''));
-            } else {
-                return json(array('info' => '初始化失败,备份文件创建失败!', 'status' => 0, 'url' => ''));
-            }
-        } elseif (request()->isGet() && is_numeric($id) && is_numeric($start)) { //备份数据
-            $tables = session('backup_tables');
-            //备份指定表
-            $Database = new \mall\Backup(session('backup_file'), session('backup_config'));
-            $start = $Database->backup($tables[$id], $start);
-            if (false === $start) { //出错
-                return json(array('info' => '备份出错!', 'status' => 0, 'url' => ''));
-            } elseif (0 === $start) { //下一表
-                if (isset($tables[++$id])) {
-                    $tab = array('id' => $id, 'start' => 0);
-                    return json(array('tab' => $tab, 'info' => '备份完成!', 'status' => 1, 'url' => ''));
-                } else { //备份完成,清空缓存
-                    unlink(session('backup_config.path') . 'backup.lock');
-                    session('backup_tables', null);
-                    session('backup_file', null);
-                    session('backup_config', null);
-                    return json(array('info' => '备份完成!', 'status' => 1, 'url' => ''));
-                }
-            } else {
-                $tab = array('id' => $id, 'start' => $start[0]);
-                $rate = floor(100 * ($start[0] / $start[1]));
-                return json(array('tab' => $tab, 'info' => "正在备份...({$rate}%)", 'status' => 1, 'url' => ''));
-            }
-        } else {
-            //出错
-            return json(array('info' => '参数错误!', 'status' => 0, 'url' => ''));
-        }
-    }
-
-    public function restore()
-    {
-        $path = DATA_BACKUP_PATH;
-        if (!is_dir($path)) {
-            mkdir($path, 0755, true);
-        }
-        $path = realpath($path);
-        $flag = \FilesystemIterator::KEY_AS_FILENAME;
-        $glob = new \FilesystemIterator($path, $flag);
-        $list = array();
-        $filenum = $total = 0;
-        foreach ($glob as $name => $file) {
-            if (preg_match('/^\d{8,8}-\d{6,6}-\d+\.sql(?:\.gz)?$/', $name)) {
-                $name = sscanf($name, '%4s%2s%2s-%2s%2s%2s-%d');
-                $date = "{$name[0]}-{$name[1]}-{$name[2]}";
-                $time = "{$name[3]}:{$name[4]}:{$name[5]}";
-                $part = $name[6];
-                $info = pathinfo($file);
-                if (isset($list["{$date} {$time}"])) {
-                    $info = $list["{$date} {$time}"];
-                    $info['part'] = max($info['part'], $part);
-                    $info['size'] = $info['size'] + $file->getSize();
-                } else {
-                    $info['part'] = $part;
-                    $info['size'] = $file->getSize();
-                }
-                $info['compress'] = ($info['extension'] === 'sql') ? '-' : $info['extension'];
-                $info['time'] = strtotime("{$date} {$time}");
-                $filenum++;
-                $total += $info['size'];
-                $list["{$date} {$time}"] = $info;
-            }
-        }
-        $allpower = $this->qxhans();
-        $this->assign('allpower',$allpower);
-        $this->assign('list', $list);
-        $this->assign('filenum', $filenum);
-        $this->assign('total', $total);
-        $this->setAdminCurItem('restore');
-        return $this->fetch();
-    }
-
-    /**
-     * 执行还原数据库操作
-     * @param int $time
-     * @param null $part
-     * @param null $start
-     */
-    public function import($time = 0, $part = null, $start = null)
-    {
-        function_exists('set_time_limit') && set_time_limit(0);
-
-        if (is_numeric($time) && is_null($part) && is_null($start)) { //初始化
-            //获取备份文件信息
-            $name = date('Ymd-His', $time) . '-*.sql*';
-            $path = realpath(DATA_BACKUP_PATH) . DIRECTORY_SEPARATOR . $name;
-            $files = glob($path);
-            $list = array();
-            foreach ($files as $name) {
-                $basename = basename($name);
-                $match = sscanf($basename, '%4s%2s%2s-%2s%2s%2s-%d');
-                $gz = preg_match('/^\d{8,8}-\d{6,6}-\d+\.sql.gz$/', $basename);
-                $list[$match[6]] = array($match[6], $name, $gz);
-            }
-            ksort($list);
-
-            //检测文件正确性
-            $last = end($list);
-            if (count($list) === $last[0]) {
-                session('backup_list', $list); //缓存备份列表
-                $this->success('初始化完成!', NULL, ['part' => 1, 'start' => 0]);
-            } else {
-                $this->error('备份文件可能已经损坏,请检查!');
-            }
-        } elseif (is_numeric($part) && is_numeric($start)) {
-            $list = session('backup_list');
-            $db = new \mall\Backup($list[$part], array(
-                    'path' => realpath(DATA_BACKUP_PATH) . DIRECTORY_SEPARATOR,
-                    'compress' => $list[$part][2])
-            );
-            $start = $db->import($start);
-            if (false === $start) {
-                $this->error('还原数据出错!');
-            } elseif (0 === $start) { //下一卷
-                if (isset($list[++$part])) {
-                    $data = array('part' => $part, 'start' => 0);
-                    $this->success("正在还原...#{$part}", null, $data);
-                } else {
-                    session('backup_list', null);
-                    $this->success('还原完成!');
-                }
-            } else {
-                $data = array('part' => $part, 'start' => $start[0]);
-                if ($start[1]) {
-                    $rate = floor(100 * ($start[0] / $start[1]));
-                    $this->success("正在还原...#{$part} ({$rate}%)", null, $data);
-                } else {
-                    $data['gz'] = 1;
-                    $this->success("正在还原...#{$part}", null, $data);
-                }
-            }
-        } else {
-            $this->error('参数错误!');
-        }
-    }
-
-    /**
-     * 优化
-     */
-    public function optimize()
-    {
-        $batchFlag = intval(input('param.batchFlag'));
-        //批量删除
-        if ($batchFlag) {
-            $table = I('key', array());
-        } else {
-            $table[] = input('param.tablename');
-        }
-        if (empty($table)) {
-            $this->error('请选择要优化的表');
-        }
-
-        $strTable = implode(',', $table);
-
-        if (!db()->query("OPTIMIZE TABLE {$strTable} ")) {
-            $strTable = '';
-        }
-        $this->success("优化表成功" . $strTable, url('Admin/Db/index'));
-    }
-
-    /**
-     * 修复
-     */
-    public function repair()
-    {
-        $batchFlag = intval(input('param.batchFlag'));
-        //批量删除
-        if ($batchFlag) {
-            $table = I('key', array());
-        } else {
-            $table[] = input('param.tablename');
-        }
-
-        if (empty($table)) {
-            $this->error('请选择修复的表');
-        }
-
-        $strTable = implode(',', $table);
-        if (!db()->query("REPAIR TABLE {$strTable} ")) {
-            $strTable = '';
-        }
-
-        $this->success("修复表成功" . $strTable, url('Admin/Db/index'));
-    }
-
-    /**
-     * 下载
-     * @param int $time
-     */
-    public function downFile($time = 0)
-    {
-        $name = date('Ymd-His', $time) . '-*.sql*';
-        $path = realpath(DATA_BACKUP_PATH) . DIRECTORY_SEPARATOR . $name;
-        $files = glob($path);
-        if (is_array($files)) {
-            foreach ($files as $filePath) {
-                if (!file_exists($filePath)) {
-                    $this->error("该文件不存在,可能是被删除");
-                } else {
-                    $filename = basename($filePath);
-                    header("Content-type: application/octet-stream");
-                    header('Content-Disposition: attachment; filename="' . $filename . '"');
-                    header("Content-Length: " . filesize($filePath));
-                    readfile($filePath);
-                }
-            }
-        }
-    }
-
-    /**
-     * 删除备份文件
-     * @param  Integer $time 备份时间
-     */
-    public function del($time = 0)
-    {
-        if ($time) {
-            $name = date('Ymd-His', $time) . '-*.sql*';
-            $path = realpath(DATA_BACKUP_PATH) . DIRECTORY_SEPARATOR . $name;
-            array_map("unlink", glob($path));
-            if (count(glob($path))) {
-                $this->error('备份文件删除失败,请检查权限!');
-            } else {
-                $this->success('备份文件删除成功!');
-            }
-        } else {
-            $this->error('参数错误!');
-        }
-    }
-
-    /**
-     * 获取卖家栏目列表,针对控制器下的栏目
-     */
-    protected function getAdminItemList()
-    {
-        $menu_array = array(
-            array(
-                'name' => 'db',
-                'text' => '数据备份',
-                'url' => url('Admin/Db/index')
-            ),
-            array(
-                'name' => 'restore',
-                'text' => '数据还原',
-                'url' => url('Admin/Db/restore')
-            ),
-        );
-
-        return $menu_array;
-    }
-
-}
-
-?>

+ 0 - 138
application/user/controller/Message.php

@@ -1,138 +0,0 @@
-<?php
-
-namespace app\user\controller;
-
-use think\Lang;
-use think\Validate;
-
-class Message extends AdminControl
-{
-    public function _initialize()
-    {
-        parent::_initialize();
-        Lang::load(APP_PATH . 'admin/lang/' . config('default_lang') . '/message.lang.php');
-    }
-
-    /**
-     * 留言管理
-     */
-    public function index()
-    {
-        $model_message = Model('message');
-        if(request()->isPost()){
-            $lyaddtime = $_POST['lyaddtime'];
-        }else{
-            $lyaddtime = 0;
-        }
-
-        if($lyaddtime==1){
-            $kstime = strtotime(date("Y-m-d 23:59:59",strtotime("-3 day")));
-        }elseif($lyaddtime==2){
-            $kstime = strtotime(date("Y-m-d 23:59:59",strtotime("-1 week")));
-        }elseif($lyaddtime==3){
-            $kstime = strtotime(date("Y-m-d",strtotime("-1 month")));
-        }else{
-            $kstime = "1546272000";
-        }
-        $endtime = TIMESTAMP;
-
-        if (input('post.kstime')) {
-            $kstime = strtotime(input('post.kstime'));
-        }
-        if (input('post.endtime')) {
-            $endtime = strtotime(input('post.endtime'));
-        }
-
-        $readok = input('post.message_readok');
-        $condition = array();
-        $condition['message_addtime'] = array('between', array($kstime, $endtime));
-        if($readok){
-            $condition['message_readok'] = $readok;
-        }
-        $message_list = $model_message->getMessageList($condition, '*', 10);
-        // var_dump($message_list);die;
-        if($message_list){
-            for ($i=0; $i < count($message_list); $i++) { 
-                $where['admin_id'] = $message_list[$i]["admin_id"];
-                $admin_list[] = model('admin')->getOneAdmin($where,$field = 'admin_name');
-            }
-            $this->assign('admin_list',$admin_list);
-        }
-        $allgs = Model('member')->allcompany('');
-        $allpower = $this->qxhans();
-        $this->assign('allgs',$allgs);
-        $this->assign('allpower',$allpower);
-        $this->assign('message_list', $message_list);
-        $this->assign('lyaddtime',$lyaddtime);
-        $this->assign('endtime',$endtime);
-        $this->assign('kstime',$kstime);
-        $this->assign('show_page', $model_message->page_info->render());
-        $this->setAdminCurItem('index');
-        return $this->fetch();
-    }
-
-    /**
-     * 留言回复
-     */
-    public function reply(){
-        $message_id = intval(input('param.message_id'));
-        if (!request()->isPost()) {
-            $message = model('message')->getOneMessage(['message_id' => $message_id]);
-            $this->assign('message', $message);
-            $this->setAdminCurItem('reply');
-            return $this->fetch('form');
-        } else {
-            $data = array(
-                'admin_id' => $this->admin_info['admin_id'],
-                'message_useinfo' => input('post.message_useinfo'),
-                'message_result' => input('post.message_result'),
-                'message_readok' => 1,
-                'message_replytime' => TIMESTAMP,
-            );
-
-            $result = model('message')->editMessage(['message_id' => $message_id], $data);
-            if ($result) {
-                $this->log(lang('ds_message').'-'.lang('edit_succ') . '[' . $data['message_useinfo'] . ']', null);
-                dsLayerOpenSuccess(lang('edit_succ'));
-            } else {
-                $this->error(lang('edit_fail'));
-            }
-        }
-        $this->setAdminCurItem('form');
-        return $this->fetch();
-    }
-
-    /**
-     * 删除留言
-     */
-    public function del()
-    {
-        $message_id = intval(input('param.message_id'));
-        if ($message_id) {
-            $condition['message_id'] = $message_id;
-            $result = model('message')->delMessage($condition);
-            if ($result) {
-                $this->log(lang('ds_message').'-'.lang('del_succ') . '[' . $message_id . ']', null);
-                ds_json_encode(10000, lang('del_succ'));
-            } else {
-                ds_json_encode(10001, lang('del_fail'));
-            }
-        } else {
-            ds_json_encode(10001, lang('del_fail'));
-        }
-
-    }
-
-    protected function getAdminItemList()
-    {
-        $menu_array = array(
-            array(
-                'name' => 'index', 'text' => lang('ds_manage'), 'url' => url('message/index'),
-            )
-        );
-        return $menu_array;
-    }
-
-}
-
-?>

+ 0 - 71
application/user/controller/Pic.php

@@ -1,71 +0,0 @@
-<?php
-
-namespace app\user\controller;
-class Pic extends AdminControl
-{
-    public function upload()
-    {
-        if (!empty($_FILES['file']['name'])) {
-
-            $pic_type_id = intval(input('param.pic_type_id'));
-            $pic_type = input('param.pic_type');
-            switch ($pic_type){
-                case 'product':
-                    $pic_type_url = ATTACH_PRODUCT;
-                    break;
-                case 'cases':
-                    $pic_type_url = ATTACH_CASES;
-                    break;
-                case 'news':
-                    $pic_type_url = ATTACH_NEWS;
-                    break;
-                default:
-                    break;
-            }
-            $upload_file = BASE_UPLOAD_PATH . DS . $pic_type_url;
-            $upload = request()->file('file');
-            $info = $upload->validate(['ext' => 'jpg,png,gif,jpeg'])->move($upload_file);
-            if ($info) {
-                $file_name = $info->getFilename();
-                $save_name = $info->getSaveName();
-                list($width, $height, $type, $attr) = getimagesize($upload_file . DS . $save_name);
-                $insert = array(
-                    'pic_type' => $pic_type,
-                    'pic_type_id' => $pic_type_id,
-                    'pic_name' => $file_name,
-                    'pic_cover' => $save_name,
-                    'pic_size' => intval($_FILES['file']['size']),
-                    'pic_time' => TIMESTAMP,
-                );
-                $result = model('pic')->addpic($insert);
-                $file_url = "get_".$pic_type."_Img";
-                if ($result) {
-                    $data = array(
-                        'file_id' => $result,
-                        'file_name' => $file_name,
-                        'file_url' => $file_url($save_name)
-                    );
-                    $output = json_encode($data);
-                    echo $output;
-                }
-            }
-        }
-    }
-
-    /**
-     * 删除图片
-     */
-    function del()
-    {
-        $pic_id = intval(input('param.file_id'));
-        $pic_type = intval(input('param.pic_type'));
-        if ($pic_id > 0) {
-            $result = model('pic')->delPic(array('pic_id' => $pic_id),$pic_type);
-            if ($result > 0) {
-                echo 'true';
-                exit;
-            }
-        }
-        echo 'false';
-    }
-}

+ 0 - 182
application/user/controller/Product.php

@@ -1,182 +0,0 @@
-<?php
-namespace app\user\controller;
-use think\Controller;
-use think\Lang;
-use think\Request;
-
-class Product extends AdminControl
-{
-    public function _initialize()
-    {
-        parent::_initialize();
-        Lang::load(APP_PATH . 'admin/lang/' . config('default_lang') . '/product.lang.php');
-    }
-
-    public function index()
-    {
-        $model_product = Model('product');
-        $product_keywords = input('post.product_keywords');
-        $product_type = input('post.product_type');
-        $condition = array();
-        if($product_keywords){
-            $condition['product_keywords'] = $product_keywords;
-        }
-        if($product_type){
-            $condition['product_type'] = $product_type;
-        }
-        $product_list = $model_product->getProductList($condition,'*',10);
-        
-        $allpower = $this->qxhans();
-        $this->assign('allpower',$allpower);
-        $this->assign('product_list', $product_list);
-        $this->assign('show_page', $model_product->page_info->render());
-        $this->setAdminCurItem('index');
-        return $this->fetch();
-    }
-
-    public function add()
-    {
-        $allpower = $this->qxhans();
-        $this->assign('allpower',$allpower);
-        if (request()->isPost()) {
-            $data = array(
-                'product_type' => input('post.product_type'),
-                'product_title' => input('post.product_title'),
-                'product_ctitle' => input('post.product_ctitle'),
-                'product_keywords' => input('post.product_keywords'),
-                'product_status' => input('post.product_status'),
-                'product_isjump' => input('post.product_isjump'),
-                'product_content' => input('post.product_content'),
-            );
-            if (!input('param.product_addtime')) {
-                $data['product_addtime'] = TIMESTAMP;
-            } else {
-                $data['product_addtime'] = strtotime(input('param.product_addtime'));
-            }
-
-            $result = model('product')->addproduct($data);
-            if ($result){
-                $this->success(lang('add_succ'), url('product/index'));
-            }
-            $this->error(lang('add_fail'));
-        } else {
-            $product = array(
-                'product_isjump' => 0,
-                'product_status' => 0,
-                'product_type' => '',
-            );
-            $pic_list = model('pic')->getPicList(array('pic_id' => 0));
-            $this->assign('product', $product);
-            $this->assign('product_pic_type', ['pic_type' => 'product']);
-            $this->assign('pic_list', $pic_list);
-            $this->setAdminCurItem('add');
-            return $this->fetch('form');
-        }
-    }
-
-    public function edit()
-    {
-        $allpower = $this->qxhans();
-        $this->assign('allpower',$allpower);
-        $product_id = input('param.product_id');
-        if ($product_id <= 0) {
-            $this->error('系统错误');
-        }
-        $condition['pic_type'] = 'product';
-        $condition['pic_type_id'] = $product_id;
-        if (request()->isPost()) {
-            $data = array(
-                'product_type' => input('post.product_type'),
-                'product_title' => input('post.product_title'),
-                'product_ctitle' => input('post.product_ctitle'),
-                'product_keywords' => input('post.product_keywords'),
-                'product_status' => input('post.product_status'),
-                'product_isjump' => input('post.product_isjump'),
-                'product_content' => input('post.product_content'),
-            );
-            if (!input('param.product_updatetime')) {
-                $data['product_updatetime'] = TIMESTAMP;
-            } else {
-                $data['product_updatetime'] = strtotime(input('param.product_updatetime'));
-            }
-
-            $result = model('product')->editproduct(['product_id' => $product_id], $data);
-            if ($result >= 0) {
-                $this->success(lang('edit_succ'), 'product/index');
-            } else {
-                $this->error(lang('edit_fail'));
-            }
-        } else {
-            $pic_list = model('pic')->getpicList($condition);
-            $this->assign('pic_list', $pic_list);
-            $where = array();
-            //获取当前帮助中心的内容
-            $product = model('product')->getOneProduct(['product_id' => $product_id]);
-            $this->assign('product_pic_type', ['pic_type' => 'product']);
-            $this->assign('product', $product);
-            $this->setAdminCurItem('edit');
-            return $this->fetch('form');
-        }
-    }
-
-    function del()
-    {
-        $product_id = intval(input('param.product_id'));
-        if ($product_id) {
-            $condition['product_id'] = $product_id;
-            $result = model('product')->delproduct($condition);
-            if ($result) {
-                ds_json_encode(10000, lang('del_succ'));
-            } else {
-                ds_json_encode(10001, lang('del_fail'));
-            }
-        } else {
-            ds_json_encode(10001, lang('param_error'));
-        }
-    }
-
-    function ajax()
-    {
-        $branch = input('param.branch');
-        switch ($branch) {
-            case 'product':
-                $product_mod = model('product');
-                $condition = array('product_id' => intval(input('param.id')));
-                $update[input('param.column')] = input('param.value');
-                $product_mod->editproduct($condition, $update);
-                echo 'true';
-        }
-    }
-
-    function setproduct()
-    {
-        $product_type = input('param.product_type');
-        $product_id = input('param.product_id');
-        $res = model('product')->getOneProduct(['product_id' => $product_id], $product_type);
-        $id = $res[$product_type] == 0 ? 1 : 0;
-        $update[$product_type] = $id;
-        $condition['product_id'] = $product_id;
-        if (model('product')->editproduct($condition, $update)) {
-            ds_json_encode(10000, lang('edit_succ'));
-        } else {
-            $this->error(lang('edit_fail'));
-        }
-    }
-
-    protected function getAdminItemList()
-    {
-        $menu_array = array(
-            array(
-                'name' => 'index', 'text' => '管理', 'url' => url('product/index')
-            ), array(
-                'name' => 'add', 'text' => '新增', 'url' => url('product/add')
-            ),
-        );
-        if (request()->action() == 'edit') {
-            $menu_array[] = array(
-                'name' => 'edit', 'text' => '编辑', 'url' => url('product/edit')
-            );
-        }
-        return $menu_array;
-    }
-}

+ 48 - 28
application/user/controller/Renewal.php

@@ -1,6 +1,7 @@
 <?php
 
 namespace app\user\controller;
+
 use think\Lang;
 
 class Renewal extends UserControl
@@ -12,14 +13,15 @@ class Renewal extends UserControl
         Lang::load(APP_PATH . 'admin/lang/' . config('default_lang') . '/db.lang.php');
 
     }
+
     public function index()
     {
         $condition['user_id'] = session('user_id');
         $type = input('get.type');
         $nowDate = date('Y-m-d');
-        if (count($type)) {
+        if (strlen($type)) {
             if ($type > 0) {
-                $maturityTime = date('Y-m-d', strtotime ($type . " day"));
+                $maturityTime = date('Y-m-d', strtotime($type . " day"));
                 $condition['userProduct_maturityTime'] = array('between', array($nowDate, $maturityTime));
             } else {
                 $condition['userProduct_maturityTime'] = array('<', $nowDate);
@@ -42,15 +44,16 @@ class Renewal extends UserControl
 
         return $this->fetch('index');
     }
+
     public function renewal()
     {
         $userId = session('user_id');
         $type = input('post.type');
         $userProduct_id = input('post.renewal_id');
         $product_id = input('post.product_id');
-        $product = model('product')->getProductWhere(['product_id'=>$product_id, 'product_status'=>1]);
-        if(!$product) {
-            return ["msg"=>"错误:该产品已停售"];
+        $product = model('product')->getProductWhere(['product_id' => $product_id, 'product_status' => 1]);
+        if (!$product) {
+            return ["msg" => "错误:该产品已停售"];
         }
         $userInfo = model('userinfo')->getInfo($userId);
         switch (intval($type)) {
@@ -67,37 +70,54 @@ class Renewal extends UserControl
                 $money = $product->product_TypeFour;
         }
         if ($userInfo->userInfo_money >= $money) {
-            $findRenewal = model('renewal')->findRenewal(['renewal_status'=>1,'renewal_identity'=>$type]);
+            $findRenewal = model('renewal')->findRenewal(['renewal_status' => 1, 'renewal_identity' => $type]);
         } else {
-            return ["msg"=>"错误:您的余额不足"];
+            return ["msg" => "错误:您的余额不足"];
         }
         if (!$findRenewal) {
-            return ["msg"=>"错误:该期限已不支持购买"];
+            return ["msg" => "错误:该期限已不支持购买"];
         }
-
         $day = $findRenewal->renewal_day;
         $cashMoney = $userInfo->userInfo_money - $money;
-        /*$model = model('userinfo');
-        $model->startTrans();*/
-        $updateUserInfo = model('userinfo')->updateInfo($userId, ['userInfo_money' => $cashMoney]);
-        $nowDate = date('Y-m-d');
-        $userProduct = model('Userproduct')->findUserProduct(['userProduct_id' => $userProduct_id]);
-        $data['userProduct_dayNumber'] = $userProduct->userProduct_dayNumber + $day;
-        $data['userproduct_identity'] = OrderID();
-        $data['userProduct_buyTime'] = $nowDate;
-        /*if ($userProduct->userProduct_maturityTime > $nowDate) {
-            $data['userProduct_maturityTime'] = date('Y-m-d', strtotime(intval($day) . " day", strtotime($userProduct->userProduct_maturityTime)));
-        } else {
-            $data['userProduct_maturityTime'] = date('Y-m-d', strtotime(intval($day) . " day", $nowDate));
-        }*/
-        $updateUserProduct = model('Userproduct')->updateUserProduct(['userProduct_id' => $userProduct_id], $data);
-        // 提交事务
-        if ($updateUserInfo && $updateUserProduct) {
-            /*$model->commit();*/
+        $dbUserInfo = model('Userinfo');
+        $dbUserProduct = model('Userproduct');
+        $dbOrder = model('Order');
+        $dbUserInfo->startTrans();
+        $dbUserProduct->startTrans();
+        $dbOrder->startTrans();
+        try {
+            $dbUserInfo->updateInfo($userId, ['userInfo_money' => $cashMoney]);
+            $nowDate = date('Y-m-d');
+            $userProduct = model('Userproduct')->findUserProduct(['userProduct_id' => $userProduct_id]);
+            $data['userProduct_dayNumber'] = $userProduct->userProduct_dayNumber + $day;
+            $orderID = OrderID();
+            $data['userproduct_identity'] = $orderID;
+            $data['userProduct_buyTime'] = $nowDate;
+            if ($userProduct->userProduct_maturityTime > $nowDate) {
+                $data['userProduct_maturityTime'] = date('Y-m-d', strtotime(intval($day) . " day", strtotime($userProduct->userProduct_maturityTime)));
+            } else {
+                $data['userProduct_maturityTime'] = date('Y-m-d', strtotime(intval($day) . " day"));
+            }
+            $dbUserProduct->updateUserProduct(['userProduct_id' => $userProduct_id], $data);
+            $addOrderData = [
+                'order_identity' => $orderID,
+                'user_id' => $userId,
+                'product_id' => $product_id,
+                'order_dayNumber' => $day,
+                'order_buyTime' => $nowDate,
+                'order_money' => $money,
+            ];
+            $dbOrder->addOrder($addOrderData);
+            // 提交事务
+            $dbUserInfo->commit();
+            $dbUserProduct->commit();
+            $dbOrder->commit();
             return ["msg" => "续费成功"];
-        } else {
+        } catch (\Exception $e) {
             // 回滚事务
-            /*$model->rollBack();*/
+            $dbUserInfo->rollBack();
+            $dbUserProduct->rollBack();
+            $dbOrder->rollBack();
             return ["msg" => "操作失败"];
         }
     }

+ 1 - 1
application/user/controller/UserControl.php

@@ -122,7 +122,7 @@ class UserControl extends Controller
             'product_sever' => array(
                 'name' => 'product_sever',
                 'text' => lang('ds_product_sever'),
-				'url' => url('Config/index'),
+				'url' => url('Product/index'),
             ),
             'personnel_manage' => array(
                 'name' => 'personnel_manage',

+ 0 - 69
application/user/controller/Wlcome.php

@@ -1,69 +0,0 @@
-<?php
-
-namespace app\user\controller;
-
-use think\Lang;
-use think\Cache;
-
-class Wlcome extends UserControl
-{
-
-    public function _initialize()
-    {
-        parent::_initialize();
-        Lang::load(APP_PATH . 'admin/lang/' . config('default_lang') . '/index.lang.php');
-    }
-
-
-    /**
-     * 首页
-     * @return mixed
-     */
-    public function index()
-    {
-        $setup_date = config('setup_date');
-        $statistics['os'] = PHP_OS;
-        $statistics['web_server'] = $_SERVER['SERVER_SOFTWARE'];
-        $statistics['php_version'] = PHP_VERSION;
-        $statistics['sql_version'] = $this->_mysql_version();
-        $statistics['setup_date'] = substr($setup_date, 0, 10);
-
-        $statistics['domain'] = $_SERVER['HTTP_HOST'];
-        $statistics['ip'] = GetHostByName($_SERVER['SERVER_NAME']);
-        $statistics['zlib'] = function_exists('gzclose') ? 'YES' : 'NO'; //zlib
-        $statistics['safe_mode'] = (boolean)ini_get('safe_mode') ? 'YES' : 'NO'; //safe_mode = Off
-        $statistics['timezone'] = function_exists("date_default_timezone_get") ? date_default_timezone_get() : "no_timezone";
-        $statistics['curl'] = function_exists('curl_init') ? 'YES' : 'NO';
-        $statistics['fileupload'] = @ini_get('file_uploads') ? ini_get('upload_max_filesize') : 'unknown';
-        $statistics['max_ex_time'] = @ini_get("max_execution_time") . 's'; //脚本最大执行时间
-        $statistics['set_time_limit'] = function_exists("set_time_limit") ? true : false;
-        $statistics['memory_limit'] = ini_get('memory_limit');
-        $statistics['version'] = file_get_contents(APP_PATH . 'version.php');
-        if (function_exists("gd_info")) {
-            $gd = gd_info();
-            $statistics['gdinfo'] = $gd['GD Version'];
-        } else {
-            $statistics['gdinfo'] = lang('Unknown');
-        }
-
-        $this->assign('statistics', $statistics);
-        return $this->fetch('index');
-    }
-
-    private function _mysql_version()
-    {
-        $version = db()->query("select version() as ver");
-        return $version[0]['ver'];
-    }
-
-    protected function getAdminItemList()
-    {
-        $menu_array = array(
-            array(
-                'name' => 'index', 'text' => "欢迎界面", 'url' => url('Wlcome/index')
-            )
-        );
-        return $menu_array;
-    }
-
-}

+ 6 - 0
application/user/model/Order.php

@@ -18,5 +18,11 @@ class Order extends Model
 
         return $result;
     }
+    public function addOrder($data)
+    {
+        $result = $this->insert($data);
+
+        return $result;
+    }
 
 }

+ 0 - 73
application/user/view/admingroup/form.html

@@ -1,73 +0,0 @@
-{extend name="layout:home" /}
-{block name="container"}
-<form method="post">
-    <div class="layui-tab layui-tab-card">
-        <div class="layui-tab-content page-tab-content">
-            <div class="layui-tab-item layui-show ">
-                <div class="layui-form-item">
-                    <label class="layui-form-label">{$Think.lang.admin_group_name}</label>
-                    <div class="layui-input-block">
-                        <input type="text" class="layui-input field-name" name="group_name" id="group_name"
-                               value="{$group_info.group_name|default=''}" lay-verify="group_name" autocomplete="off"
-                               placeholder="{:lang('ds_please_enter')}{:lang('admin_group_name')}" required/>
-                    </div>
-                </div>
-                <table class="ds-default-table">
-                    <thead>
-                    <tr class="space">
-                        <th><input id="limitAll" value="1" type="checkbox">&nbsp;&nbsp;{$Think.lang.admin_group_set_limt}</th>
-                    </tr>
-                    </thead>
-                    <tbody>
-                    {foreach name="limit" item="v" key="k" }
-                    <tr>
-                        <td>
-                            <label style="width:100px">{$v.nav|default=''}</label>
-                            <input id="limit{$k}" type="checkbox" onclick="selectLimit('limit{$k}')">
-                            <label for="limit{$k}"><b>{$v.name}</b></label>
-                            {foreach name="$v.child" item="xv" key="xk" }
-                            {if condition="$admin_array eq 'add'"}
-                            <label><input dstype='limit' class="limit{$k}" type="checkbox" name="permission[]" value="{$xv.action}">{$xv.name}&nbsp;</label>
-                            {else/}
-                            <label><input dstype="limit{$k}" class="limit{$k}" type="checkbox" name="permission[]" value="{$xv.action}" <?php if(in_array(substr($xv['action'],0,($t=strpos($xv['action'],'|'))?$t:100),$group_info['group_limits'])){ echo "checked=\"checked\""; }?>>{$xv.name}&nbsp;</label>
-                            {/if}
-                            {/foreach}
-                        </td>
-                    </tr>
-                    {/foreach}
-                    </tbody>
-                </table>
-                <div class="layui-form-item">
-                    <div class="layui-input-block">
-                        <input type="submit" class="layui-btn layui-btn-normal" lay-submit value="{:lang('ds_submit')}"/>
-                    </div>
-                </div>
-            </div>
-        </div>
-    </div>
-</form>
-<script>
-    function selectLimit(name) {
-        if ($('#' + name).prop('checked')) {
-            $('.' + name).prop('checked', true);
-        } else {
-            $('.' + name).prop('checked', false);
-        }
-    }
-    $(function () {
-        $('#limitAll').on('click', function () {
-            if ($(this).prop('checked')) {
-                $(this).parents('table').find('input:checkbox').prop('checked', true);
-            } else {
-                $(this).parents('table').find('input:checkbox').prop('checked', false);
-            }
-        });
-    });
-    layui.use('form', function () {
-        var form = layui.form;
-    });
-</script>
-{/block}
-
-
-

+ 0 - 42
application/user/view/admingroup/index.html

@@ -1,42 +0,0 @@
-{extend name="layout:home" /}
-{block name="container"}
-<div class="layui-tab layui-tab-card">
-    {include file="layout/admin_items" /}
-    <div class="layui-tab-content page-tab-content">
-        <table class="layui-table lay-even">
-            <colgroup>
-                <col width="150">
-                <col width="200">
-                <col>
-            </colgroup>
-            <thead>
-            <tr>
-                <th>{$Think.lang.admin_group_name}</th>
-                <th>创建时间</th>
-                <th>{$Think.lang.ds_operation}</th>
-            </tr>
-            </thead>
-            <tbody>
-            {if $admin_group_list}
-            {volist name="admin_group_list" id="admin_group"}
-            <tr>
-                <td>{$admin_group.group_name}</td>
-                <td>{$admin_group.addtime|date="Y-m-d H:i:s",###}</td>
-                <td>
-                    {if array_intersect(explode(" ",str_replace("/", ".","admingroup/edit")),$allpower)}
-                        <a href="javascript:dsLayerOpen('{:url('Admingroup/edit',['group_id'=>$admin_group.group_id])}','{$Think.lang.ds_edit}-{$admin_group.group_name}')" class="layui-btn layui-btn-xs"><i class="layui-icon layui-icon-edit"></i>{$Think.lang.ds_edit}</a>
-                    {/if}
-                    {if array_intersect(explode(" ",str_replace("/", ".","admingroup/del")),$allpower)}
-                        <a href="javascript:dsLayerConfirm('{:url('Admingroup/del',['group_id'=>$admin_group.group_id])}','{$Think.lang.admin_group_confirm_del}')" class="layui-btn layui-btn-xs layui-btn-danger"><i class="layui-icon layui-icon-delete"></i>{$Think.lang.ds_del}</a>
-                    {/if}
-                </td>
-            </tr>
-            {/volist}
-            {else}
-            <td>无数据</td>
-            {/if}
-            </tbody>
-        </table>
-    </div>
-</div>
-{/block}

+ 0 - 93
application/user/view/adminlog/index.html

@@ -1,93 +0,0 @@
-{extend name="layout:home" /}
-{block name="container"}
-<div class="layui-tab layui-tab-card">
-    {include file="layout/admin_items" /}
-    <div>&nbsp;</div>
-    <form method="get" class="layui-form layui-form-pane">
-        <input type="hidden" name="delago" id="delago" value="">
-        <div class="layui-form-item">
-            <div class="layui-input-inline" style="width: 250px;">
-                <label class="layui-form-label">{$Think.lang.admin_log_man}</label>
-                <input name="admin_name" value="{$Request.get.admin_name}" type="text" class="layui-input field-name float_input" id="admin_name"
-                       style="display: inline-block;width: 50%;"/>
-            </div>
-            <div class="layui-input-inline" style="width: 440px;">
-                <label class="layui-form-label">{$Think.lang.admin_log_dotime}</label>
-                <input value="{$Request.get.time_from}" id="time_from" name="time_from" type="text" class="layui-input field-name"
-                       style="display: inline-block;width: 30%;"/>
-                <label for="time_to">~</label>
-                <input value="{$Request.get.time_to}" id="time_to" name="time_to" type="text" class="layui-input field-name"
-                       style="display: inline-block;width: 30%;"/>
-            </div>
-            <div class="layui-input-inline">
-                <input type="submit" class="layui-btn layui-btn-normal" lay-submit value="{:lang('ds_search')}"/>
-                <input type="reset" class="layui-btn layui-btn-warm" value="{:lang('ds_reset')}"/>
-                <input type="button" class="layui-btn laydate-day-next" onclick="location.href = '{:url('Adminlog/export_step1')}'" value="{$Think.lang.ds_export}"/>
-            </div>
-        </div>
-    </form>
-    <div class="layui-tab-content page-tab-content">
-        <table class="layui-table lay-even">
-            <colgroup>
-                <col width="50">
-            </colgroup>
-            <thead>
-            <tr>
-                <th></th>
-                <th>{$Think.lang.admin_log_man}</th>
-                <th>{$Think.lang.admin_log_do}</th>
-                <th class="align-center">{$Think.lang.admin_log_dotime}</th>
-                <th class="align-center">IP</th>
-            </tr>
-            </thead>
-            <tbody>
-            {notempty name="list"}
-            {volist name="list" id="v"}
-            <tr>
-                <td class="w24">
-                    <input type="checkbox" class="checkitem" value="{$v.adminlog_id}">
-                </td>
-                <td>{$v.admin_name}</td>
-                <td>{$v.content}</td>
-                <td class="align-center">{$v.createtime|date="Y-m-d H:i:s",###}</td>
-                <td class="align-center">{$v.ip}</td>
-            </tr>
-            {/volist}
-            {else}
-            <tr class="no_data">
-                <td colspan="10">{$Think.lang.ds_no_record}</td>
-            </tr>
-            {/notempty}
-            </tbody>
-            <tfoot class="tfoot">
-            {notempty name="list"}
-            <tr class="tfoot">
-                <td><input type="checkbox" class="checkall" id="checkallBottom" name="chkVal"></td>
-                <td colspan="16"><label for="checkallBottom">{$Think.lang.ds_select_all}</label>
-                    &nbsp;&nbsp;<a href="JavaScript:void(0);" class="btn btn-small" onclick="submit_delete_batch()"><span>{$Think.lang.ds_del}</span></a>
-                </td>
-            </tr>
-            {/notempty}
-            </tfoot>
-        </table>
-        {$page}
-    </div>
-</div>
-<script>
-    layui.use('laydate', function () {
-        var laydate = layui.laydate;
-        //执行一个laydate实例
-        laydate.render({
-            elem: '#time_from' //指定元素
-        });
-        //执行一个laydate实例
-        laydate.render({
-            elem: '#time_to' //指定元素
-        });
-    });
-    function submit_delete(ids_str){
-        _uri = ADMINSITEURL+"/Adminlog/list_del.html?adminlog_id=" + ids_str;
-        dsLayerConfirm(_uri,'{$Think.lang.ds_confirm_cancel}');
-    }
-</script>
-{/block}

+ 0 - 94
application/user/view/config/index.html

@@ -1,94 +0,0 @@
-{extend name="layout:home" /}
-
-{block name="container"}
-<form class="layui-form layui-form-pane" method="post" action="" enctype="multipart/form-data">
-    <div class="layui-tab layui-tab-card">
-        {include file="layout/admin_items" /}
-        <div class="layui-tab-content page-tab-content">
-            <div class="layui-tab-item layui-show ">
-
-                <div class="layui-form-item">
-                    <label class="layui-form-label">{$Think.lang.site_name}</label>
-                    <div class="layui-input-inline">
-                        <input type="text" class="layui-input field-name" name="site_name" id="site_name" value="{$list_config.site_name|default=''}" lay-verify="" autocomplete="off" placeholder="{$Think.lang.ds_please_enter}{$Think.lang.site_name}" required />
-                    </div>
-                </div>
-                <div class="layui-form-item">
-                    <label class="layui-form-label">{$Think.lang.icp_number}</label>
-                    <div class="layui-input-inline">
-                        <input type="text" class="layui-input field-name" name="icp_number" id="icp_number" value="{$list_config.icp_number|default=''}" lay-verify="" autocomplete="off" placeholder="{$Think.lang.ds_please_enter}{$Think.lang.icp_number}" required />
-                    </div>
-                </div>
-                <div class="layui-form-item">
-                    <label class="layui-form-label">{$Think.lang.site_phone}</label>
-                    <div class="layui-input-inline">
-                        <input type="text" class="layui-input field-name" name="site_phone" id="site_phone" value="{$list_config.site_phone|default=''}" lay-verify="" autocomplete="off" placeholder="{$Think.lang.ds_please_enter}{$Think.lang.site_phone}" required />
-                    </div>
-                </div>
-                <div class="layui-form-item">
-                    <label class="layui-form-label">{$Think.lang.flow_static_code}</label>
-                    <div class="layui-input-inline">
-                        <input type="text" class="layui-input field-name" name="flow_static_code" id="flow_static_code" value="{$list_config.flow_static_code|default=''}" lay-verify="" autocomplete="off" placeholder="{$Think.lang.ds_please_enter}{$Think.lang.flow_static_code}" required />
-                    </div>
-                </div>
-                <div class="layui-form-item">
-                    <label class="layui-form-label">{$Think.lang.fax}</label>
-                    <div class="layui-input-inline">
-                        <input type="text" class="layui-input field-name" name="fax" id="fax" value="{$list_config.fax|default=''}" lay-verify="" autocomplete="off" placeholder="{$Think.lang.ds_please_enter}{$Think.lang.fax}" required />
-                    </div>
-                </div>
-                <div class="layui-form-item">
-                    <label class="layui-form-label">{$Think.lang.site_logowx}</label>
-                    <div class="layui-input-inline">
-                        <input type="file" name="site_logowx" />
-                    </div>
-                </div>
-                <div class="layui-form-item">
-                    <label class="layui-form-label">{$Think.lang.site_logo}</label>
-                    <div class="layui-input-inline">
-                        <input type="file" name="site_logo" />
-                    </div>
-                </div>
-                <div class="layui-form-item">
-                    <label class="layui-form-label">{$Think.lang.site_logowb}</label>
-                    <div class="layui-input-inline">
-                        <input type="file" name="site_logowb" />
-                    </div>
-                </div>
-
-                <div class="layui-form-item">
-                    <label class="layui-form-label">{$Think.lang.site_state}</label>
-                    <div class="layui-input-block">
-                        <input type="checkbox" name="site_state" lay-skin="switch" lay-text="开启|关闭" value="1" {if
-                               condition="$list_config.site_state eq '1'" }checked{/if}>
-                    </div>
-                </div>
-                <div class="layui-form-item">
-                    <div class="layui-input-block">
-                        <input type="submit" class="layui-btn layui-btn-normal" lay-submit value="{:lang('ds_submit')}"/>
-                    </div>
-                </div>
-            </div>
-        </div>
-    </div>
-</form>
-<script>
-    layui.use('form', function () {
-        var form = layui.form;
-    });
-</script>
-<script>
-    //Demo
-    layui.use('form', function () {
-        var form = layui.form;
-
-        //监听提交
-        form.on('submit(formDemo)', function (data) {
-            layer.msg(JSON.stringify(data.field));
-            return false;
-        });
-    });
-</script>
-
-{/block}
-

+ 0 - 155
application/user/view/db/db.html

@@ -1,155 +0,0 @@
-{extend name="layout:home" /}
-{block name="container"}
-<div class="layui-tab layui-tab-card">
-    {include file="layout/admin_items" /}
-    <div class="layui-tab-content page-tab-content">
-        <div class="explanation" id="explanation">
-            <div class="title" id="checkZoom">
-                <h4 title="提示相关设置操作时应注意的要点">操作提示</h4>
-                <span id="explanationZoom" title="收起提示" class="arrow"></span>
-            </div>
-            <ul>
-                <li>1.会员相关信息。</li>
-            </ul>
-        </div>
-        <div class="mDiv">
-            <div class="ftitle">
-                <div style="width: 100px;float: left;line-height: 56px;"><h3>数据库表列表</h3></div>
-                <div style="width: 300px;float: left;line-height: 56px;"><h5>(共{$tableNum}张记录,共计{$total})</h5></div>
-            </div>
-            <a id="export" class="layui-btn layui-btn-primary " style="background-color: #009688;color: #fff;margin-top: 10px;">数据备份</a>
-        </div>
-        <form method="post" id="export-form" action="{:url('Admin/Db/export')}">
-            <div class="layui-tab-content page-tab-content">
-                <table class="layui-table lay-even">
-                    <colgroup>
-                        <col width="80">
-                        <col width="200">
-                        <col width="100">
-                        <col width="200">
-                        <col width="200">
-                        <col width="150">
-                        <col>
-                    </colgroup>
-                    <thead>
-                    <tr>
-                        <th><input type="checkbox" onclick="javascript:$('input[name*=tables]').prop('checked', this.checked);">全选</th>
-                        <th>数据库表</th>
-                        <th>记录条数</th>
-                        <th>占用空间</th>
-                        <th>编码</th>
-                        <th>冗余</th>
-                        <th>创建时间</th>
-                        <th>备注</th>
-                        <th>操作</th>
-                    </tr>
-                    </thead>
-                    <tbody>
-                    {notempty name="list"}
-                    {volist name="list" id="db"}
-                    <tr data-id="{$db.Name}">
-                        <td>
-                            <input type="checkbox" name="tables[]" value="{$db.Name}">
-                        </td>
-                        <td class="align-center">
-                            {$db.Name}
-                        </td>
-                        <td class="align-center">
-                            {$db.Rows}
-                        </td>
-                        <td class="align-center">
-                            {$db.Data_length|format_bytes}
-                        </td>
-                        <td class="align-center">
-                            {$db.Collation}
-                        </td>
-
-                        <td>{$db['Data_free']/1024} kb
-                        </td>
-                        <td class="align-center">
-                            {$db.Create_time}
-                        </td>
-                        <td>{$db['Comment']}
-                        </td>
-                        <td class="align-center">
-                            <div style="text-align: center;">
-                                <a href="{:url('Admin/Db/optimize',array('tablename'=>$db['Name']))}" class="layui-btn layui-btn-xs">优化</a>
-                                <a href="{:url('Admin/Db/repair',array('tablename'=>$db['Name']))}" class="layui-btn layui-btn-xs layui-btn-danger">修复</a>
-                            </div>
-                        </td>
-                    </tr>
-                    {/volist}
-                    {else}
-                    <tr class="no_data">
-                        <td colspan="11">{$Think.lang.ds_no_record}</td>
-                    </tr>
-                    {/notempty}
-                    </tbody>
-                </table>
-
-            </div>
-        </form>
-    </div>
-</div>
-<script>
-    (function ($) {
-        var $form = $("#export-form"), $export = $("#export"), tables;
-        $export.click(function () {
-            if ($("input[name^='tables']:checked").length == 0) {
-                alert('请选中要备份的数据表');
-                return false;
-            }
-            $export.addClass("disabled");
-            $export.html("正在发送备份请求...");
-            $.post(
-                $form.attr("action"),
-                $form.serialize(),
-                function (data) {
-                    if (data.status) {
-                        tables = data.tables;
-                        $export.html(data.info + "开始备份,请不要关闭本页面!");
-                        backup(data.tab);
-                        window.onbeforeunload = function () {
-                            return "正在备份数据库,请不要关闭!"
-                        }
-                    } else {
-                        alert(data.info);
-                        $export.removeClass("disabled");
-                        $export.html("立即备份");
-                    }
-                },
-                "json"
-            );
-            return false;
-        });
-
-        function backup(tab, status) {
-            status && showmsg(tab.id, "开始备份...(0%)");
-            $.get($form.attr("action"), tab, function (data) {
-                if (data.status) {
-                    showmsg(tab.id, data.info);
-                    if (!$.isPlainObject(data.tab)) {
-                        $export.removeClass("disabled");
-                        $export.html("备份完成,点击重新备份");
-                        window.onbeforeunload = function () {
-                            return null
-                        }
-                        return;
-                    }
-                    backup(data.tab, tab.id != data.tab.id);
-                } else {
-                    $export.removeClass("disabled");
-                    $export.html("立即备份");
-                }
-            }, "json");
-
-        }
-
-        function showmsg(id, msg) {
-            $("input[value=" + tables[id] + "]").closest("tr").find(".info").html(msg);
-//                            $("input[value=" + tables[id] + "]").closest("tr").hide(3000);
-        }
-    })(jQuery);
-</script>
-{/block}
-

+ 0 - 146
application/user/view/db/restore.html

@@ -1,146 +0,0 @@
-{extend name="layout:home" /}
-{block name="container"}
-<div class="layui-tab layui-tab-card">
-    {include file="layout/admin_items" /}
-    <!-- 操作说明 -->
-    <div class="layui-tab-content page-tab-content" id="flexigrid">
-        <div class="explanation" id="explanation">
-            <div class="title" id="checkZoom">
-                <h4 title="提示相关设置操作时应注意的要点">操作提示</h4>
-                <span id="explanationZoom" title="收起提示" class="arrow"></span>
-            </div>
-            <ul>
-                <li> 数据还原, 点击恢复选项进行数据库导入.</li>
-                <li> 导入的SQL文件语句必须按照MYSQL的语法编写</li>
-            </ul>
-        </div>
-
-        <div class="mDiv">
-            <div class="ftitle">
-                <div style="width: 100px;float: left;line-height: 56px;"><h3>sql文件列表</h3></div>
-                <div style="width: 300px;float: left;line-height: 56px;"><h5>(备份文件数量:{$filenum},占空间大小:{$total|format_bytes})</h5></div>
-            </div>
-            <div title="刷新数据" class="pReload"><i class="fa fa-refresh"></i></div>
-        </div>
-        <table class="layui-table lay-even">
-            <colgroup>
-                <col width="150">
-                <col width="200">
-                <col width="200">
-                <col>
-                <col width="150">
-            </colgroup>
-            <thead>
-            <tr>
-                <th align="left" abbr="article_title" axis="col3" class="">
-                    <div style="text-align: left; width: 200px;" class="">文件名称</div>
-                </th>
-                <th align="center" abbr="ac_id" axis="col4" class="">
-                    <div style="text-align: center; width: 50px;" class="">卷号</div>
-                </th>
-                <th align="center" abbr="article_show" axis="col5" class="">
-                    <div style="text-align: center; width: 50px;" class="">压缩</div>
-                </th>
-                <th align="center" abbr="article_time" axis="col6" class="">
-                    <div style="text-align: center; width: 150px;" class="">数据大小</div>
-                </th>
-                <th align="center" abbr="article_show" axis="col7" class="">
-                    <div style="text-align: center; width: 150px;" class="">备份时间</div>
-                </th>
-                <th align="center" abbr="article_show" axis="col8" class="">
-                    <div style="text-align: center; width: 130px;" class="">状态</div>
-                </th>
-                <th align="center" axis="col1" class="handle">
-                    <div style="text-align: center; width: 250px;">操作</div>
-                </th>
-            </tr>
-            </thead>
-            <tbody>
-            {notempty name="list"}
-            {volist name="list" id="vo"}
-            <tr>
-                <td align="left" class="">
-                    <div style="text-align: left; width: 200px;">{$vo.basename}</div>
-                </td>
-                <td align="center" class="">
-                    <div style="text-align: center; width: 50px;">{$vo.part}</div>
-                </td>
-                <td align="center" class="">
-                    <div style="text-align: center; width: 50px;">{$vo.compress}</div>
-                </td>
-                <td align="center" class="">
-                    <div style="text-align: center; width: 150px;">{$vo.size|format_bytes}</div>
-                </td>
-                <td align="center" class="">
-                    <div style="text-align: center; width: 150px;">{$vo.time|date="Y-m-d H:i:s",###}</div>
-                </td>
-                <td align="center" class="">
-                    <div style="text-align: center; width: 130px;">-</div>
-                </td>
-                <td align="center" class="handle">
-                    <div style="text-align: center; width: 170px; max-width:170px;">
-                        <a value="{:url('/Admin/Db/import',['time'=>$vo.time])}" href="javascript:void(0)" class="db-import"><i
-                                class="fa fa-repeat"></i>恢复</a> |
-                        <a href="{:url('/Admin/Db/downFile',['time'=>$vo.time])}"><i class="fa fa-download"></i>下载</a> |
-                        <a href="{:url('/Admin/Db/del',['time'=>$vo.time])}"><i class="fa fa-trash"></i>删除</a>
-                    </div>
-                </td>
-            </tr>
-            {/volist}
-            {else}
-            <tr class="no_data">
-                <td colspan="11">{$Think.lang.ds_no_record}</td>
-            </tr>
-            {/notempty}
-            </tbody>
-        </table>
-    </div>
-</div>
-<script>
-
-    $(document).ready(function () {
-        // 表格行点击选中切换
-        $('#flexigrid > table>tbody >tr').click(function () {
-            $(this).toggleClass('trSelected');
-        });
-
-        // 点击刷新数据
-        $('.fa-refresh').click(function () {
-            location.href = location.href;
-        });
-    });
-
-    $(".db-import").click(function () {
-
-        var self = this, status = ".";
-        $.get($('.db-import').attr('value'), success, "json");
-        window.onbeforeunload = function () {
-            return "正在还原数据库,请不要关闭!"
-        }
-        function success(data) {
-            if (data.code) {
-                if (data.gz) {
-                    data.info += status;
-                    if (status.length === 5) {
-                        status = ".";
-                    } else {
-                        status += ".";
-                    }
-                }
-                $(self).parent().parent().prev().find('div').text(data.msg);
-                if (data.data) {
-                    $.get($('.db-import').attr('value'), {"part": data.data.part, "start": data.data.start}, success, "json");
-                } else {
-                    window.onbeforeunload = function () {
-                        return null;
-                    }
-                }
-            } else {
-                layer.alert(data.msg, {icon: 2});
-            }
-        }
-    });
-</script>
-{/block}
-
-    

+ 0 - 54
application/user/view/message/form.html

@@ -1,54 +0,0 @@
-{extend name="layout:home" /}
-
-{block name="container"}
-<form class="layui-form layui-form-pane" method="post" enctype="multipart/form-data" >
-    <div class="layui-tab layui-tab-card">
-        <div class="layui-tab-content page-tab-content">
-            <div class="layui-tab-item layui-show ">
-                <div class="layui-form-item">
-                    <label class="layui-form-label">{$Think.lang.message_customer}</label>
-                    <div class="layui-input-inline">
-                        <input type="text" class="layui-input field-name" value="{$message.message_customer}" disabled />
-                    </div>
-                </div>
-                <div class="layui-form-item">
-                    <label class="layui-form-label">{$Think.lang.message_phone}</label>
-                    <div class="layui-input-inline">
-                        <input type="text" class="layui-input field-name" class="layui-input field-name" value="{$message.message_phone}" disabled />
-                    </div>
-                </div>
-                <div class="layui-form-item">
-                    <label class="layui-form-label">{$Think.lang.message_content}</label>
-                    <div class="layui-input-inline">
-                        <textarea class="layui-textarea" disabled>{$message.message_content}</textarea>
-                    </div>
-                </div>
-                <div class="layui-form-item">
-                    <label class="layui-form-label"><b>{$Think.lang.message_useinfo}</b></label>
-                    <div class="layui-input-inline">
-                        <textarea class="layui-textarea field-name" name="message_useinfo" placeholder="{$Think.lang.ds_please_enter}{$Think.lang.message_useinfo}">{$message.message_useinfo}</textarea>
-                    </div>
-                </div>
-                <div class="layui-form-item">
-                    <label class="layui-form-label"><b>处理结果</b></label>
-                    <div class="layui-input-inline">
-                        <textarea class="layui-textarea field-name" name="message_result" placeholder="{$Think.lang.ds_please_enter}处理结果">{$message.message_result}</textarea>
-                    </div>
-                </div>
-                <div class="layui-form-item">
-                    <div class="layui-input-inline">
-                        <input type="submit" class="layui-btn layui-btn-normal" lay-submit value="{:lang('ds_submit')}" />
-                    </div>
-                </div>
-            </div>
-        </div>
-    </div>
-</form>
-<script>
-    layui.use('form', function () {
-        var form = layui.form;
-    });
-</script>
-{/block}
-
-

+ 0 - 98
application/user/view/message/index.html

@@ -1,98 +0,0 @@
-{extend name="layout:home" /}
-{block name="container"}
-<div class="layui-tab layui-tab-card">
-    {include file="layout/admin_items" /}
-    <div class="layui-tab-content page-tab-content">
-        <form action="" method="post" enctype="multipart/form-data" >
-            <div class="layui-form-item">
-                <div class="layui-inline">
-                    <select name="lyaddtime" lay-verify="" class="layui-select layui-unselect layui-form-select">
-                        <option value ="{$lyaddtime}">{if $lyaddtime==1}近三天{elseif $lyaddtime==2/}最近一周{elseif $lyaddtime==3/}最近一月{else}所有{/if}</option>
-                        <option value ="0">所有</option>
-                        <option value ="1">近三天</option>
-                        <option value="2">最近一周</option>
-                        <option value="3">最近一月</option>
-                    </select>
-                </div>
-                <div class="layui-inline">
-                    <select name="message_readok" lay-verify="" class="layui-select layui-unselect layui-form-select">
-                        <option value="">请选择是否处理</option>
-                        <option value="1">已处理</option>
-                        <option value="2">未处理</option>
-                    </select>
-                </div>
-                <div class="layui-inline">
-                    <button type="submit" class="layui-btn search-subBtn">搜索</button>
-                </div>
-            </div>
-        </form>
-        <table class="layui-table lay-even">
-            <colgroup>
-                <col width="150">
-                <col>
-            </colgroup>
-            <thead>
-                <tr>
-                    <th>{$Think.lang.message_customer}</th>
-                    <th>{$Think.lang.message_phone}</th>
-                    <th>留言内容</th>
-                    <th>{$Think.lang.message_readok}</th>
-                    <th>{$Think.lang.message_useinfo}</th>
-                    <th>处理结果</th>
-                    <th>回复者</th>
-                    <th>{$Think.lang.message_addtime}</th>
-                    <th>处理时间</th>
-                    <th>{$Think.lang.ds_operation}</th>
-                </tr>
-            </thead>
-            <tbody>
-            {if $message_list}
-            {volist name="message_list" id="message" key="k"}
-            <tr>
-                <td>{$message.message_customer ?: '匿名'}</td>
-                <td>{$message.message_phone}</td>
-                <td>{$message.message_content}</td>
-                <td>{if condition="$message.message_readok eq 1"}否{else}是{/if}</td>
-                <td>{$message.message_useinfo ?: '暂未回复'}</td>
-                <td>{$message.message_result ?: '暂未结果'}</td>
-                <td>{$admin_list[$k-1]['admin_name']}</td>
-                <td>{$message.message_addtime|date='Y-m-d H:i:s',###}</td>
-                <td>{$message.message_replytime|date='Y-m-d H:i:s',###}</td>
-                <td>
-                    {if array_intersect(explode(" ",str_replace("/", ".","message/reply")),$allpower)}
-                        <a href="javascript:dsLayerOpen('{:url('message/reply',['message_id'=>$message.message_id])}','留意着-{$message.message_phone}')"class="layui-btn layui-btn-xs"><i class="layui-icon layui-icon-edit"></i>{$Think.lang.ds_view}</a>
-                    {/if}
-                    {if array_intersect(explode(" ",str_replace("/", ".","message/del")),$allpower)}
-                        <a href="javascript:dsLayerConfirm('{:url('message/del',['message_id'=>$message.message_id])}','{$Think.lang.ds_confirm_cancel}')" class="layui-btn layui-btn-danger layui-btn-xs"><i class="layui-icon layui-icon-delete"></i>{$Think.lang.ds_del}</a>
-                    {/if}
-                </td>
-            </tr>
-            {/volist}
-            {else}
-            <td>无数据</td>
-            {/if}
-        </tbody>
-        </table>
-        {$show_page}
-    </div>
-</div>
-<script type="text/javascript" src="{$Think.ADMIN_SITE_ROOT}/js/jquery.edit.js"></script>
-<script>
-    layui.use('form', function () {
-        var form = layui.form;
-    });
-    layui.use('laydate', function(){
-        var laydate = layui.laydate;
-        laydate.render({
-            elem: '#kstime'
-        });
-    });
-    layui.use('laydate', function(){
-        var laydate = layui.laydate;
-        laydate.render({
-            elem: '#endtime'
-        });
-    });
-</script>
-
-{/block}

+ 0 - 164
application/user/view/product/form.html

@@ -1,164 +0,0 @@
-{extend name="layout:home" /}
-
-{block name="container"}
-<form class="layui-form" method="post" enctype="multipart/form-data" >
-    <div class="layui-tab layui-tab-card">
-        {include file="layout/admin_items" /}
-        <div class="layui-tab-content page-tab-content">
-            <div class="layui-tab-item layui-show ">
-                
-                <div class="layui-collapse">
-                    <div class="layui-colla-item">
-                        <h2 class="layui-colla-title">基本设置</h2>
-                        <div class="layui-colla-content layui-show">
-                            <div class="layui-form-item">
-                                <label class="layui-form-label">所属类别</label>
-                                <div class="layui-input-inline">
-                                    <select name="product_type" id="product_type">
-                                        <option value="{$product['product_type']}">{if $product.product_type==1}首页{elseif $product.product_type==2}业务范围{elseif $product.product_type==3}案例展示{elseif $product.product_type==4}解决方案{elseif $product.product_type==5}联系我们{elseif $product.product_type==6}关于我们{elseif $product.product_type==7}合作流程{else}请选择类别{/if}</option>
-                                        <option value="1">首页</option>
-                                        <option value="2">业务范围</option>
-                                        <option value="3">案例展示</option>
-                                        <option value="4">解决方案</option>
-                                        <option value="5">联系我们</option>
-                                        <option value="6">关于我们</option>
-                                        <option value="7">合作流程</option>
-                                    </select>
-                                </div>
-                            </div>
-                            <div class="layui-form-item">
-                                <label class="layui-form-label">标题</label>
-                                <div class="layui-input-inline">
-                                    <input type="text" class="layui-input field-name" name="product_title" id="product_title" value="{$product.product_title|default=''}" lay-verify="product_title" autocomplete="off" placeholder="{$Think.lang.ds_please_enter}标题" required />
-                                </div>
-                            </div>
-                            <div class="layui-form-item">
-                                <label class="layui-form-label">副标题</label>
-                                <div class="layui-input-inline">
-                                    <input type="text" class="layui-input field-name" name="product_ctitle" id="product_ctitle" value="{$product.product_ctitle|default=''}" lay-verify="product_ctitle" autocomplete="off" placeholder="{$Think.lang.ds_please_enter}副标题" required />
-                                </div>
-                            </div>
-
-                            <div class="layui-form-item">
-                                <label class="layui-form-label">关键字</label>
-                                <div class="layui-input-inline">
-                                    <input type="text" class="layui-input field-name" name="product_keywords" id="product_keywords" value="{$product.product_keywords|default=''}" lay-verify="product_keywords" autocomplete="off" placeholder="{$Think.lang.ds_please_enter}关键字" required />
-                                </div>
-                            </div>
-                            <div class="layui-form-item">
-                                <label class="layui-form-label">状态</label>
-                                <div class="layui-input-inline">
-                                    <input type="checkbox" name="product_status" lay-skin="switch" lay-text="{$Think.lang.ds_yes}|{$Think.lang.ds_no}" value="1" {if condition="$product.product_status eq '1'"}checked{/if}>
-                                </div>
-                            </div>
-                            <div class="layui-form-item">
-                                <label class="layui-form-label">是否跳转</label>
-                                <div class="layui-input-inline">
-                                    <input type="checkbox" name="product_isjump" lay-skin="switch" lay-text="{$Think.lang.ds_yes}|{$Think.lang.ds_no}" value="1" {if condition="$product.product_isjump eq '1'"}checked{/if}>
-                                </div>
-                            </div>
-                        </div>
-                    </div>
-                    
-                    <div class="layui-colla-item">
-                        <h2 class="layui-colla-title">详情内容</h2>
-                        <div class="layui-colla-content">
-                            <div class="layui-form-item">
-                                <label class="layui-form-label">{$Think.lang.product_content}</label>
-                                <div class="layui-input-block">
-                                    {:build_editor(['name'=>'product_content','content'=>isset($product.product_content)?$product.product_content:''])}
-                                    <textarea name="product_content" id="product_content" style="min-height:400px;"></textarea>
-                                </div>
-                            </div>
-                            <!-- <button type="button" class="layui-btn" id="upload_productpic"><i class="layui-icon"></i>{$Think.lang.ds_uploading_files}</button> -->
-                            <div class="selected_pic clearfix">
-                                <ul>
-                                    {foreach name="pic_list" id="productpic"}
-                                    <li id="{$productpic.pic_id}">
-                                        <img src="{:get_product_img($productpic['pic_cover'])}"/>
-                                        <i class="delect layui-icon" title="{$Think.lang.ds_insert_editor}" onclick="insert_editor('{:get_product_img($productpic['pic_cover'])}')">&#xe654;</i>
-                                        <i class="insert layui-icon" title="{$Think.lang.ds_delete_picture}" onclick="del_productpic({$productpic.pic_id})">&#xe640;</i>
-                                    </li>
-                                    {/foreach}
-                                </ul>
-                            </div>
-                        </div>
-                    </div>
-                </div>
-                
-                <div class="layui-form-item mt20">
-                    <div class="layui-input-inline">
-                        <input type="submit" class="layui-btn layui-btn-normal" lay-submit value="{:lang('ds_submit')}" />
-                    </div>
-                </div>
-            </div>
-        </div>
-    </div>
-</form>
-<script>
-    layui.use('form', function () {
-        var form = layui.form;
-    });
-    layui.use('element', function () {
-        var element = layui.element;
-    });
-    layui.use('laydate', function(){
-        var laydate = layui.laydate;
-        laydate.render({
-            elem: '#product_addtime'
-        });
-    });
-    /**
-     * 图片异步上传
-     */
-    layui.use('upload', function () {
-        var $ = layui.jquery, upload = layui.upload;
-        //指定允许上传的文件类型
-        upload.render({
-            elem: '#upload_productpic'
-            , url: "{:url('pic/upload',['pic_type_id'=>$Request.param.product_id,'pic_type'=>$product_pic_type.pic_type])}"
-            , accept: 'file' //普通文件
-            , done: function (res) {
-                add_uploadedfile(res);
-//                console.log(res)
-            }
-        });
-    });
-    function add_uploadedfile(file_data)
-    {
-        var newImg = '<li id="' + file_data.file_id + '"><img src="' + file_data.file_url + '"/><i class="delect layui-icon" title="插入编辑器" onclick="insert_editor(\''+file_data.file_url+'\')">&#xe654;</i><i class="insert layui-icon" title="删除图片" onclick="del_productpic(' + file_data.file_id + ')">&#xe640;</i></li>'
-        $('.selected_pic ul').prepend(newImg);
-    }
-
-
-    /**
-     * 插入编辑器
-     */
-    function insert_editor(file_path){
-        ue.execCommand('insertimage', {src:file_path});
-    }
-
-    function del_productpic(file_id)
-    {
-        layer.open({
-            content: '{$Think.lang.ds_confirm_cancel}',
-            yes: function(index, layero){
-                $.getJSON("{:url('pic/del')}",{file_id: + file_id,pic_type:'product'}, function(result){
-                    if(result){
-                        $('#' + file_id).remove();
-                        layer.msg('{$Think.lang.del_succ}');
-                        layer.close(index);
-                        return;
-                    }else{
-                        layer.msg('{$Think.lang.del_fail}');
-                        layer.close(index);
-                        return;
-                    }
-                });
-            }
-        });
-    }
-</script>
-{/block}
-
-

+ 0 - 82
application/user/view/product/index.html

@@ -1,82 +0,0 @@
-{extend name="layout:home" /}
-{block name="container"}
-<div class="layui-tab layui-tab-card">
-    {include file="layout/admin_items" /}
-    <div class="layui-tab-content page-tab-content">
-    <!-- 搜索框开始 -->
-        <div class="search-form">
-        <form class="" method="post">
-            <div class="layui-form-item">
-                <div class="layui-inline">
-                    <input type="text" name="product_keywords"  placeholder="输入关键字" autocomplete="off" class="layui-input">
-                </div>
-                <div class="layui-inline">
-                    <select name="product_type" lay-verify="" class="layui-select layui-unselect layui-form-select">
-                        <option value="">请选择类别</option>
-                        <option value="1">首页</option>
-                        <option value="2">业务范围</option>
-                        <option value="3">案例展示</option>
-                        <option value="4">解决方案</option>
-                        <option value="5">联系我们</option>
-                        <option value="6">关于我们</option>
-                        <option value="7">合作流程</option>
-                    </select>
-                </div>
-                <div class="layui-inline">
-                    <button type="submit" class="layui-btn search-subBtn">搜索</button>
-                </div>
-            </div>
-        </form>
-        </div>
-        <!-- 搜索框结束 -->
-        <table class="layui-table lay-even">
-            <colgroup>
-                <col width="150">
-                <col width="200">
-                <col width="100">
-                <col width="100">
-                <col width="100">
-                <col>
-            </colgroup>
-            <thead>
-                <tr>
-                    <th>{$Think.lang.product_title}</th>
-                    <th>副标题</th>
-                    <th>内容</th>
-                    <th>关键字</th>
-                    <th>创建时间</th>
-                    <th>所属类别</th>
-                    <th>是否跳转</th>
-                    <th>状态</th>
-                    <th>{$Think.lang.ds_operation}</th>
-                </tr>
-            </thead>
-            <tbody>
-            {if $product_list}
-            {volist name="product_list" id="product" key="kk"}
-            <tr>
-                <td>{$product.product_title}</td>
-                <td>{$product.product_ctitle}</td>
-                <td>{$product.product_content}</td>
-                <td>{$product.product_keywords}</td>
-                <td>{$product.product_addtime|date='Y-m-d ',###}</td>
-                <td>{if $product.product_type==1}首页{elseif $product.product_type==2}业务范围{elseif $product.product_type==3}案例展示{elseif $product.product_type==4}解决方案{elseif $product.product_type==5}联系我们{elseif $product.product_type==6}关于我们{else}合作流程{/if}</td>
-                <td>{if $product.product_isjump==1}跳转{else}不跳转{/if}</td>
-                <td>{if $product.product_status==1}使用中{else}未使用{/if}</td>
-                <td>
-                    <a href="{:url('product/edit',['product_id'=>$product.product_id])}" class="layui-btn layui-btn-xs"><i class="layui-icon layui-icon-edit"></i>{$Think.lang.ds_edit}</a>
-                    <a class="layui-btn layui-btn-danger layui-btn-xs" href="javascript:dsLayerConfirm('{:url('product/del',['product_id'=>$product.product_id])}','{$Think.lang.ds_confirm_cancel}')"><i class="layui-icon layui-icon-delete"></i>{$Think.lang.ds_del}</a>
-                </td>
-            </tr>
-            {/volist}
-            {else}
-            <td>无数据</td>
-            {/if}
-        </tbody>
-        </table>
-        {$show_page}
-        
-    </div>
-</div>
-<script type="text/javascript" src="{$Think.ADMIN_SITE_ROOT}/js/jquery.edit.js"></script>
-{/block}

+ 4 - 0
application/user/view/renewal/index.html

@@ -121,6 +121,10 @@
         let name = $("#selectTime").find("option:selected").attr("name");
         $("#layui-layer-content").html(name)
     }
+    function showCurrent() {
+        let type = $("#type").val();
+        window.location.href = myHost + "/User/renewal/index.html?type=" + type;
+    }
     function submit() {
         let url = myHost + "/User/renewal/renewal.html";
         let renewal_id = $("#renewal_id").val();

+ 0 - 85
application/user/view/wlcome/index.html

@@ -1,85 +0,0 @@
-{extend name="layout:home" /}
-{block name="container"}
-<div class="layui-tab-content page-tab-content">
-    <h1>{$Think.lang.wel_version_info}</h1>
-    <table class="layui-table lay-even">
-        <colgroup>
-            <col width="300">
-            <col width="530">
-        </colgroup>
-        <tbody>
-        <tr>
-            <td class="gray_bg">{$Think.lang.wel_version}</td>
-            <td>{$statistics['version']}</td>
-            <td class="gray_bg">{$Think.lang.wel_install_date}</td>
-            <td>{notempty name="statistics['setup_date']"}$statistics['setup_date']{else}{$Think.lang.temporary_installation}{/notempty}</td>
-        </tr>
-        <tr>
-            <td class="gray_bg">{$Think.lang.wel_program_development}</td>
-            <td>{$Think.lang.wel_deshangwangluo}</td>
-            <td class="gray_bg">{$Think.lang.wel_all_right_reserved}</td>
-            <td>{$Think.lang.wel_piracy_must_be_studied}</td>
-        </tr>
-        <tr>
-            <td class="gray_bg">{$Think.lang.wel_aboutus_website}</td>
-            <td><a href="http://www.csdeshang.com" target="_blank">{$Think.lang.aboutus_website}</a></td>
-            <td class="gray_bg">{$Think.lang.wel_aboutus_bbs}</td>
-            <td><a href="http://bbs.csdeshang.com" target="_blank">{$Think.lang.wel_communication_bbs}</a></td>
-        </tr>
-        </tbody>
-    </table>
-
-    <h1>{$Think.lang.wel_sys_info}</h1>
-    <table class="layui-table lay-even">
-        <colgroup>
-            <col width="300">
-            <col width="530">
-        </colgroup>
-        <tbody>
-        <tr>
-            <td class="gray_bg">{$Think.lang.wel_thinkphp_version}</td>
-            <td>{$Think.THINK_VERSION}</td>
-            <td class="gray_bg">{$Think.lang.wel_class_library_file_suffix}</td>
-            <td>{$Think.EXT}</td>
-        </tr>
-        <tr>
-            <td class="gray_bg">{$Think.lang.wel_server_os}</td>
-            <td>{$statistics['os']}</td>
-            <td class="gray_bg">{$Think.lang.wel_server_domain_ip}</td>
-            <td>{$statistics.domain} [ {$statistics.ip} ]</td>
-        </tr>
-        <tr>
-            <td class="gray_bg">WEB {$Think.lang.wel_server}</td>
-            <td>{$statistics['web_server']}</td>
-            <td class="gray_bg">PHP {$Think.lang.wel_version}</td>
-            <td>{$statistics['php_version']}</td>
-        </tr>
-        <tr>
-            <td class="gray_bg">MYSQL {$Think.lang.wel_version}</td>
-            <td>{$statistics['sql_version']}</td>
-            <td class="gray_bg">GD {$Think.lang.wel_version}</td>
-            <td>{$statistics.gdinfo}</td>
-        </tr>
-        <tr>
-            <td class="gray_bg">{$Think.lang.wel_file_uplode_limit}</td>
-            <td>{$statistics.fileupload}</td>
-            <td class="gray_bg">{$Think.lang.wel_max_occupied_memory}</td>
-            <td>{$statistics.memory_limit}</td>
-        </tr>
-        <tr>
-            <td class="gray_bg">{$Think.lang.wel_max_ex_time}</td>
-            <td>{$statistics.max_ex_time}</td>
-            <td class="gray_bg">{$Think.lang.wel_safe_mode}</td>
-            <td>{$statistics.safe_mode}</td>
-        </tr>
-        <tr>
-            <td class="gray_bg">Zlib {$Think.lang.wel_support}</td>
-            <td>{$statistics.zlib}</td>
-            <td class="gray_bg">Curl {$Think.lang.wel_support}</td>
-            <td>{$statistics.curl}</td>
-        </tr>
-        </tbody>
-    </table>
-</div>
-
-{/block}