leruge/tp6-admin

此包已被 弃用 并不再维护。作者建议使用 leruge/admin 包。

适用于thinkphp6的后台扩展

安装: 185

依赖者: 0

建议者: 0

安全: 0

星标: 0

关注者: 1

分支: 0

开放问题: 0

语言:JavaScript

dev-master 2021-07-01 06:19 UTC

This package is auto-updated.

Last update: 2021-10-25 11:33:45 UTC


README

功能

  1. 系统设置
  2. 管理员管理
  3. 权限
  4. 迁移和种子
  5. 错误页面、下载页面、首页、隐私协议
  6. 下载页面 域名+down.html
  7. 首页 域名
  8. 隐私协议地址 域名+agreement.html

使用说明

  1. 安装后台扩展 composer require leruge/tp6-admin=dev-master
  2. 安装封装函数 composer require leruge/tp6-helper=dev-main
  3. 生成后台所需文件 php think leruge:admin
  4. 执行完成后,在config目录会生成extra.php和admin.php配置文件,自行配置即可
  5. 开启开发模式env,配置app_url全局url
  6. 删除static下的.gitignore文件
  7. 配置数据库,编码设置utf8mb4
  8. 执行迁移 php think migrate:run
  9. 种子填充(不允许重复执行) php think seed:run
  10. 后台登录状态使用session,所有需要开启session中间件,用的name是adminId
  11. 配置磁盘filesystem.php如下
'customer' => [
    'type' => 'local',
    'root' => app()->getRootPath() . 'public' . DIRECTORY_SEPARATOR . 'static' . DIRECTORY_SEPARATOR . 'uploads',
]
  1. 在app.php配置文件修改配置 'exception_tmpl' => env('app_debug') ? app()->getThinkPath() . 'tpl/think_exception.tpl' : app()->getRootPath() . 'view' . DIRECTORY_SEPARATOR . 'error' . DIRECTORY_SEPARATOR . 'error.html',
  2. 在公共函数中实现send_code($phone, $code),返回结果1是发送成功
  3. 下载页面需要配置urlscheme,在index控制器的down方法中