PHPackages                             simplestart/start-library - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Utility &amp; Helpers](/categories/utility)
4. /
5. simplestart/start-library

ActiveLibrary[Utility &amp; Helpers](/categories/utility)

simplestart/start-library
=========================

Simplestart Library For Thinkphp V6.0

v1.1.9(4y ago)2249Apache-2.0PHP

Since Sep 7Pushed 4y ago1 watchersCompare

[ Source](https://github.com/Simplestart-cn/start-library)[ Packagist](https://packagist.org/packages/simplestart/start-library)[ RSS](/packages/simplestart-start-library/feed)WikiDiscussions master Synced 3d ago

READMEChangelog (10)Dependencies (1)Versions (20)Used By (0)

Library for ThinkPHP 6.0
========================

[](#library-for-thinkphp-60)

start-library 是针对 ThinkPHP 6.0 版本封装的一套多应用工具类库，方便快速构建 WEB 应用。

包含组件
----

[](#包含组件)

- 通用模型 （快速信息查询，分页查询，列表查询，数据安全删除处理：is\_deleted 字段存在则自动软删除)
- 通用服务 (模型自动关联，快速信息查询，分页查询，列表查询，数据更新)
- 通用控制器 (快速输入验证，自动化CSRF安全验证)
- 通用文件存储 (本地存储 + 阿里云OSS存储 + 腾讯云COS存储 + 七牛云存储)
- 通用网络请求 （支持 get 及 post，可配置请求证书等）
- UTF8加密算法支持（安全URL参数传参数）
- 接口CORS跨域默认支持（输出 JSON 标准化）

代码仓库
----

[](#代码仓库)

start-library 为 Apache 协议开源项目，安装使用或二次开发不受约束，欢迎 fork 项目。 部分代码来自互联网，若有异议可以联系作者进行删除。

- Github仓库地址：

使用说明
----

[](#使用说明)

- start-library 需要 Composer 支持
- 安装命令 ` composer require simplestart/start-library 1.0.0`
- 案例代码： 控制器需要继承 `start\Controller`，然后`$this`就可能使用全部功能

```
// 定义 MyController 控制器
class MyController extend start\Controller {
	// 快速验证,参数(验证规则：array(), 请求方法：'post./get.', 严格模式：true/fasle)
	// 开启严格模式后只会接收经过规则验证的参数
    $input = $this->formValidate([
    	'id.require'    => 'ID不能为空',
        'title.require' => '名字不能为空'
    ]);
}
```

#### 文件存储组件（ cos 、 oss 及 qiniu 需要配置参数,无配置参数则执行本地存储）

[](#文件存储组件-cos--oss-及-qiniu-需要配置参数无配置参数则执行本地存储)

```
// 实例化存储驱动()
$config = [
	'engine' => 'aliyun',
	'domain' => '',
	'bucket' => '',
	'access_key_id' => '',
	'access_key_secret' => ''
];
$StorageDriver = new \start\Storage($config);
// 设置上传文件的信息
$StorageDriver->setUploadFile('iFile');
// 上传图片
if (!$StorageDriver->upload()) {
    return json(['code' => 0, 'msg' => '图片上传失败' . $StorageDriver->getError()]);
}

// 图片上传路径
$fileName = $StorageDriver->getFileName();
// 图片信息
$fileInfo = $StorageDriver->getFileInfo();
// 添加文件库记录
// some code ....
// 图片上传成功
return json(['code' => 1, 'msg' => '图片上传成功', 'data' => $uploadFile]);
```

#### 通用网络请求

[](#通用网络请求)

```
// 发起get请求
$result = http_get($url, $query, $options);

// 发起post请求
$result = http_post($url, $data, $options);
```

#### 系统参数配置（基于 admin\_config 数据表）

[](#系统参数配置基于-admin_config-数据表)

```
// 设置参数
conf($keyname, $keyvalue);

// 获取参数
$keyvalue = conf($kename);
```

#### UTF8加密算法

[](#utf8加密算法)

```
// 字符串加密操作
$string = encode($content);

// 加密字符串解密
$content = decode($string);
```

#### 应用菜单构建

[](#应用菜单构建)

```
// 构建全部应用菜单
php think start:menu

// 构建单个应用菜单
php think start:menu [appName]
```

1.0.3 更新说明
----------

[](#103-更新说明)

- 添加菜单构建命令
- 调整基础查询参数结构
- 取消快速排序属性

1.0.4 更新说明
----------

[](#104-更新说明)

- 快速验证添加严格模式，开启后将只接收经过验证的参数
- 添加全局获取当前管理员方法get\_admin\_id(),get\_admin\_name()
- 优化模型快速查询方法，支持关联及操作符查询
- 修复一些已知问题

###  Health Score

29

—

LowBetter than 59% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity14

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity63

Established project with proven stability

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~32 days

Recently: every ~67 days

Total

19

Last Release

1496d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/ad250385e2443e59ff0d38b36ed8394cabdedf781fe55f94260e85ce2ef9267b?d=identicon)[Simplestart](/maintainers/Simplestart)

---

Top Contributors

[![startctrl](https://avatars.githubusercontent.com/u/255149153?v=4)](https://github.com/startctrl "startctrl (72 commits)")

### Embed Badge

![Health badge](/badges/simplestart-start-library/health.svg)

```
[![Health](https://phpackages.com/badges/simplestart-start-library/health.svg)](https://phpackages.com/packages/simplestart-start-library)
```

###  Alternatives

[topthink/think-captcha

captcha package for thinkphp

132934.4k68](/packages/topthink-think-captcha)[topthink/think-worker

workerman extend for thinkphp

202227.2k9](/packages/topthink-think-worker)[yunwuxin/think-cron

计划任务

17416.2k](/packages/yunwuxin-think-cron)[zzstudio/think-addons

The ThinkPHP6 Addons Package

1518.6k](/packages/zzstudio-think-addons)[topthink/think-annotation

Annotation For ThinkPHP

4831.5k8](/packages/topthink-think-annotation)[liliuwei/thinkphp-jump

适用于thinkphp6.0的跳转扩展

2874.4k1](/packages/liliuwei-thinkphp-jump)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
