mirror of
https://gitee.com/zoujingli/ThinkAdmin.git
synced 2025-04-06 03:58:04 +08:00
Update Plugs.php
This commit is contained in:
parent
6cbb687862
commit
294c8b82a6
@ -47,13 +47,10 @@ class Plugs extends Controller
|
|||||||
*/
|
*/
|
||||||
public function script(): \think\Response
|
public function script(): \think\Response
|
||||||
{
|
{
|
||||||
$taDebug = $this->app->isDebug() ? 'true' : 'false';
|
return response(join("\r\n", [
|
||||||
$taAdmin = sysuri('admin/index/index', [], false);
|
sprintf("window.taDebug = %s;", $this->app->isDebug() ? 'true' : 'false'),
|
||||||
$taEditor = sysconf('base.editor') ?: 'ckeditor4';
|
sprintf("window.taAdmin = '%s';", sysuri('admin/index/index', [], false)),
|
||||||
return response(join("\n", [
|
sprintf("window.taEditor = '%s';", sysconf('base.editor') ?: 'ckeditor4'),
|
||||||
"window.taDebug = {$taDebug};",
|
|
||||||
"window.taAdmin = '{$taAdmin}';",
|
|
||||||
"window.taEditor = '{$taEditor}';",
|
|
||||||
]))->contentType('application/x-javascript');
|
]))->contentType('application/x-javascript');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user