重新初始化

This commit is contained in:
2020-02-17 20:47:06 +08:00
parent 5c320206fb
commit 58d999ed73
4016 changed files with 1271 additions and 302396 deletions

View File

@@ -3,35 +3,32 @@
// | 应用设置
// +----------------------------------------------------------------------
use think\facade\Env;
return [
// 应用地址
'app_host' => Env::get('app.host', ''),
'app_host' => env('app.host', ''),
// 应用的命名空间
'app_namespace' => '',
'app_namespace' => '',
// 是否启用路由
'with_route' => true,
'with_route' => true,
// 是否启用事件
'with_event' => true,
// 自动多应用模式
'auto_multi_app' => false,
// 应用映射(自动多应用模式有效)
'app_map' => [],
// 域名绑定(自动多应用模式有效)
'domain_bind' => [],
// 禁止URL访问的应用列表自动多应用模式有效
'deny_app_list' => [],
'with_event' => true,
// 默认应用
'default_app' => 'index',
'default_app' => 'index',
// 默认时区
'default_timezone' => 'Asia/Shanghai',
// 应用映射(自动多应用模式有效)
'app_map' => [],
// 域名绑定(自动多应用模式有效)
'domain_bind' => [],
// 禁止URL访问的应用列表自动多应用模式有效
'deny_app_list' => [],
// 异常页面的模板文件
'exception_tmpl' => app()->getThinkPath() . 'tpl/think_exception.tpl',
'exception_tmpl' => app()->getThinkPath() . 'tpl/think_exception.tpl',
// 错误显示信息,非调试模式有效
'error_message' => '页面错误!请稍后再试~',
'error_message' => '页面错误!请稍后再试~',
// 显示错误信息
'show_error_msg' => true,
'show_error_msg' => true,
];

20
config/auth.php Normal file
View File

@@ -0,0 +1,20 @@
<?php
// +----------------------------------------------------------------------
// | SentCMS [ WE CAN DO IT JUST THINK IT ]
// +----------------------------------------------------------------------
// | Copyright (c) 2013 http://www.tensent.cn All rights reserved.
// +----------------------------------------------------------------------
// | Author: molong <molong@tensent.cn> <http://www.tensent.cn>
// +----------------------------------------------------------------------
return [
// 权限设置
'auth_config' => [
'auth_on' => true, // 认证开关
'auth_type' => 1, // 认证方式1为实时认证2为登录认证。
'auth_group' => 'auth_group', // 用户组数据表名
'auth_group_access' => 'auth_group_access', // 用户-用户组关系表
'auth_rule' => 'auth_rule', // 权限规则表
'auth_user' => 'admin', // 用户信息表
],
];

View File

