diff --git a/vendor/composer/installed.json b/vendor/composer/installed.json index 9063162f2..e54d1e8ff 100644 --- a/vendor/composer/installed.json +++ b/vendor/composer/installed.json @@ -893,12 +893,12 @@ "source": { "type": "git", "url": "https://github.com/zoujingli/ThinkLibrary.git", - "reference": "141fa175f3cdbdb4ad2e9927d6de379fb618e75a" + "reference": "b55328975855e44d2947ccd5503e52b30385a117" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/zoujingli/ThinkLibrary/zipball/141fa175f3cdbdb4ad2e9927d6de379fb618e75a", - "reference": "141fa175f3cdbdb4ad2e9927d6de379fb618e75a", + "url": "https://api.github.com/repos/zoujingli/ThinkLibrary/zipball/b55328975855e44d2947ccd5503e52b30385a117", + "reference": "b55328975855e44d2947ccd5503e52b30385a117", "shasum": "", "mirrors": [ { @@ -915,7 +915,7 @@ "ext-mbstring": "*", "topthink/framework": "^6.0" }, - "time": "2020-09-29T05:20:22+00:00", + "time": "2020-10-09T01:50:18+00:00", "type": "library", "extra": { "think": { diff --git a/vendor/services.php b/vendor/services.php index 95e185a74..4de1fab6c 100644 --- a/vendor/services.php +++ b/vendor/services.php @@ -1,5 +1,5 @@ 'think\\admin\\Library', diff --git a/vendor/zoujingli/think-library/src/helper/FormHelper.php b/vendor/zoujingli/think-library/src/helper/FormHelper.php index 52e9ec1c1..35f5b1280 100644 --- a/vendor/zoujingli/think-library/src/helper/FormHelper.php +++ b/vendor/zoujingli/think-library/src/helper/FormHelper.php @@ -35,7 +35,7 @@ class FormHelper extends Helper * @param string $field 指定数据主键 * @param array $where 额外更新条件 * @param array $data 表单扩展数据 - * @return array|boolean|mixed + * @return array|boolean|mixed|void * @throws \think\db\exception\DataNotFoundException * @throws \think\db\exception\DbException * @throws \think\db\exception\ModelNotFoundException diff --git a/vendor/zoujingli/think-library/src/helper/PageHelper.php b/vendor/zoujingli/think-library/src/helper/PageHelper.php index 3c838c1e9..6c0d259c3 100644 --- a/vendor/zoujingli/think-library/src/helper/PageHelper.php +++ b/vendor/zoujingli/think-library/src/helper/PageHelper.php @@ -36,7 +36,7 @@ class PageHelper extends Helper * @param boolean|integer $total 集合分页记录数 * @param integer $limit 集合每页记录数 * @param string $template 模板文件名称 - * @return array|mixed + * @return array|mixed|void * @throws \think\db\exception\DataNotFoundException * @throws \think\db\exception\DbException * @throws \think\db\exception\ModelNotFoundException @@ -45,15 +45,15 @@ class PageHelper extends Helper { $this->query = $this->buildQuery($dbQuery); // 数据列表排序自动处理 - if ($this->app->request->isPost()) $this->sortAction(); + if ($this->app->request->isPost()) $this->_sortAction(); // 列表设置默认排序处理 - if (!$this->query->getOptions('order')) $this->orderAction(); + if (!$this->query->getOptions('order')) $this->_orderAction(); // 列表分页及结果集处理 if ($page) { if ($limit > 0) { $limit = intval($limit); } else { - $limit = $this->app->request->get('limit', $this->app->cookie->get('limit')); + $limit = $this->app->request->get('limit', $this->app->cookie->get('limit', 20)); $this->app->cookie->set('limit', ($limit = intval($limit >= 10 ? $limit : 20)) . ''); } [$options, $query] = ['', $this->app->request->get()]; @@ -91,11 +91,11 @@ class PageHelper extends Helper * POST 提交 {action:sort,PK:$PK,SORT:$SORT} * @throws \think\db\exception\DbException */ - private function sortAction() + private function _sortAction() { if ($this->app->request->post('action') === 'sort') { if (method_exists($this->query, 'getTableFields') && in_array('sort', $this->query->getTableFields())) { - $pk = $this->query->getPk() ?? 'id'; + $pk = $this->query->getPk() ?: 'id'; if ($this->app->request->has($pk, 'post')) { $map = [$pk => $this->app->request->post($pk, 0)]; $data = ['sort' => intval($this->app->request->post('sort', 0))]; @@ -112,7 +112,7 @@ class PageHelper extends Helper * 列表默认排序处理 * 未配置排序规则时自动按SORT排序 */ - private function orderAction() + private function _orderAction() { if (method_exists($this->query, 'getTableFields')) { if (in_array('sort', $this->query->getTableFields())) { diff --git a/vendor/zoujingli/think-library/src/helper/SaveHelper.php b/vendor/zoujingli/think-library/src/helper/SaveHelper.php index 55c0da9db..fbdd8ef0c 100644 --- a/vendor/zoujingli/think-library/src/helper/SaveHelper.php +++ b/vendor/zoujingli/think-library/src/helper/SaveHelper.php @@ -34,7 +34,7 @@ class SaveHelper extends Helper * @param array $data 表单扩展数据 * @param string $field 数据对象主键 * @param array $where 额外更新条件 - * @return boolean + * @return boolean|void * @throws \think\db\exception\DbException */ public function init($dbQuery, array $data = [], string $field = '', array $where = []) diff --git a/vendor/zoujingli/think-library/src/multiple/App.php b/vendor/zoujingli/think-library/src/multiple/App.php index 98555ba90..332842b78 100644 --- a/vendor/zoujingli/think-library/src/multiple/App.php +++ b/vendor/zoujingli/think-library/src/multiple/App.php @@ -65,9 +65,7 @@ class App */ public function handle(Request $request, Closure $next) { - if (!$this->parseMultiApp()) { - return $next($request); - } + if (!$this->parseMultiApp()) return $next($request); return $this->app->middleware->pipeline('app')->send($request)->then(function ($request) use ($next) { return $next($request); }); @@ -155,7 +153,6 @@ class App /** * 获取当前运行入口名称 - * @access protected * @codeCoverageIgnore * @return string */