admin.php 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370
  1. <?php
  2. return [
  3. /*
  4. |--------------------------------------------------------------------------
  5. | The name of admin application
  6. |--------------------------------------------------------------------------
  7. |
  8. | This value is the name of admin application, This setting is displayed on the
  9. | login page.
  10. |
  11. */
  12. 'name' => 'Laravel-admin',
  13. /*
  14. |--------------------------------------------------------------------------
  15. | Logo setting of admin application
  16. |--------------------------------------------------------------------------
  17. |
  18. */
  19. 'logo' => [
  20. 'image' => '/vendor/laravel-admin/AdminLTE/img/AdminLTELogo.png',
  21. 'text' => '<span class="font-weight-bolder">Laravel-admin</span>',
  22. ],
  23. /*
  24. |--------------------------------------------------------------------------
  25. | Laravel-admin bootstrap setting
  26. |--------------------------------------------------------------------------
  27. |
  28. | This value is the path of laravel-admin bootstrap file.
  29. |
  30. */
  31. 'bootstrap' => app_path('Admin/bootstrap.php'),
  32. /*
  33. |--------------------------------------------------------------------------
  34. | Laravel-admin route settings
  35. |--------------------------------------------------------------------------
  36. |
  37. | The routing configuration of the admin page, including the path prefix,
  38. | the controller namespace, and the default middleware. If you want to
  39. | access through the root path, just set the prefix to empty string.
  40. |
  41. */
  42. 'route' => [
  43. 'prefix' => env('ADMIN_ROUTE_PREFIX', 'admin'),
  44. 'namespace' => 'App\\Admin\\Controllers',
  45. 'middleware' => ['web', 'admin'],
  46. ],
  47. /*
  48. |--------------------------------------------------------------------------
  49. | Laravel-admin install directory
  50. |--------------------------------------------------------------------------
  51. |
  52. | The installation directory of the controller and routing configuration
  53. | files of the administration page. The default is `app/Admin`, which must
  54. | be set before running `artisan admin::install` to take effect.
  55. |
  56. */
  57. 'directory' => app_path('Admin'),
  58. /*
  59. |--------------------------------------------------------------------------
  60. | Laravel-admin html title
  61. |--------------------------------------------------------------------------
  62. |
  63. | Html title for all pages.
  64. |
  65. */
  66. 'title' => 'Admin',
  67. /*
  68. |--------------------------------------------------------------------------
  69. | Access via `https`
  70. |--------------------------------------------------------------------------
  71. |
  72. | If your page is going to be accessed via https, set it to `true`.
  73. |
  74. */
  75. 'https' => env('ADMIN_HTTPS', false),
  76. /*
  77. |--------------------------------------------------------------------------
  78. | Laravel-admin auth setting
  79. |--------------------------------------------------------------------------
  80. |
  81. | Authentication settings for all admin pages. Include an authentication
  82. | guard and a user provider setting of authentication driver.
  83. |
  84. | You can specify a controller for `login` `logout` and other auth routes.
  85. |
  86. */
  87. 'auth' => [
  88. 'controller' => App\Admin\Controllers\AuthController::class,
  89. 'guard' => 'admin',
  90. 'guards' => [
  91. 'admin' => [
  92. 'driver' => 'session',
  93. 'provider' => 'admin',
  94. ],
  95. ],
  96. 'providers' => [
  97. 'admin' => [
  98. 'driver' => 'eloquent',
  99. 'model' => Encore\Admin\Models\Administrator::class,
  100. ],
  101. ],
  102. // Add "remember me" to login form
  103. 'remember' => true,
  104. // Redirect to the specified URI when user is not authorized.
  105. 'redirect_to' => 'auth/login',
  106. // The URIs that should be excluded from authorization.
  107. 'excepts' => [
  108. 'auth/login',
  109. 'auth/logout',
  110. '_handle_form_',
  111. '_handle_action_',
  112. '_handle_selectable_',
  113. '_handle_renderable_',
  114. ],
  115. ],
  116. /*
  117. |--------------------------------------------------------------------------
  118. | Laravel-admin upload setting
  119. |--------------------------------------------------------------------------
  120. |
  121. | File system configuration for form upload files and images, including
  122. | disk and upload path.
  123. |
  124. */
  125. 'upload' => [
  126. // Disk in `config/filesystem.php`.
  127. 'disk' => 'admin',
  128. // Image and file upload path under the disk above.
  129. 'directory' => [
  130. 'image' => 'images',
  131. 'file' => 'files',
  132. ],
  133. ],
  134. /*
  135. |--------------------------------------------------------------------------
  136. | Laravel-admin database settings
  137. |--------------------------------------------------------------------------
  138. |
  139. | Here are database settings for laravel-admin builtin model & tables.
  140. |
  141. */
  142. 'database' => [
  143. // Database connection for following tables.
  144. 'connection' => '',
  145. // User tables and model.
  146. 'users_table' => 'admin_users',
  147. 'users_model' => Encore\Admin\Models\Administrator::class,
  148. // Menu table and model.
  149. 'menu_table' => 'admin_menu',
  150. 'menu_model' => Encore\Admin\Models\Menu::class,
  151. ],
  152. /*
  153. |--------------------------------------------------------------------------
  154. | User default avatar
  155. |--------------------------------------------------------------------------
  156. |
  157. | Set a default avatar for newly created users.
  158. |
  159. */
  160. 'default_avatar' => '/vendor/laravel-admin/AdminLTE/img/user2-160x160.jpg',
  161. /*
  162. |--------------------------------------------------------------------------
  163. | Application theme
  164. |--------------------------------------------------------------------------
  165. |
  166. | @see https://adminlte.io/docs/3.0/layout.html
  167. |
  168. */
  169. 'theme' => [
  170. /*
  171. |--------------------------------------------------------------------------
  172. | Available layout options.
  173. |--------------------------------------------------------------------------
  174. | Fixed Sidebar: use the class `.layout-fixed` to get a fixed sidebar.
  175. | Fixed Navbar: use the class `.layout-navbar-fixed` to get a fixed navbar.
  176. | Fixed Footer: use the class `.layout-footer-fixed` to get a fixed footer.
  177. | Collapsed Sidebar: use the class `.sidebar-collapse` to have a collapsed sidebar upon loading.
  178. | Boxed Layout: use the class `.layout-boxed` to get a boxed layout that stretches only to 1250px.
  179. | Top Navigation: use the class `.layout-top-nav` to remove the sidebar and have your links at the top navbar.
  180. |
  181. */
  182. 'layout' => ['sidebar-mini', 'sidebar-collapse', 'text-sm'],
  183. /*
  184. |--------------------------------------------------------------------------
  185. | Default color for all links.
  186. |--------------------------------------------------------------------------
  187. |
  188. | navbar-light or navbar-dark for content color
  189. |
  190. | navbar-$color for backgroud color
  191. |
  192. | Available $color options:
  193. | primary secondary secondary info warning danger black gray-dark gray
  194. | light indigo navy purple fuchsia pink maroon orange lime teal olive
  195. |
  196. */
  197. 'navbar' => 'navbar-light navbar-white',
  198. /*
  199. |--------------------------------------------------------------------------
  200. | Default color for all links.
  201. |--------------------------------------------------------------------------
  202. |
  203. | Available options:
  204. | primary secondary secondary info warning danger black gray-dark gray
  205. | light indigo navy purple fuchsia pink maroon orange lime teal olive
  206. |
  207. */
  208. 'accent' => 'info',
  209. /*
  210. |--------------------------------------------------------------------------
  211. | Default color for card form and buttons.
  212. |--------------------------------------------------------------------------
  213. |
  214. | light-$color or dark-$color
  215. |
  216. | Available $color options:
  217. | primary secondary secondary info warning danger black gray-dark gray
  218. | light indigo navy purple fuchsia pink maroon orange lime teal olive
  219. |
  220. */
  221. 'sidebar' => 'light-info',
  222. /*
  223. |--------------------------------------------------------------------------
  224. | Default color for card, form and buttons.
  225. |--------------------------------------------------------------------------
  226. |
  227. | Available options:
  228. | primary secondary secondary info warning danger
  229. */
  230. 'color' => 'info',
  231. /*
  232. |--------------------------------------------------------------------------
  233. | Logo backgroud color.
  234. |--------------------------------------------------------------------------
  235. |
  236. | Available color options:
  237. | primary secondary secondary info warning danger black gray-dark gray
  238. | light indigo navy purple fuchsia pink maroon orange lime teal olive
  239. |
  240. */
  241. 'logo' => 'light',
  242. ],
  243. /*
  244. |--------------------------------------------------------------------------
  245. | Login page background image
  246. |--------------------------------------------------------------------------
  247. |
  248. | This value is used to set the background image of login page.
  249. |
  250. */
  251. 'login_background_image' => '',
  252. /*
  253. |--------------------------------------------------------------------------
  254. | Show version at footer
  255. |--------------------------------------------------------------------------
  256. |
  257. | Whether to display the version number of laravel-admin at the footer of
  258. | each page
  259. |
  260. */
  261. 'show_version' => true,
  262. /*
  263. |--------------------------------------------------------------------------
  264. | Show environment at footer
  265. |--------------------------------------------------------------------------
  266. |
  267. | Whether to display the environment at the footer of each page
  268. |
  269. */
  270. 'show_environment' => true,
  271. /*
  272. |--------------------------------------------------------------------------
  273. | Enable default breadcrumb
  274. |--------------------------------------------------------------------------
  275. |
  276. | Whether enable default breadcrumb for every page content.
  277. */
  278. 'enable_default_breadcrumb' => true,
  279. /*
  280. |--------------------------------------------------------------------------
  281. | Enable/Disable assets minify
  282. |--------------------------------------------------------------------------
  283. */
  284. 'minify_assets' => [
  285. // Assets will not be minified.
  286. 'excepts' => [
  287. ],
  288. ],
  289. /*
  290. |--------------------------------------------------------------------------
  291. | Alert message that will displayed on top of the page.
  292. |--------------------------------------------------------------------------
  293. */
  294. 'top_alert' => '',
  295. /*
  296. |--------------------------------------------------------------------------
  297. | The global Table action display class.
  298. |--------------------------------------------------------------------------
  299. */
  300. 'table_action_class' => \Encore\Admin\Table\Displayers\DropdownActions::class,
  301. /*
  302. |--------------------------------------------------------------------------
  303. | Extension Directory
  304. |--------------------------------------------------------------------------
  305. |
  306. | When you use command `php artisan admin:extend` to generate extensions,
  307. | the extension files will be generated in this directory.
  308. */
  309. 'extension_dir' => app_path('Admin/Extensions'),
  310. /*
  311. |--------------------------------------------------------------------------
  312. | Settings for extensions.
  313. |--------------------------------------------------------------------------
  314. |
  315. | You can find all available extensions here
  316. | https://github.com/laravel-admin-extensions.
  317. |
  318. */
  319. 'extensions' => [
  320. ],
  321. ];