@@ -1,5 +1,4 @@
<?php
use think\facade\Env;
// +----------------------------------------------------------------------
// | 缓存设置
@@ -7,7 +6,7 @@ use think\facade\Env;
return [
// 默认缓存驱动
'default' => Env::get('cache.driver', 'file'),
'default' => env('cache.driver', 'file'),
// 缓存连接方式配置
'stores' => [

View File

@@ -1,9 +1,8 @@
<?php
use think\facade\Env;
return [
// 默认使用的数据库连接配置
'default' => Env::get('database.driver', 'mysql'),
'default' => env('database.driver', 'mysql'),
// 自定义时间查询规则
'time_query_rule' => [],
@@ -20,25 +19,24 @@ return [
'connections' => [
'mysql' => [
// 数据库类型
'type' => Env::get('database.type', 'mysql'),
'type' => env('database.type', 'mysql'),
// 服务器地址
'hostname' => Env::get('database.hostname', '127.0.0.1'),
'hostname' => env('database.hostname', '127.0.0.1'),
// 数据库名
'database' => Env::get('database.database', ''),
'database' => env('database.database', ''),
// 用户名
'username' => Env::get('database.username', 'root'),
'username' => env('database.username', 'root'),
// 密码
'password' => Env::get('database.password', ''),
'password' => env('database.password', ''),
// 端口
'hostport' => Env::get('database.hostport', '3306'),
'hostport' => env('database.hostport', '3306'),
// 数据库连接参数
'params' => [],
// 数据库编码默认采用utf8
'charset' => Env::get('database.charset', 'utf8'),
'charset' => env('database.charset', 'utf8'),
// 数据库表前缀
'prefix' => Env::get('database.prefix', ''),
// 数据库调试模式
'debug' => Env::get('database.debug', true),
'prefix' => env('database.prefix', ''),
// 数据库部署方式:0 集中式(单一服务器),1 分布式(主从服务器)
'deploy' => 0,
// 数据库读写是否分离 主从式有效
@@ -51,6 +49,10 @@ return [
'fields_strict' => true,
// 是否需要断线重连
'break_reconnect' => false,
// 监听SQL
'trigger_sql' => env('app_debug', true),
// 开启字段缓存
'fields_cache' => false,
// 字段缓存路径
'schema_cache_path' => app()->getRuntimePath() . 'schema' . DIRECTORY_SEPARATOR,
],

View File

@@ -1,18 +1,22 @@
<?php
use think\facade\Env;
return [
'default' => Env::get('filesystem.driver', 'local'),
// 默认磁盘
'default' => env('filesystem.driver', 'local'),
// 磁盘列表
'disks' => [
'local' => [
'type' => 'local',
'root' => app()->getRuntimePath() . 'storage',
],
'public' => [
// 磁盘类型
'type' => 'local',
// 磁盘路径
'root' => app()->getRootPath() . 'public/storage',
// 磁盘路径对应的外部URL路径
'url' => '/storage',
// 可见性
'visibility' => 'public',
],
// 更多的磁盘配置信息

12
config/jump.php Normal file
View File

@@ -0,0 +1,12 @@
<?php
/**
* Created by PhpStorm.
* User: liliuwei
* Date: 2019/5/23
* Time: 22:50
*/
return[
// 默认跳转页面对应的模板文件
'dispatch_success_tmpl' => app()->getRootPath().'/vendor/liliuwei/thinkphp-jump/src/tpl/dispatch_jump.tpl',
'dispatch_error_tmpl' => app()->getRootPath().'/vendor/liliuwei/thinkphp-jump/src/tpl/dispatch_jump.tpl',
];

View File

@@ -1,17 +0,0 @@
<?php
return [
'secret' => env('JWT_SECRET'),
//Asymmetric key
'public_key' => env('JWT_PUBLIC_KEY'),
'private_key' => env('JWT_PRIVATE_KEY'),
'password' => env('JWT_PASSWORD'),
//JWT time to live
'ttl' => env('JWT_TTL', 60),
//Refresh time to live
'refresh_ttl' => env('JWT_REFRESH_TTL', 20160),
//JWT hashing algorithm
'algo' => env('JWT_ALGO', 'HS256'),
'blacklist_storage' => sent\jwt\provider\storage\Tp6::class,
];

View File

@@ -3,11 +3,9 @@
// | 多语言设置
// +----------------------------------------------------------------------
use think\facade\Env;
return [
// 默认语言
'default_lang' => Env::get('lang.default_lang', 'zh-cn'),
'default_lang' => env('lang.default_lang', 'zh-cn'),
// 允许的语言列表
'allow_lang_list' => [],
// 多语言自动侦测变量名

View File

@@ -1,12 +1,11 @@
<?php
use think\facade\Env;
// +----------------------------------------------------------------------
// | 日志设置
// +----------------------------------------------------------------------
return [
// 默认日志记录通道
'default' => Env::get('log.channel', 'file'),
'default' => env('log.channel', 'file'),
// 日志记录级别
'level' => [],
// 日志类型记录的通道 ['error'=>'email',...]

View File

@@ -1,8 +1,8 @@
<?php
//中间件配置
// 中间件配置
return [
//别名或分组
// 别名或分组
'alias' => [],
//优先级设置,此数组中的中间件会按照数组中的顺序优先执行
// 优先级设置,此数组中的中间件会按照数组中的顺序优先执行
'priority' => [],
];

View File

@@ -18,12 +18,6 @@ return [
'route_rule_merge' => false,
// 路由是否完全匹配
'route_complete_match' => false,
// 是否开启路由缓存
'route_check_cache' => false,
// 路由缓存连接参数
'route_cache_option' => [],
// 路由缓存Key
'route_check_cache_key' => '',
// 访问控制器层名称
'controller_layer' => 'controller',
// 空控制器名

View File

@@ -3,7 +3,7 @@
// | Trace设置 开启调试模式后有效
// +----------------------------------------------------------------------
return [
// 内置Html 支持扩展
// 内置Html和Console两种方式 支持扩展
'type' => 'Html',
// 读取的日志通道名
'channel' => '',

View File

@@ -10,8 +10,6 @@ return [
'auto_rule' => 1,
// 模板目录名
'view_dir_name' => 'view',
// 模板路径
'view_path' => '',
// 模板后缀
'view_suffix' => 'html',
// 模板文件名分隔符