From 254480a8bb6a6733bd5cdfd2a0870b7ddbf2e9ab Mon Sep 17 00:00:00 2001 From: Anyon Date: Fri, 10 Jan 2020 12:10:19 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E7=B3=BB=E7=BB=9F=E4=BB=BB?= =?UTF-8?q?=E5=8A=A1?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/admin/controller/Index.php | 10 - app/admin/view/index/main.html | 176 ------------------ composer.lock | 8 +- vendor/composer/installed.json | 8 +- vendor/services.php | 2 +- .../src/service/QueueService.php | 14 +- 6 files changed, 19 insertions(+), 199 deletions(-) delete mode 100644 app/admin/view/index/main.html diff --git a/app/admin/controller/Index.php b/app/admin/controller/Index.php index 804902b75..62f7b4a1f 100644 --- a/app/admin/controller/Index.php +++ b/app/admin/controller/Index.php @@ -47,16 +47,6 @@ class Index extends Controller } } - /** - * 后台环境信息 - */ - public function main() - { - $this->think_ver = $this->app->version(); - $this->mysql_ver = $this->app->db->query('select version() as ver')[0]['ver']; - $this->fetch(); - } - /** * 修改用户资料 * @login true diff --git a/app/admin/view/index/main.html b/app/admin/view/index/main.html deleted file mode 100644 index 4b85f4874..000000000 --- a/app/admin/view/index/main.html +++ /dev/null @@ -1,176 +0,0 @@ -{extend name='main'} - -{block name='content'} -
-
商城统计
-
-
-
-
商品总量
-
63
-
当前商品总数量
-
- -
-
-
-
用户总量
-
1,634
-
当前用户总数量
-
- -
-
-
-
订单总量
-
148
-
已付款订单总数量
-
- -
-
-
-
评价总量
-
0
-
订单评价总数量
-
- -
-
-
- -
-
实时概况
-
-
-
-
- -
-
-
销售额(元)
-
1351.00
-
昨日:974.00
-
-
-
支付订单数
-
106
-
昨日:76
-
-
-
-
-
-
- -
-
-
新增用户数
-
327
-
昨日:238
-
-
-
下单用户数
-
69
-
昨日:34
-
-
-
-
-
- -
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
系统信息
当前程序版本{:sysconf('app_version')}
运行PHP版本{$Think.PHP_VERSION}
ThinkPHP版本{$think_ver}
MySQL数据库版本{$mysql_ver}
服务器操作系统{:php_uname('s')}
WEB运行环境{:php_sapi_name()}
上传大小限制{:ini_get('upload_max_filesize')}
POST大小限制{:ini_get('post_max_size')}
-
-
-
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
产品团队
产品名称ThinkAdmin
在线体验http://demo.thinkadmin.top
官方QQ群 - - - -
项目地址https://github.com/zoujingli/ThinkAdmin
BUG反馈https://github.com/zoujingli/ThinkAdmin/issues
开发团队广州楚才信息科技有限公司
团队官网http://www.cuci.cc
办公地址广州市天河区东圃一横路东泷商贸中心G02
-
-
-
-{/block} diff --git a/composer.lock b/composer.lock index 8ba453f92..f789444bf 100644 --- a/composer.lock +++ b/composer.lock @@ -909,12 +909,12 @@ "source": { "type": "git", "url": "https://github.com/zoujingli/ThinkLibrary.git", - "reference": "95cfaa9e2e93adf76a4e28f57157d8f779f55680" + "reference": "a644ee8cd994cabbbdfae43ab43557bb91cf5705" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/zoujingli/ThinkLibrary/zipball/95cfaa9e2e93adf76a4e28f57157d8f779f55680", - "reference": "95cfaa9e2e93adf76a4e28f57157d8f779f55680", + "url": "https://api.github.com/repos/zoujingli/ThinkLibrary/zipball/a644ee8cd994cabbbdfae43ab43557bb91cf5705", + "reference": "a644ee8cd994cabbbdfae43ab43557bb91cf5705", "shasum": "", "mirrors": [ { @@ -958,7 +958,7 @@ ], "description": "ThinkPHP v6.0 Development Library", "homepage": "http://framework.thinkadmin.top", - "time": "2020-01-10T02:43:12+00:00" + "time": "2020-01-10T04:03:27+00:00" }, { "name": "zoujingli/wechat-developer", diff --git a/vendor/composer/installed.json b/vendor/composer/installed.json index 33a7cdee0..32fdcc6e8 100644 --- a/vendor/composer/installed.json +++ b/vendor/composer/installed.json @@ -935,12 +935,12 @@ "source": { "type": "git", "url": "https://github.com/zoujingli/ThinkLibrary.git", - "reference": "95cfaa9e2e93adf76a4e28f57157d8f779f55680" + "reference": "a644ee8cd994cabbbdfae43ab43557bb91cf5705" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/zoujingli/ThinkLibrary/zipball/95cfaa9e2e93adf76a4e28f57157d8f779f55680", - "reference": "95cfaa9e2e93adf76a4e28f57157d8f779f55680", + "url": "https://api.github.com/repos/zoujingli/ThinkLibrary/zipball/a644ee8cd994cabbbdfae43ab43557bb91cf5705", + "reference": "a644ee8cd994cabbbdfae43ab43557bb91cf5705", "shasum": "", "mirrors": [ { @@ -956,7 +956,7 @@ "ext-json": "*", "topthink/framework": "^6.0" }, - "time": "2020-01-10T02:43:12+00:00", + "time": "2020-01-10T04:03:27+00:00", "type": "library", "extra": { "think": { diff --git a/vendor/services.php b/vendor/services.php index 6d59594a3..3a221b11e 100644 --- a/vendor/services.php +++ b/vendor/services.php @@ -1,5 +1,5 @@ 'think\\app\\Service', diff --git a/vendor/zoujingli/think-library/src/service/QueueService.php b/vendor/zoujingli/think-library/src/service/QueueService.php index 68611325f..a7eaeaf30 100644 --- a/vendor/zoujingli/think-library/src/service/QueueService.php +++ b/vendor/zoujingli/think-library/src/service/QueueService.php @@ -64,7 +64,10 @@ class QueueService extends Service if (!empty($code)) { $this->code = $code; $this->queue = $this->app->db->name('SystemQueue')->where(['code' => $this->code])->find(); - if (empty($this->queue)) throw new \think\Exception("Queue {$code} Not found."); + if (empty($this->queue)) { + $this->app->log->error(__METHOD__ . " Qeueu initialize failed, Queue {$code} not found."); + throw new \think\Exception("Queue {$code} not found."); + } $this->code = $this->queue['code']; $this->title = $this->queue['title']; $this->data = json_decode($this->queue['exec_data'], true) ?: []; @@ -92,9 +95,12 @@ class QueueService extends Service */ public function reset($wait = 0) { - if (empty($this->queue)) throw new \think\Exception('Queue data cannot be empty!'); - $this->app->db->name('SystemQueue')->where(['code' => $this->code])->failException(true)->update([ - 'exec_time' => time() + $wait, 'attempts' => $this->queue['attempts'] + 1, 'status' => '1', + if (empty($this->queue)) { + $this->app->log->error(__METHOD__ . " Qeueu reset failed, Queue {$this->code} data cannot be empty!"); + throw new \think\Exception("Qeueu reset failed, Queue {$this->code} data cannot be empty!"); + } + $this->app->db->name('SystemQueue')->where(['code' => $this->code])->strict(false)->failException(true)->update([ + 'exec_pid' => '0', 'exec_time' => time() + $wait, 'attempts' => $this->app->db->raw('attempts+1'), 'status' => '1', ]); return $this->initialize($this->code); }