top-think / think-awesome Goto Github PK
View Code? Open in Web Editor NEWawesome for thinkphp
License: Apache License 2.0
awesome for thinkphp
License: Apache License 2.0
案例推荐,基于thinkphp6.0开发的cms
sentcms
地址:https://gitee.com/sentcms/sentcms
GitHub地址:https://github.com/static7/past.git
基于thinkphp6.0框架,前端采用layui框架.
1.使用仓储(Repository)模式
2.使用trait,提高代码复用、减少复杂性
3.封装使用率高的方法到trait类中
4.命令一键生成仓储模式 类名 php think depot [应用名/]类名
5.模板生成器,生成数据列表页面和表单页面 (高可扩展性和衍生性,开发效率可提升60%)
6.Request类 加入参数名映射 控制器中方法代码有示例 源码在app\Request类中查看
7.组权限控制,用户组权限控制 (展示菜单树节点)
严格遵循官方文档进行开发
传送门: https://demo.calm7.com 帐号密码均为:test001
https://github.com/deatil/laket-admin
laket-admin
是基于 Thinkphp
的PHP通用后台管理系统,升级 Thinkphp 到 v8 版本layui
搭建后台管理界面https://github.com/XY-JX/utils
1.生成二维码
2.xml与数组转换
3.生成范围经纬度
4.经纬度换算距离
5.人民币转大写
6.MurmurHash
7.GoogleAuth
8.对称加密和证书加密
9.延迟队列
10.访问限制
11.redis
12.生成证书
13.验证码
14.其他
异步代码执行
/异步延迟执行
/异步事件订阅
功能top-think/think-queue
提供的常驻监听脚本执行对应的代码,来实现系统的异步化基于thinkphp6的队列服务
在官方的基础上增加的rabbitmq 的支持
增加的rabbitmq
项目地址:https://gitee.com/thans/jwt-auth
介绍:thinkphp 的 jwt (JSON Web Token)身份验证扩展包。支持tp5.1和6.0
原think-image的打开gif文件会报不合法文件,保存png的质量参数和jpg的质量参数意义不统一,保存gif文件异常,不支持ThinkPHP6.0以版本,基于此修复了不支持PHP8的语法,移除了gif文件支持,统一了png和jpg的质量参数的意义,下步准备接入intervention/image和intervention/gif。
Github:github.com/woxiaoyao81/think-image
composer:think-image
https://packagist.org/packages/linphp/generator
根据数据库自动生成增删改查api接口
https://github.com/suframe/think-admin
基于thinkphp6的管理中控台库,类似于laravel-admin,带菜单,权限,配置等,composer安装,
项目链接:https://gitee.com/thans/thinkphp-filesystem-cloud
目前支持:七牛、阿里云、腾讯云
简介:项目主要是作为一个中介,通过引入成熟的第三方扩展包来使tp6的filesystem更完善
项目地址:https://github.com/whereof/think-elasticsearch
介绍:在您的 thinkphp 应用程序中使用官方 PHP ElasticSearch 客户端的简单方法。支持thinkphp6
GIT仓库地址:
aliyun-oss-thinkphp
扩展包安装:
composer require alphasnow/aliyun-oss-thinkphp
Rotate captcha 旋转图片角度验证码, 包含php生成验证图片(gd
或者 imagick
)
支持原生js
, jquery
, vue2
, uniapp
https://github.com/isszz/rotate-captcha
Svg captcha 使用php
生成svg
格式的验证码
https://github.com/isszz/svg-captcha
Thinkphp6 blade
view engine
https://github.com/isszz/think-blade
项目地址:https://github.com/whereof/think-http-logger
介绍:这个包添加了一个中间件,可以将传入的请求记录到默认日志中。 如果在用户请求期间出现任何问题,您仍然可以访问该用户发送的原始请求数据。
composer
composer require phpu/think-captcha
git
https://github.com/liujiawm/think-captcha
只是要一个验证码功能,很简单!
可生成base64码输出,有利于api使用
验证码单独SESSION保存,不相互影响,在创建验证码时给一个key参数就可以
可以单独指定验证后是否清除,可以指定验证成功清除或是只要验证就清除,也可以设置不清除
可定义图片大小
实用而不繁琐,简洁而不简单
推荐一个非常好用的时间日期的类库, 支持composer, 开箱即用.可以填补TP5之后, 官方没有时间助手类的空白
[b]无须下载, 直接使用composer加载即可[/b]
说明文档也非常详细
[url]https://github.com/zjkal/time-helper[/url]
主要有如下几个功能:
详细功能清打开Github地址查看即可
https://github.com/zjkal/time-helper
之前一直用的消息队列,但是每天任务多了以后,任务又特别耗时间,每天的任务都跑不完,然后就用workerman写了一个tp6的composer包,可多进程执行异步任务,windows上是单进程,liunx上是多进程,项目地址在:https://gitee.com/FengXuanJi/tp6-workerman-task.git,简单
如果你还未使用或者正想使用数据库迁移功能,但又不并不想自己写迁移文件的话,这个工具可以很好的帮助实现文件迁移 目前提供了 Laravel5.5+ 和 Thinkphp6+ 的迁移文件的生成。
composer require jaguarjack/migration-generator 1.0
php think migration:generate
E-admin是一个基于TP6。Element Plus开发而成后台系统构建工具,无需关注页面模板javascript,只用php代码即可快速构建出一个功能完善的后台系统。。
码云:https://gitee.com/rocky-git/eadmin
github:https://github.com/rocky-git/E-admin
token权限管理real-token:https://gitee.com/jinan-jimeng-network_0/real-token
https://github.com/hahadu/think-ueditor
基于thinkphp6的ueditor文件上传类,文件上传采用tp6的文件上传方法
专门处理csv文档的扩展 wenhainan/thinkcsv https://github.com/wenhainan/thinkcsv
thinkphp5和thinkphp6均可使用, 自己写的,希望加入到导航里,非常感谢.
lake-admin是一款基于ThinkPHP6和Layui的后台开发框架。
扩展地址
https://github.com/deatil/lake-admin
扩展安装
composer require lake/lake-admin
市面上短信服务商分为两类:
1、模板类
2、内容直接发送类
业务场景:
1、发短信验证码
2、验证短信验证码
3、通知类内容短信
SDK内容服务商类:https://github.com/cinaofdai/think-sms
SDK模板服务商类:https://github.com/cinaofdai/think-sms-temp
理论上能适配市面上所有的短信服务商
技术特点:
1、发送短信使用单列模式
2、发送短信内容使用了适配器设计模式**,思路。
3、短信服务商的适配,使用适配器设计模式**。
内含几个前端UI框架的分页驱动,能收录不(嘻嘻)
不知道用法是不是最佳的,欢迎流年老大指导
地址:https://github.com/big-dream/think-paginator-driver
// 设置服务注入
\think\Paginator::maker(function (...$args) {
// 使用Bootstrap4分页驱动(更多驱动看下面示例)
return $this->app->make(\bigDream\thinkPaginatorDriver\Bootstrap4::class, $args, true);
});
\think\facade\Db::table('users')->paginate();
https://github.com/axguowen/think-sms.git
支持多平台短信配置:目前支持阿里云、百度云、七牛云、腾讯云平台;
可扩展自定义平台驱动;
支持facade门面方式调用;
支持动态指定短信模板;
支持指定多个手机号接收;
支持动态切换平台;
Aliyun、聚合数据短信发送
https://github.com/tongso/notice-message
uniadmin-apidoc是无侵入的Swagger3/OpenApi3.0接口文档查看工具UI。引用即可生效,无需自己配置路由,无需自己部署swagger-ui到public目录。 插件为你做好了一切,基于ThinkPHP6的无侵入OpenApi UI界面,基于swagger-bootstrap-ui制作。
软件架构
基于ThinPHP6的ServiceProvider与Swagger-Bootstrap-UI,适合所有thinkphp6.0项目。
安装教程
composer require-dev zircote/swagger-php
composer require-dev uniadmin/uniadmin-apidoc dev-master
写一个文档
在一个控制器比如app/controller/User.php里写一个标准的接开文档如下
/**
* 用户登录
*
* @OA\POST(
* tags={"核心模块"},
* summary="用户登录",
* description="支持账号密码、手机号、邮箱登录",
* path="/core/user/login",
* @OA\Response(response="200",description="获取成功"),
* @OA\Parameter(
* name="account",in="query",required=true,description="用户名",
* @OA\Schema(type="string")
* ),
* @OA\Parameter(
* name="password",in="query",required=true,description="用户密码",
* @OA\Schema(type="string")
* )
* )
*
* @param \think\Request $request
* @return \think\Response
* @author jry <[email protected]>
*/
public function login(Request $request)
{
}
使用说明
访问 {域名:端口}/doc
项目地址:cathcAdmin
申请资源收录
希望流年看看,给点建议😂
think-repository
是为thinkphp 6.0.*
提供的存储库用于抽象数据层,使我们的应用程序更灵活地进行维护。
基于tp5版本的中间件
GIT仓库地址:
cxx2320/tp5-middleware
您好,劳烦帮忙将仓库地址:https://gitee.com/thans/jwt-auth
更换成:https://github.com/QThans/jwt-auth
谢谢。
连接地址:https://www.eduaskcms.xin/
描述 :基于ThinkPHP5.1、LayUI开发的快速开发系统
https://github.com/hahadu/think-userlogin
thinkphp6的用户登录模块,支持短信登录/注册、邮箱登录/注册,支持JWT鉴权方式和session鉴权
项目地址:https://github.com/whereof/think-queue-connector
介绍:think-queue增加 RabbitMQ 驱动
项目地址:https://github.com/whereof/think-scout
介绍:whereof/think-scout 为模型的全文搜索提供了一个简单的、基于驱动程序的解决方案。支持thinkphp6
ULID - 一种比UUID更好的方案
仓库地址: efarsoft/ulid-php
为什么不选择UUID UUID 目前有 5 个版本:
版本1:在许多环境中是不切实际的,因为它需要访问唯一的,稳定的MAC地址,容易被攻击;
版本2:将版本 1 的时间戳前四位换为 POSIX 的 UID 或 GID,问题同上;
版本3:基于 MD5 哈希算法生成,生成随机分布的ID需要唯一的种子,这可能导致许多数据结构碎片化;
版本4:基于随机数或伪随机数生成,除了随机性外没有提供其他信息;
版本5:通过 SHA-1 哈希算法生成,生成随机分布的ID需要唯一的种子,这可能导致许多数据结构碎片化;
这里面常用的就是 UUID4 了,但是,即使是随机的,但是也是存在冲突的风险。
和 UUID 要么基于随机数,要么基于时间戳不同,ULID 是既基于时间戳又基于随机数,时间戳精确到毫秒,毫秒内有1.21e + 24个随机数,不存在冲突的风险,而且转换成字符串比 UUID 更加友好。
ULID特性:
ulid() # 01ARZ3NDEKTSV4RRFFQ69G5FAV
与UUID的128位兼容性
每毫秒1.21e + 24个唯一ULID
按字典顺序(也就是字母顺序)排序!
规范地编码为26个字符串,而不是UUID的36个字符
使用Crockford的base32获得更好的效率和可读性(每个字符5位)
不区分大小写
没有特殊字符(URL安全)
单调排序顺序(正确检测并处理相同的毫秒)
数据库迁移工具 think-phinx —— https://gitee.com/ajiho/think-phinx
smarty模板引擎 think-smarty —— https://gitee.com/ajiho/think-smarty
项目地址:https://github.com/whereof/think-csv
介绍:轻松地从Eloquent模型生成CSV文件。支持thinkphp6
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.