tenancy.php 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393
  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 route settings
  37. |--------------------------------------------------------------------------
  38. |
  39. | The routing configuration of the admin page, including the path prefix,
  40. | the controller namespace, and the default middleware. If you want to
  41. | access through the root path, just set the prefix to empty string.
  42. |
  43. */
  44. 'route' => [
  45. 'prefix' => 'cdms',
  46. 'namespace' => 'App\\Community\\Controllers',
  47. 'middleware' => ['web', 'admin','multi-session:path,/cdms'],
  48. ],
  49. /*
  50. |--------------------------------------------------------------------------
  51. | Laravel-admin install directory
  52. |--------------------------------------------------------------------------
  53. |
  54. | The installation directory of the controller and routing configuration
  55. | files of the administration page. The default is `app/Admin`, which must
  56. | be set before running `artisan admin::install` to take effect.
  57. |
  58. */
  59. 'directory' => app_path('Community'),
  60. /*
  61. |--------------------------------------------------------------------------
  62. | Laravel-admin html title
  63. |--------------------------------------------------------------------------
  64. |
  65. | Html title for all pages.
  66. |
  67. */
  68. 'title' => '超级妈力',
  69. /*
  70. |--------------------------------------------------------------------------
  71. | Access via `https`
  72. |--------------------------------------------------------------------------
  73. |
  74. | If your page is going to be accessed via https, set it to `true`.
  75. |
  76. */
  77. /*
  78. |--------------------------------------------------------------------------
  79. | Laravel-admin auth setting
  80. |--------------------------------------------------------------------------
  81. |
  82. | Authentication settings for all admin pages. Include an authentication
  83. | guard and a user provider setting of authentication driver.
  84. |
  85. | You can specify a controller for `login` `logout` and other auth routes.
  86. |
  87. */
  88. 'auth' => [
  89. 'controller' => App\Community\Controllers\AuthController::class,
  90. 'guards' => [
  91. 'admin' => [
  92. 'driver' => 'session',
  93. 'provider' => 'admin',
  94. ],
  95. ],
  96. 'providers' => [
  97. 'admin' => [
  98. 'driver' => 'eloquent',
  99. 'model' => Encore\Admin\Auth\Database\Administrator::class,
  100. ],
  101. ],
  102. ],
  103. /*
  104. |--------------------------------------------------------------------------
  105. | Laravel-admin upload setting
  106. |--------------------------------------------------------------------------
  107. |
  108. | File system configuration for form upload files and images, including
  109. | disk and upload path.
  110. |
  111. */
  112. 'upload' => [
  113. // Disk in `config/filesystem.php`.
  114. 'disk' => 'admin',
  115. // Image and file upload path under the disk above.
  116. 'directory' => [
  117. 'image' => 'images',
  118. 'file' => 'files',
  119. ],
  120. ],
  121. /*
  122. |--------------------------------------------------------------------------
  123. | Laravel-admin database settings
  124. |--------------------------------------------------------------------------
  125. |
  126. | Here are database settings for laravel-admin builtin model & tables.
  127. |
  128. */
  129. 'database' => [
  130. // Database connection for following tables.
  131. 'connection' => '',
  132. // User tables and model.
  133. 'users_table' => 'cdms_users',
  134. 'users_model' =>\App\Models\CdmsUsers::class,
  135. // Role table and model.
  136. 'roles_table' => 'cdms_roles',
  137. 'roles_model' => \App\Models\CdmsRoles::class,
  138. // Permission table and model.
  139. 'permissions_table' => 'cdms_permissions',
  140. 'permissions_model' => \App\Models\CdmsPermissions::class,
  141. // Menu table and model.
  142. 'menu_table' => 'cdms_menu',
  143. 'menu_model' => \App\Models\CdmsMenus::class,
  144. // Pivot table for table above.
  145. 'operation_log_table' => 'cdms_operation_log',
  146. 'user_permissions_table' => 'cdms_user_permissions',
  147. 'role_users_table' => 'cdms_role_users',
  148. 'role_permissions_table' => 'cdms__role_permissions',
  149. 'role_menu_table' => 'cdms_role_menu',
  150. ],
  151. /*
  152. |--------------------------------------------------------------------------
  153. | User operation log setting
  154. |--------------------------------------------------------------------------
  155. |
  156. | By setting this option to open or close operation log in laravel-admin.
  157. |
  158. */
  159. 'operation_log' => [
  160. 'enable' => true,
  161. /*
  162. * Only logging allowed methods in the list
  163. */
  164. 'allowed_methods' => ['GET', 'HEAD', 'POST', 'PUT', 'DELETE', 'CONNECT', 'OPTIONS', 'TRACE', 'PATCH'],
  165. /*
  166. * Routes that will not log to database.
  167. *
  168. * All method to path like: admin/auth/logs
  169. * or specific method to path like: get:admin/auth/logs.
  170. */
  171. 'except' => [
  172. 'admin/auth/logs*',
  173. ],
  174. ],
  175. /*
  176. |--------------------------------------------------------------------------
  177. | Admin map field provider
  178. |--------------------------------------------------------------------------
  179. |
  180. | Supported: "tencent", "google", "yandex".
  181. |
  182. */
  183. 'map_provider' => 'google',
  184. /*
  185. |--------------------------------------------------------------------------
  186. | Application Skin
  187. |--------------------------------------------------------------------------
  188. |
  189. | This value is the skin of admin pages.
  190. | @see https://adminlte.io/docs/2.4/layout
  191. |
  192. | Supported:
  193. | "skin-blue", "skin-blue-light", "skin-yellow", "skin-yellow-light",
  194. | "skin-green", "skin-green-light", "skin-purple", "skin-purple-light",
  195. | "skin-red", "skin-red-light", "skin-black", "skin-black-light".
  196. |
  197. */
  198. 'skin' => 'skin-blue-light',
  199. /*
  200. |--------------------------------------------------------------------------
  201. | Application layout
  202. |--------------------------------------------------------------------------
  203. |
  204. | This value is the layout of admin pages.
  205. | @see https://adminlte.io/docs/2.4/layout
  206. |
  207. | Supported: "fixed", "layout-boxed", "layout-top-nav", "sidebar-collapse",
  208. | "sidebar-mini".
  209. |
  210. */
  211. 'layout' => ['sidebar-mini'],
  212. /*
  213. |--------------------------------------------------------------------------
  214. | Login page background image
  215. |--------------------------------------------------------------------------
  216. |
  217. | This value is used to set the background image of login page.
  218. |
  219. */
  220. 'login_background_image' => '',
  221. /*
  222. |--------------------------------------------------------------------------
  223. | Show version at footer
  224. |--------------------------------------------------------------------------
  225. |
  226. | Whether to display the version number of laravel-admim at the footer of
  227. | each page
  228. |
  229. */
  230. 'show_version' => true,
  231. /*
  232. |--------------------------------------------------------------------------
  233. | Show environment at footer
  234. |--------------------------------------------------------------------------
  235. |
  236. | Whether to display the environment at the footer of each page
  237. |
  238. */
  239. 'show_environment' => true,
  240. /*
  241. |--------------------------------------------------------------------------
  242. | Menu bind to permissionsymlink
  243. |--------------------------------------------------------------------------
  244. |
  245. | whether enable menu bind to a permission
  246. */
  247. 'menu_bind_permission' => true,
  248. /*
  249. |--------------------------------------------------------------------------
  250. | Enable default breadcrumb
  251. |--------------------------------------------------------------------------
  252. |
  253. | Whether enable default breadcrumb for every page content.
  254. */
  255. 'enable_default_breadcrumb' => true,
  256. /*
  257. |--------------------------------------------------------------------------
  258. | Extension Directory
  259. |--------------------------------------------------------------------------
  260. |
  261. | When you use command `php artisan admin:extend` to generate extensions,
  262. | the extension files will be generated in this directory.
  263. */
  264. 'extension_dir' => app_path('Community/Extensions'),
  265. /*
  266. |--------------------------------------------------------------------------
  267. | Settings for extensions.
  268. |--------------------------------------------------------------------------
  269. |
  270. | You can find all available extensions here
  271. | https://github.com/laravel-admin-extensions.
  272. |
  273. */
  274. 'extensions' => [
  275. 'latlong' => [
  276. // Whether to enable this extension, defaults to true
  277. 'enable' => true,
  278. // Specify the default provider
  279. 'default' => 'tencent',
  280. // According to the selected provider above, fill in the corresponding api_key
  281. 'providers' => [
  282. 'google' => [
  283. 'api_key' => '',
  284. ],
  285. 'yadex' => [
  286. 'api_key' => '',
  287. ],
  288. 'baidu' => [
  289. 'api_key' => 'xck5u2lga9n1bZkiaXIHtMufWXQnVhdx',
  290. ],
  291. 'tencent' => [
  292. 'api_key' => 'KCFBZ-UOC3I-CAKGB-5FHGL-4G46Z-XJBC4',
  293. ],
  294. 'amap' => [
  295. 'api_key' => '3693fe745aea0df8852739dac08a22fb',
  296. ],
  297. ]
  298. ],
  299. 'wang-editor2' => [
  300. // 如果要关掉这个扩展,设置为false
  301. 'enable' => true,
  302. // 编辑器的配置
  303. 'config' => [
  304. 'uploadImgFileName' => 'up_image', //这个应该wangEditor的上传方法名字,不要乱改
  305. 'uploadImgUrl' => '/cdms/img_upload', //注意这里是上传的路由地址
  306. 'menus' => [
  307. 'source',
  308. '|',
  309. 'bold',
  310. 'underline',
  311. 'italic',
  312. 'strikethrough',
  313. 'eraser',
  314. 'forecolor',
  315. 'bgcolor',
  316. '|',
  317. 'quote',
  318. 'fontfamily',
  319. 'fontsize',
  320. 'head',
  321. 'unorderlist',
  322. 'orderlist',
  323. 'alignleft',
  324. 'aligncenter',
  325. 'alignright',
  326. '|',
  327. 'link',
  328. 'unlink',
  329. 'table',
  330. '|',
  331. 'img',
  332. 'video',
  333. 'insertcode',
  334. '|',
  335. 'undo',
  336. 'redo',
  337. 'fullscreen'
  338. ],
  339. ]
  340. ]
  341. ],
  342. // 使用`下拉菜单`形式
  343. 'grid_action_class' => \Encore\Admin\Grid\Displayers\DropdownActions::class,
  344. ];