mirror of
https://gitee.com/fastadminnet/framework.git
synced 2026-07-07 15:12:48 +08:00
增加response_auto_output参数用于控制是否自动调用Response类响应输出
如果设置为false 则由控制器自行输出
This commit is contained in:
@@ -37,6 +37,8 @@ return [
|
|||||||
'lang_cookie_var' => 'think_lang',
|
'lang_cookie_var' => 'think_lang',
|
||||||
// 默认全局过滤方法 用逗号分隔多个
|
// 默认全局过滤方法 用逗号分隔多个
|
||||||
'default_filter' => '',
|
'default_filter' => '',
|
||||||
|
// 自动Response输出
|
||||||
|
'response_auto_output' => true,
|
||||||
|
|
||||||
// +----------------------------------------------------------------------
|
// +----------------------------------------------------------------------
|
||||||
// | 模块设置
|
// | 模块设置
|
||||||
|
|||||||
@@ -103,7 +103,10 @@ class App
|
|||||||
// 监听app_end
|
// 监听app_end
|
||||||
APP_HOOK && Hook::listen('app_end', $data);
|
APP_HOOK && Hook::listen('app_end', $data);
|
||||||
// 输出数据到客户端
|
// 输出数据到客户端
|
||||||
return Response::send($data, Response::type(), Config::get('response_return'));
|
if (Config::get('response_auto_output')) {
|
||||||
|
// 自动响应输出
|
||||||
|
return Response::send($data, Response::type(), Config::get('response_return'));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 执行函数或者闭包方法 支持参数调用
|
// 执行函数或者闭包方法 支持参数调用
|
||||||
|
|||||||
Reference in New Issue
Block a user