From be72564d8028de49f64f3c994d31cd11230281d6 Mon Sep 17 00:00:00 2001 From: Anyon Date: Fri, 19 Jun 2020 10:19:07 +0800 Subject: [PATCH] ComposerUpdate --- composer.json | 2 +- composer.lock | 18 +++++++-------- vendor/composer/installed.json | 20 ++++++++--------- vendor/opis/closure/CHANGELOG.md | 4 ++++ vendor/opis/closure/src/ReflectionClosure.php | 2 +- vendor/services.php | 2 +- .../think-library/src/helper/DeleteHelper.php | 22 ++++++++++++------- 7 files changed, 40 insertions(+), 30 deletions(-) diff --git a/composer.json b/composer.json index 9a7345c8e..2e71f24f9 100644 --- a/composer.json +++ b/composer.json @@ -2,7 +2,7 @@ "type": "project", "name": "zoujingli/thinkadmin", "license": "MIT", - "homepage": "http://demo.thinkadmin.top", + "homepage": "https://thinkadmin.top", "description": "Application development framework", "keywords": [ "ThinkAdmin", diff --git a/composer.lock b/composer.lock index ab4cd06a9..75ec8b8d4 100644 --- a/composer.lock +++ b/composer.lock @@ -223,16 +223,16 @@ }, { "name": "opis/closure", - "version": "3.5.4", + "version": "3.5.5", "source": { "type": "git", "url": "https://github.com/opis/closure.git", - "reference": "1d0deef692f66dae5d70663caee2867d0971306b" + "reference": "dec9fc5ecfca93f45cd6121f8e6f14457dff372c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/opis/closure/zipball/1d0deef692f66dae5d70663caee2867d0971306b", - "reference": "1d0deef692f66dae5d70663caee2867d0971306b", + "url": "https://api.github.com/repos/opis/closure/zipball/dec9fc5ecfca93f45cd6121f8e6f14457dff372c", + "reference": "dec9fc5ecfca93f45cd6121f8e6f14457dff372c", "shasum": "", "mirrors": [ { @@ -286,7 +286,7 @@ "serialization", "serialize" ], - "time": "2020-06-07T11:41:29+00:00" + "time": "2020-06-17T14:59:55+00:00" }, { "name": "psr/cache", @@ -929,12 +929,12 @@ "source": { "type": "git", "url": "https://github.com/zoujingli/ThinkLibrary.git", - "reference": "60e7ef58637b5efdf08d8a8dd5199c183272f655" + "reference": "b4b544f9e3ee8e5e3ed218f14eb442371a1de58c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/zoujingli/ThinkLibrary/zipball/60e7ef58637b5efdf08d8a8dd5199c183272f655", - "reference": "60e7ef58637b5efdf08d8a8dd5199c183272f655", + "url": "https://api.github.com/repos/zoujingli/ThinkLibrary/zipball/b4b544f9e3ee8e5e3ed218f14eb442371a1de58c", + "reference": "b4b544f9e3ee8e5e3ed218f14eb442371a1de58c", "shasum": "", "mirrors": [ { @@ -978,7 +978,7 @@ ], "description": "ThinkPHP v6.0 Development Library", "homepage": "http://framework.thinkadmin.top", - "time": "2020-06-16T08:08:00+00:00" + "time": "2020-06-18T04:01:24+00:00" }, { "name": "zoujingli/wechat-developer", diff --git a/vendor/composer/installed.json b/vendor/composer/installed.json index a22e2edc2..3ff52730f 100644 --- a/vendor/composer/installed.json +++ b/vendor/composer/installed.json @@ -222,17 +222,17 @@ }, { "name": "opis/closure", - "version": "3.5.4", - "version_normalized": "3.5.4.0", + "version": "3.5.5", + "version_normalized": "3.5.5.0", "source": { "type": "git", "url": "https://github.com/opis/closure.git", - "reference": "1d0deef692f66dae5d70663caee2867d0971306b" + "reference": "dec9fc5ecfca93f45cd6121f8e6f14457dff372c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/opis/closure/zipball/1d0deef692f66dae5d70663caee2867d0971306b", - "reference": "1d0deef692f66dae5d70663caee2867d0971306b", + "url": "https://api.github.com/repos/opis/closure/zipball/dec9fc5ecfca93f45cd6121f8e6f14457dff372c", + "reference": "dec9fc5ecfca93f45cd6121f8e6f14457dff372c", "shasum": "", "mirrors": [ { @@ -248,7 +248,7 @@ "jeremeamia/superclosure": "^2.0", "phpunit/phpunit": "^4.0 || ^5.0 || ^6.0 || ^7.0" }, - "time": "2020-06-07T11:41:29+00:00", + "time": "2020-06-17T14:59:55+00:00", "type": "library", "extra": { "branch-alias": { @@ -955,12 +955,12 @@ "source": { "type": "git", "url": "https://github.com/zoujingli/ThinkLibrary.git", - "reference": "60e7ef58637b5efdf08d8a8dd5199c183272f655" + "reference": "b4b544f9e3ee8e5e3ed218f14eb442371a1de58c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/zoujingli/ThinkLibrary/zipball/60e7ef58637b5efdf08d8a8dd5199c183272f655", - "reference": "60e7ef58637b5efdf08d8a8dd5199c183272f655", + "url": "https://api.github.com/repos/zoujingli/ThinkLibrary/zipball/b4b544f9e3ee8e5e3ed218f14eb442371a1de58c", + "reference": "b4b544f9e3ee8e5e3ed218f14eb442371a1de58c", "shasum": "", "mirrors": [ { @@ -976,7 +976,7 @@ "ext-json": "*", "topthink/framework": "^6.0" }, - "time": "2020-06-16T08:08:00+00:00", + "time": "2020-06-18T04:01:24+00:00", "type": "library", "extra": { "think": { diff --git a/vendor/opis/closure/CHANGELOG.md b/vendor/opis/closure/CHANGELOG.md index 5eb1d6218..cb2898f58 100644 --- a/vendor/opis/closure/CHANGELOG.md +++ b/vendor/opis/closure/CHANGELOG.md @@ -1,6 +1,10 @@ CHANGELOG --------- +### v3.5.5, 2020.06.17 + +- Fixed a false-positive when using `Opis\Closure\ReflectionClosure::isScopeRequired` method + ### v3.5.4, 2020.06.07 - Fixed a false-positive when using `Opis\Closure\ReflectionClosure::isScopeRequired` method diff --git a/vendor/opis/closure/src/ReflectionClosure.php b/vendor/opis/closure/src/ReflectionClosure.php index c5aff5dc9..1b7e3a167 100644 --- a/vendor/opis/closure/src/ReflectionClosure.php +++ b/vendor/opis/closure/src/ReflectionClosure.php @@ -569,7 +569,7 @@ class ReflectionClosure extends ReflectionFunction $context === 'root' ){ if($id_start_ci === 'self' || $id_start_ci === 'static' || $id_start_ci === 'parent'){ - if (!$inside_structure) { + if (!$inside_structure && !$id_start_ci === 'static') { $isUsingScope = true; } } elseif (!($php7 && in_array($id_start_ci, $php7_types))){ diff --git a/vendor/services.php b/vendor/services.php index bdfceb91e..5b020c0a0 100644 --- a/vendor/services.php +++ b/vendor/services.php @@ -1,5 +1,5 @@ 'think\\app\\Service', diff --git a/vendor/zoujingli/think-library/src/helper/DeleteHelper.php b/vendor/zoujingli/think-library/src/helper/DeleteHelper.php index d1d620b9f..ade12a0eb 100644 --- a/vendor/zoujingli/think-library/src/helper/DeleteHelper.php +++ b/vendor/zoujingli/think-library/src/helper/DeleteHelper.php @@ -29,7 +29,7 @@ class DeleteHelper extends Helper * 表单额外更新条件 * @var array */ - protected $where; + protected $map; /** * 数据对象主键名称 @@ -48,28 +48,34 @@ class DeleteHelper extends Helper * @param string|Query $dbQuery * @param string $field 操作数据主键 * @param array $where 额外更新条件 - * @return boolean|null + * @return boolean|null|void * @throws \think\db\exception\DbException */ public function init($dbQuery, $field = '', $where = []) { - $this->where = $where; + $this->map = $where; $this->query = $this->buildQuery($dbQuery); $this->field = $field ?: $this->query->getPk(); $this->value = $this->app->request->post($this->field, null); // 主键限制处理 - if (!isset($this->where[$this->field]) && is_string($this->value)) { + if (!isset($this->map[$this->field]) && is_string($this->value)) { $this->query->whereIn($this->field, explode(',', $this->value)); } // 前置回调处理 - if (false === $this->controller->callback('_delete_filter', $this->query, $where)) { + if (false === $this->controller->callback('_delete_filter', $this->query, $this->map)) { return null; } // 执行删除操作 - if (method_exists($this->query, 'getTableFields') && in_array('is_deleted', $this->query->getTableFields())) { - $result = $this->query->where($this->where)->update(['is_deleted' => '1']); + $data = []; + if (method_exists($this->query, 'getTableFields')) { + $fields = $this->query->getTableFields(); + if (in_array('deleted', $fields)) $data['deleted'] = 1; + if (in_array('is_deleted', $fields)) $data['is_deleted'] = 1; + } + if (empty($data)) { + $result = $this->query->where($this->map)->update($data); } else { - $result = $this->query->where($this->where)->delete(); + $result = $this->query->where($this->map)->delete(); } // 结果回调处理 if (false === $this->controller->callback('_delete_result', $result)) {