admin.php 13 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401
  1. <?php
  2. return [
  3. /*
  4. |--------------------------------------------------------------------------
  5. | Laravel-admin name
  6. |--------------------------------------------------------------------------
  7. |
  8. | This value is the name of laravel-admin, This setting is displayed on the
  9. | login page.
  10. |
  11. */
  12. 'name' => '用户反馈系统',
  13. /*
  14. |--------------------------------------------------------------------------
  15. | Laravel-admin logo
  16. |--------------------------------------------------------------------------
  17. |
  18. | The logo of all admin pages. You can also set it as an image by using a
  19. | `img` tag, eg '<img src="http://logo-url" alt="Admin logo">'.
  20. |
  21. */
  22. 'logo' => '<b>用户反馈</b> 系统',
  23. /*
  24. |--------------------------------------------------------------------------
  25. | Laravel-admin mini logo
  26. |--------------------------------------------------------------------------
  27. |
  28. | The logo of all admin pages when the sidebar menu is collapsed. You can
  29. | also set it as an image by using a `img` tag, eg
  30. | '<img src="http://logo-url" alt="Admin logo">'.
  31. |
  32. */
  33. 'logo-mini' => '<b>反馈</b>',
  34. /*
  35. |--------------------------------------------------------------------------
  36. | Laravel-admin bootstrap setting
  37. |--------------------------------------------------------------------------
  38. |
  39. | This value is the path of laravel-admin bootstrap file.
  40. |
  41. */
  42. 'bootstrap' => app_path('Admin/bootstrap.php'),
  43. /*
  44. |--------------------------------------------------------------------------
  45. | Laravel-admin route settings
  46. |--------------------------------------------------------------------------
  47. |
  48. | The routing configuration of the admin page, including the path prefix,
  49. | the controller namespace, and the default middleware. If you want to
  50. | access through the root path, just set the prefix to empty string.
  51. |
  52. */
  53. 'route' => [
  54. 'prefix' => env('ADMIN_ROUTE_PREFIX', 'admin'),
  55. 'namespace' => 'App\\Admin\\Controllers',
  56. 'middleware' => ['web', 'admin'],
  57. ],
  58. /*
  59. |--------------------------------------------------------------------------
  60. | Laravel-admin install directory
  61. |--------------------------------------------------------------------------
  62. |
  63. | The installation directory of the controller and routing configuration
  64. | files of the administration page. The default is `app/Admin`, which must
  65. | be set before running `artisan admin::install` to take effect.
  66. |
  67. */
  68. 'directory' => app_path('Admin'),
  69. /*
  70. |--------------------------------------------------------------------------
  71. | Laravel-admin html title
  72. |--------------------------------------------------------------------------
  73. |
  74. | Html title for all pages.
  75. |
  76. */
  77. 'title' => 'Admin',
  78. /*
  79. |--------------------------------------------------------------------------
  80. | Access via `https`
  81. |--------------------------------------------------------------------------
  82. |
  83. | If your page is going to be accessed via https, set it to `true`.
  84. |
  85. */
  86. 'https' => env('ADMIN_HTTPS', false),
  87. /*
  88. |--------------------------------------------------------------------------
  89. | Laravel-admin auth setting
  90. |--------------------------------------------------------------------------
  91. |
  92. | Authentication settings for all admin pages. Include an authentication
  93. | guard and a user provider setting of authentication driver.
  94. |
  95. | You can specify a controller for `login` `logout` and other auth routes.
  96. |
  97. */
  98. 'auth' => [
  99. 'controller' => App\Admin\Controllers\AuthController::class,
  100. 'guard' => 'admin',
  101. 'guards' => [
  102. 'admin' => [
  103. 'driver' => 'session',
  104. 'provider' => 'admin',
  105. ],
  106. ],
  107. 'providers' => [
  108. 'admin' => [
  109. 'driver' => 'eloquent',
  110. 'model' => Encore\Admin\Auth\Database\Administrator::class,
  111. ],
  112. ],
  113. // Add "remember me" to login form
  114. 'remember' => true,
  115. // Redirect to the specified URI when user is not authorized.
  116. 'redirect_to' => 'auth/login',
  117. // The URIs that should be excluded from authorization.
  118. 'excepts' => [
  119. 'auth/login',
  120. 'auth/logout',
  121. '_handle_action_',
  122. ],
  123. ],
  124. /*
  125. |--------------------------------------------------------------------------
  126. | Laravel-admin upload setting
  127. |--------------------------------------------------------------------------
  128. |
  129. | File system configuration for form upload files and images, including
  130. | disk and upload path.
  131. |
  132. */
  133. 'upload' => [
  134. // Disk in `config/filesystem.php`.
  135. 'disk' => 'admin',
  136. // Image and file upload path under the disk above.
  137. 'directory' => [
  138. 'image' => 'images',
  139. 'file' => 'files',
  140. ],
  141. ],
  142. /*
  143. |--------------------------------------------------------------------------
  144. | Laravel-admin database settings
  145. |--------------------------------------------------------------------------
  146. |
  147. | Here are database settings for laravel-admin builtin model & tables.
  148. |
  149. */
  150. 'database' => [
  151. // Database connection for following tables.
  152. 'connection' => '',
  153. // User tables and model.
  154. 'users_table' => 'admin_users',
  155. 'users_model' => Encore\Admin\Auth\Database\Administrator::class,
  156. // Role table and model.
  157. 'roles_table' => 'admin_roles',
  158. 'roles_model' => Encore\Admin\Auth\Database\Role::class,
  159. // Permission table and model.
  160. 'permissions_table' => 'admin_permissions',
  161. 'permissions_model' => Encore\Admin\Auth\Database\Permission::class,
  162. // Menu table and model.
  163. 'menu_table' => 'admin_menu',
  164. 'menu_model' => Encore\Admin\Auth\Database\Menu::class,
  165. // Pivot table for table above.
  166. 'operation_log_table' => 'admin_operation_log',
  167. 'user_permissions_table' => 'admin_user_permissions',
  168. 'role_users_table' => 'admin_role_users',
  169. 'role_permissions_table' => 'admin_role_permissions',
  170. 'role_menu_table' => 'admin_role_menu',
  171. ],
  172. /*
  173. |--------------------------------------------------------------------------
  174. | User operation log setting
  175. |--------------------------------------------------------------------------
  176. |
  177. | By setting this option to open or close operation log in laravel-admin.
  178. |
  179. */
  180. 'operation_log' => [
  181. 'enable' => true,
  182. /*
  183. * Only logging allowed methods in the list
  184. */
  185. 'allowed_methods' => ['GET', 'HEAD', 'POST', 'PUT', 'DELETE', 'CONNECT', 'OPTIONS', 'TRACE', 'PATCH'],
  186. /*
  187. * Routes that will not log to database.
  188. *
  189. * All method to path like: admin/auth/logs
  190. * or specific method to path like: get:admin/auth/logs.
  191. */
  192. 'except' => [
  193. 'admin/auth/logs*',
  194. ],
  195. ],
  196. /*
  197. |--------------------------------------------------------------------------
  198. | Indicates whether to check route permission.
  199. |--------------------------------------------------------------------------
  200. */
  201. 'check_route_permission' => true,
  202. /*
  203. |--------------------------------------------------------------------------
  204. | Indicates whether to check menu roles.
  205. |--------------------------------------------------------------------------
  206. */
  207. 'check_menu_roles' => true,
  208. /*
  209. |--------------------------------------------------------------------------
  210. | User default avatar
  211. |--------------------------------------------------------------------------
  212. |
  213. | Set a default avatar for newly created users.
  214. |
  215. */
  216. 'default_avatar' => '/vendor/laravel-admin/AdminLTE/dist/img/user2-160x160.jpg',
  217. /*
  218. |--------------------------------------------------------------------------
  219. | Admin map field provider
  220. |--------------------------------------------------------------------------
  221. |
  222. | Supported: "tencent", "google", "yandex".
  223. |
  224. */
  225. 'map_provider' => 'google',
  226. /*
  227. |--------------------------------------------------------------------------
  228. | Application Skin
  229. |--------------------------------------------------------------------------
  230. |
  231. | This value is the skin of admin pages.
  232. | @see https://adminlte.io/docs/2.4/layout
  233. |
  234. | Supported:
  235. | "skin-blue", "skin-blue-light", "skin-yellow", "skin-yellow-light",
  236. | "skin-green", "skin-green-light", "skin-purple", "skin-purple-light",
  237. | "skin-red", "skin-red-light", "skin-black", "skin-black-light".
  238. |
  239. */
  240. 'skin' => 'skin-blue-light',
  241. /*
  242. |--------------------------------------------------------------------------
  243. | Application layout
  244. |--------------------------------------------------------------------------
  245. |
  246. | This value is the layout of admin pages.
  247. | @see https://adminlte.io/docs/2.4/layout
  248. |
  249. | Supported: "fixed", "layout-boxed", "layout-top-nav", "sidebar-collapse",
  250. | "sidebar-mini".
  251. |
  252. */
  253. 'layout' => ['sidebar-mini', 'sidebar-collapse'],
  254. /*
  255. |--------------------------------------------------------------------------
  256. | Login page background image
  257. |--------------------------------------------------------------------------
  258. |
  259. | This value is used to set the background image of login page.
  260. |
  261. */
  262. 'login_background_image' => '',
  263. /*
  264. |--------------------------------------------------------------------------
  265. | Show version at footer
  266. |--------------------------------------------------------------------------
  267. |
  268. | Whether to display the version number of laravel-admin at the footer of
  269. | each page
  270. |
  271. */
  272. 'show_version' => true,
  273. /*
  274. |--------------------------------------------------------------------------
  275. | Show environment at footer
  276. |--------------------------------------------------------------------------
  277. |
  278. | Whether to display the environment at the footer of each page
  279. |
  280. */
  281. 'show_environment' => true,
  282. /*
  283. |--------------------------------------------------------------------------
  284. | Menu bind to permission
  285. |--------------------------------------------------------------------------
  286. |
  287. | whether enable menu bind to a permission
  288. */
  289. 'menu_bind_permission' => true,
  290. /*
  291. |--------------------------------------------------------------------------
  292. | Enable default breadcrumb
  293. |--------------------------------------------------------------------------
  294. |
  295. | Whether enable default breadcrumb for every page content.
  296. */
  297. 'enable_default_breadcrumb' => true,
  298. /*
  299. |--------------------------------------------------------------------------
  300. | Enable/Disable assets minify
  301. |--------------------------------------------------------------------------
  302. */
  303. 'minify_assets' => [
  304. // Assets will not be minified.
  305. 'excepts' => [
  306. ],
  307. ],
  308. /*
  309. |--------------------------------------------------------------------------
  310. | Enable/Disable sidebar menu search
  311. |--------------------------------------------------------------------------
  312. */
  313. 'enable_menu_search' => true,
  314. /*
  315. |--------------------------------------------------------------------------
  316. | Alert message that will displayed on top of the page.
  317. |--------------------------------------------------------------------------
  318. */
  319. 'top_alert' => '',
  320. /*
  321. |--------------------------------------------------------------------------
  322. | The global Grid action display class.
  323. |--------------------------------------------------------------------------
  324. */
  325. 'grid_action_class' => \Encore\Admin\Grid\Displayers\DropdownActions::class,
  326. /*
  327. |--------------------------------------------------------------------------
  328. | Extension Directory
  329. |--------------------------------------------------------------------------
  330. |
  331. | When you use command `php artisan admin:extend` to generate extensions,
  332. | the extension files will be generated in this directory.
  333. */
  334. 'extension_dir' => app_path('Admin/Extensions'),
  335. /*
  336. |--------------------------------------------------------------------------
  337. | Settings for extensions.
  338. |--------------------------------------------------------------------------
  339. |
  340. | You can find all available extensions here
  341. | https://github.com/laravel-admin-extensions.
  342. |
  343. */
  344. 'extensions' => [
  345. ],
  346. ];