route.php 3.3 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768
  1. <?php
  2. $router->group(function () use ($router) {
  3. // 登录日志
  4. $router->get('log/login', '\catchAdmin\system\controller\LoginLog@list');
  5. $router->delete('log/login/<id>', '\catchAdmin\system\controller\LoginLog@empty');
  6. // 操作日志
  7. $router->get('log/operate', '\catchAdmin\system\controller\OperateLog@list');
  8. // $router->delete('empty/log/operate', '\catchAdmin\system\controller\OperateLog@empty');
  9. $router->delete('log/operate/<id>', '\catchAdmin\system\controller\OperateLog@delete');
  10. // 数据字典
  11. $router->get('tables', '\catchAdmin\system\controller\DataDictionary@tables');
  12. $router->get('table/view/<table>', '\catchAdmin\system\controller\DataDictionary@view');
  13. $router->post('table/optimize', '\catchAdmin\system\controller\DataDictionary@optimize');
  14. $router->post('table/backup', '\catchAdmin\system\controller\DataDictionary@backup');
  15. //下发设备
  16. $router->resource('lssue', '\catchAdmin\system\controller\Lssue');
  17. // 附件
  18. $router->resource('attachments', '\catchAdmin\system\controller\Attachments');
  19. // 配置
  20. $router->get('config/parent', '\catchAdmin\system\controller\Config@parent');
  21. $router->resource('config', '\catchAdmin\system\controller\Config');
  22. // 代码生成
  23. $router->post('generate', '\catchAdmin\system\controller\Generate@save');
  24. $router->post('generate/preview', '\catchAdmin\system\controller\Generate@preview'); // 预览
  25. $router->post('generate/create/module', '\catchAdmin\system\controller\Generate@createModule'); // 创建模块
  26. // 敏感词
  27. $router->resource('sensitive/word', '\catchAdmin\system\controller\SensitiveWord');
  28. //developer路由
  29. $router->resource('developer', '\catchAdmin\system\controller\Developer')->middleware('auth');
  30. // 开发者认证
  31. $router->post('developer/authenticate', '\catchAdmin\system\controller\Developer@authenticate');
  32. // 模块管理
  33. $router->get('modules', '\catchAdmin\system\controller\Module@index');
  34. $router->put('modules/<module>', '\catchAdmin\system\controller\Module@disOrEnable');
  35. $router->put('cache/modules', '\catchAdmin\system\controller\Module@cache');
  36. $router->delete('clear/modules', '\catchAdmin\system\controller\Module@clear');
  37. })->middleware('auth');
  38. // 上传
  39. $router->group('upload', function () use ($router) {
  40. $router->post('image', '\catchAdmin\system\controller\Upload@image');
  41. $router->post('file', '\catchAdmin\system\controller\Upload@file');
  42. $router->post('file_v2', '\catchAdmin\system\controller\Upload@file_v2');
  43. $router->post('unlinkFile', '\catchAdmin\system\controller\Upload@unlinkFile');
  44. $router->post('file_excel', '\catchAdmin\system\controller\Upload@file_excel');
  45. $router->get('osspolicy', '\catchAdmin\system\controller\Upload@getAliOssPolicy');
  46. $router->post('osscallback', '\catchAdmin\system\controller\Upload@aliOssCallback');
  47. });
  48. // sysDictType路由
  49. $router->group('sysDictType', function () use ($router) {
  50. $router->resource('/', '\catchAdmin\system\controller\SysDictType');
  51. });
  52. // sysDictData路由
  53. $router->group('sysDictData', function () use ($router) {
  54. $router->resource('/', '\catchAdmin\system\controller\SysDictData');
  55. $router->post('getOptions', '\catchAdmin\system\controller\SysDictData@getOptionsByCode');
  56. // lssue路由
  57. });