diff --git a/catch/system/route.php b/catch/system/route.php index 9f09e8a..c3bf4d4 100644 --- a/catch/system/route.php +++ b/catch/system/route.php @@ -45,7 +45,13 @@ $router->group(function () use ($router) { $router->put('modules/', '\catchAdmin\system\controller\Module@disOrEnable'); $router->put('cache/modules', '\catchAdmin\system\controller\Module@cache'); $router->delete('clear/modules', '\catchAdmin\system\controller\Module@clear'); - })->middleware('auth'); +// 获取 table +$router->get('table//', function ($module, $tableClass){ + $table = sprintf('\\catchAdmin\\%s\\tables\\%s', $module, $tableClass); + + return (new $table)->render(request()->param('only')); +}); +