mirror of
https://gitee.com/zoujingli/ThinkAdmin.git
synced 2025-04-06 03:58:04 +08:00
ComposerUpdate
This commit is contained in:
parent
98f42ed0cd
commit
6aeb6d0c96
8
composer.lock
generated
8
composer.lock
generated
@ -879,12 +879,12 @@
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/zoujingli/ThinkLibrary.git",
|
||||
"reference": "845f0e19f58548a241fb42369344ca5b3f221337"
|
||||
"reference": "c5ae2601c499d95776061aeda087478f7912c2c5"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/zoujingli/ThinkLibrary/zipball/845f0e19f58548a241fb42369344ca5b3f221337",
|
||||
"reference": "845f0e19f58548a241fb42369344ca5b3f221337",
|
||||
"url": "https://api.github.com/repos/zoujingli/ThinkLibrary/zipball/c5ae2601c499d95776061aeda087478f7912c2c5",
|
||||
"reference": "c5ae2601c499d95776061aeda087478f7912c2c5",
|
||||
"shasum": "",
|
||||
"mirrors": [
|
||||
{
|
||||
@ -928,7 +928,7 @@
|
||||
],
|
||||
"description": "ThinkPHP v6.0 Development Library",
|
||||
"homepage": "http://framework.thinkadmin.top",
|
||||
"time": "2020-07-30T08:07:27+00:00"
|
||||
"time": "2020-07-30T09:50:41+00:00"
|
||||
},
|
||||
{
|
||||
"name": "zoujingli/wechat-developer",
|
||||
|
8
vendor/composer/installed.json
vendored
8
vendor/composer/installed.json
vendored
@ -903,12 +903,12 @@
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/zoujingli/ThinkLibrary.git",
|
||||
"reference": "845f0e19f58548a241fb42369344ca5b3f221337"
|
||||
"reference": "c5ae2601c499d95776061aeda087478f7912c2c5"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/zoujingli/ThinkLibrary/zipball/845f0e19f58548a241fb42369344ca5b3f221337",
|
||||
"reference": "845f0e19f58548a241fb42369344ca5b3f221337",
|
||||
"url": "https://api.github.com/repos/zoujingli/ThinkLibrary/zipball/c5ae2601c499d95776061aeda087478f7912c2c5",
|
||||
"reference": "c5ae2601c499d95776061aeda087478f7912c2c5",
|
||||
"shasum": "",
|
||||
"mirrors": [
|
||||
{
|
||||
@ -924,7 +924,7 @@
|
||||
"ext-json": "*",
|
||||
"topthink/framework": "^6.0"
|
||||
},
|
||||
"time": "2020-07-30T08:07:27+00:00",
|
||||
"time": "2020-07-30T09:50:41+00:00",
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"think": {
|
||||
|
2
vendor/services.php
vendored
2
vendor/services.php
vendored
@ -1,5 +1,5 @@
|
||||
<?php
|
||||
// This file is automatically generated at:2020-07-30 16:11:54
|
||||
// This file is automatically generated at:2020-07-30 17:53:29
|
||||
declare (strict_types = 1);
|
||||
return array (
|
||||
0 => 'think\\admin\\Library',
|
||||
|
2
vendor/zoujingli/think-library/composer.json
vendored
2
vendor/zoujingli/think-library/composer.json
vendored
@ -2,7 +2,7 @@
|
||||
"type": "library",
|
||||
"name": "zoujingli/think-library",
|
||||
"license": "MIT",
|
||||
"homepage": "http://thinkadmin.top",
|
||||
"homepage": "http://framework.thinkadmin.top",
|
||||
"description": "ThinkPHP v6.0 Development Library",
|
||||
"authors": [
|
||||
{
|
||||
|
@ -17,6 +17,7 @@ namespace think\admin;
|
||||
|
||||
use think\admin\command\Database;
|
||||
use think\admin\command\Install;
|
||||
use think\admin\command\Queue;
|
||||
use think\admin\command\Version;
|
||||
use think\admin\multiple\App;
|
||||
use think\admin\multiple\command\Build;
|
||||
@ -46,12 +47,12 @@ class Library extends Service
|
||||
$this->app->event->listen('HttpRun', function () {
|
||||
$this->app->middleware->add(App::class);
|
||||
});
|
||||
// 替换 ThinkPHP 地址处理
|
||||
$this->app->bind('think\route\Url', Url::class);
|
||||
// 替换 ThinkPHP 指令
|
||||
$this->commands(['build' => Build::class, 'clear' => Clear::class]);
|
||||
// 注册 ThinkAdmin 指令
|
||||
$this->commands([Queue::class, Install::class, Version::class, Database::class]);
|
||||
// 动态绑定运行配置
|
||||
$this->app->bind('think\route\Url', Url::class);
|
||||
// 动态应用配置参数
|
||||
SystemService::instance()->bindRuntime();
|
||||
}
|
||||
|
@ -65,7 +65,7 @@ abstract class Storage
|
||||
|
||||
/**
|
||||
* 存储初始化
|
||||
* @return Storage|AliossStorage|LocalStorage|QiniuStorage
|
||||
* @return static
|
||||
* @throws \think\db\exception\DataNotFoundException
|
||||
* @throws \think\db\exception\DbException
|
||||
* @throws \think\db\exception\ModelNotFoundException
|
||||
@ -98,7 +98,7 @@ abstract class Storage
|
||||
/**
|
||||
* 设置文件驱动名称
|
||||
* @param string $name 驱动名称
|
||||
* @return AliossStorage|LocalStorage|QiniuStorage
|
||||
* @return static
|
||||
* @throws Exception
|
||||
* @throws \think\db\exception\DataNotFoundException
|
||||
* @throws \think\db\exception\DbException
|
||||
|
@ -37,12 +37,6 @@ class AliossStorage extends Storage
|
||||
*/
|
||||
private $bucket;
|
||||
|
||||
/**
|
||||
* 绑定访问域名
|
||||
* @var string
|
||||
*/
|
||||
private $domain;
|
||||
|
||||
/**
|
||||
* AccessKeyId
|
||||
* @var string
|
||||
@ -68,14 +62,14 @@ class AliossStorage extends Storage
|
||||
// 读取配置文件
|
||||
$this->point = sysconf('storage.alioss_point');
|
||||
$this->bucket = sysconf('storage.alioss_bucket');
|
||||
$this->domain = sysconf('storage.alioss_http_domain');
|
||||
$this->accessKey = sysconf('storage.alioss_access_key');
|
||||
$this->secretKey = sysconf('storage.alioss_secret_key');
|
||||
// 计算链接前缀
|
||||
$type = strtolower(sysconf('storage.alioss_http_protocol'));
|
||||
if ($type === 'auto') $this->prefix = "//{$this->domain}";
|
||||
elseif ($type === 'http') $this->prefix = "http://{$this->domain}";
|
||||
elseif ($type === 'https') $this->prefix = "https://{$this->domain}";
|
||||
$domain = strtolower(sysconf('storage.alioss_http_domain'));
|
||||
if ($type === 'auto') $this->prefix = "//{$domain}";
|
||||
elseif ($type === 'http') $this->prefix = "http://{$domain}";
|
||||
elseif ($type === 'https') $this->prefix = "https://{$domain}";
|
||||
else throw new \think\admin\Exception('未配置阿里云URL域名哦');
|
||||
// 初始化配置并返回当前实例
|
||||
return parent::initialize();
|
||||
@ -84,7 +78,7 @@ class AliossStorage extends Storage
|
||||
/**
|
||||
* 获取当前实例对象
|
||||
* @param null $name
|
||||
* @return AliossStorage|LocalStorage|QiniuStorage
|
||||
* @return static
|
||||
* @throws \think\admin\Exception
|
||||
* @throws \think\db\exception\DataNotFoundException
|
||||
* @throws \think\db\exception\DbException
|
||||
|
@ -53,7 +53,7 @@ class LocalStorage extends Storage
|
||||
/**
|
||||
* 获取当前实例对象
|
||||
* @param null $name
|
||||
* @return AliossStorage|LocalStorage|QiniuStorage
|
||||
* @return static
|
||||
* @throws \think\admin\Exception
|
||||
* @throws \think\db\exception\DataNotFoundException
|
||||
* @throws \think\db\exception\DbException
|
||||
|
@ -26,7 +26,6 @@ use think\admin\Storage;
|
||||
class QiniuStorage extends Storage
|
||||
{
|
||||
private $bucket;
|
||||
private $domain;
|
||||
private $accessKey;
|
||||
private $secretKey;
|
||||
|
||||
@ -42,14 +41,14 @@ class QiniuStorage extends Storage
|
||||
{
|
||||
// 读取配置文件
|
||||
$this->bucket = sysconf('storage.qiniu_bucket');
|
||||
$this->domain = sysconf('storage.qiniu_http_domain');
|
||||
$this->accessKey = sysconf('storage.qiniu_access_key');
|
||||
$this->secretKey = sysconf('storage.qiniu_secret_key');
|
||||
// 计算链接前缀
|
||||
$type = strtolower(sysconf('storage.qiniu_http_protocol'));
|
||||
if ($type === 'auto') $this->prefix = "//{$this->domain}";
|
||||
elseif ($type === 'http') $this->prefix = "http://{$this->domain}";
|
||||
elseif ($type === 'https') $this->prefix = "https://{$this->domain}";
|
||||
$domain = strtolower(sysconf('storage.qiniu_http_domain'));
|
||||
if ($type === 'auto') $this->prefix = "//{$domain}";
|
||||
elseif ($type === 'http') $this->prefix = "http://{$domain}";
|
||||
elseif ($type === 'https') $this->prefix = "https://{$domain}";
|
||||
else throw new \think\admin\Exception('未配置七牛云URL域名哦');
|
||||
// 初始化配置并返回当前实例
|
||||
return parent::initialize();
|
||||
@ -58,7 +57,7 @@ class QiniuStorage extends Storage
|
||||
/**
|
||||
* 获取当前实例对象
|
||||
* @param null $name
|
||||
* @return AliossStorage|LocalStorage|QiniuStorage
|
||||
* @return static
|
||||
* @throws \think\admin\Exception
|
||||
* @throws \think\db\exception\DataNotFoundException
|
||||
* @throws \think\db\exception\DbException
|
||||
|
Loading…
x
Reference in New Issue
Block a user