leruge/tp6-admin

This package is abandoned and no longer maintained. The author suggests using the leruge/admin package instead.

适用于thinkphp6的后台扩展

Installs: 169

Dependents: 0

Suggesters: 0

Security: 0

Stars: 0

Watchers: 1

Forks: 0

Open Issues: 0

Language: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方法中