From 3ca70bdeed2154f0b889e23a5a029cdefb376bb7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=90=B4=E6=98=8A=E5=A4=A9?= <442384644@qq.com> Date: Mon, 27 Feb 2023 14:21:52 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E9=85=8D=E7=BD=AE=E6=8F=90?= =?UTF-8?q?=E9=86=92=EF=BC=8C=E5=AE=9A=E6=97=B6=E4=BB=BB=E5=8A=A1=E6=8F=90?= =?UTF-8?q?=E9=86=92=E6=97=B6=E9=97=B4=E6=94=B9=E4=B8=BA1=E5=88=86?= =?UTF-8?q?=E9=92=9F=EF=BC=8C=E5=90=8E=E5=8F=B0=E9=A6=96=E9=A1=B5=E6=9F=B1?= =?UTF-8?q?=E7=8A=B6=E5=9B=BE=E9=A2=9C=E8=89=B2=E5=8C=BA=E5=88=86=EF=BC=8C?= =?UTF-8?q?=E5=88=86=E7=B1=BB=E7=BC=93=E5=AD=98=E4=BC=98=E5=8C=96=EF=BC=8C?= =?UTF-8?q?=E5=AE=A2=E6=9C=8D=E6=9F=A5=E8=AF=A2=E7=BC=93=E5=AD=98=E4=BC=98?= =?UTF-8?q?=E5=8C=96=EF=BC=8C=E6=B8=A0=E9=81=93=E7=A0=81=E6=97=B6=E9=97=B4?= =?UTF-8?q?=E5=A4=84=E7=90=86=EF=BC=8C=E6=9B=B4=E6=96=B0=E5=AE=89=E8=A3=85?= =?UTF-8?q?sql?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../controller/v1/setting/SystemConfig.php | 3 + .../app/listener/admin/AdminLoginListener.php | 4 +- .../app/services/order/StoreOrderServices.php | 126 ++++++++++++++++-- .../product/product/StoreCategoryServices.php | 4 - crmeb/app/services/user/UserAuthServices.php | 2 +- .../services/wechat/WechatQrcodeServices.php | 1 + crmeb/public/install/crmeb.sql | 12 +- 7 files changed, 134 insertions(+), 18 deletions(-) diff --git a/crmeb/app/adminapi/controller/v1/setting/SystemConfig.php b/crmeb/app/adminapi/controller/v1/setting/SystemConfig.php index dd6b405f0..ff4de7ddb 100644 --- a/crmeb/app/adminapi/controller/v1/setting/SystemConfig.php +++ b/crmeb/app/adminapi/controller/v1/setting/SystemConfig.php @@ -307,6 +307,9 @@ class SystemConfig extends AuthController return app('json')->fail(400763); } } + if (isset($post['uni_brokerage_price']) && preg_match('/\.[0-9]{2,}[1-9][0-9]*$/', (string)$post['uni_brokerage_price']) > 0) { + return app('json')->fail(500029); + } //支付接口类型选择,如果有订单就不能再进行切换 // if (isset($post['pay_wechat_type'])) { diff --git a/crmeb/app/listener/admin/AdminLoginListener.php b/crmeb/app/listener/admin/AdminLoginListener.php index 049fa17c7..1297a4f81 100644 --- a/crmeb/app/listener/admin/AdminLoginListener.php +++ b/crmeb/app/listener/admin/AdminLoginListener.php @@ -35,13 +35,11 @@ class AdminLoginListener } try { - $timerPath = root_path('runtime') . '.timer'; $timer = file_get_contents($timerPath); - if ($timer && $timer <= time() && $timer > (time() - 10)) { + if ($timer && $timer <= time() && $timer > (time() - 70)) { $res1 = true; } - } catch (\Throwable $e) { } diff --git a/crmeb/app/services/order/StoreOrderServices.php b/crmeb/app/services/order/StoreOrderServices.php index 3dc91b255..b37fa8fb0 100644 --- a/crmeb/app/services/order/StoreOrderServices.php +++ b/crmeb/app/services/order/StoreOrderServices.php @@ -988,10 +988,46 @@ HTML; ] ]] ]; + $series3 = ['normal' => ['color' => [ + 'x' => 0, 'y' => 0, 'x2' => 0, 'y2' => 1, + 'colorStops' => [ + [ + 'offset' => 0, + 'color' => '#69cdff' + ], + [ + 'offset' => 0.5, + 'color' => '#3eb3f7' + ], + [ + 'offset' => 1, + 'color' => '#1495eb' + ] + ] + ]] + ]; + $series4 = ['normal' => ['color' => [ + 'x' => 0, 'y' => 0, 'x2' => 0, 'y2' => 1, + 'colorStops' => [ + [ + 'offset' => 0, + 'color' => '#6fdeab' + ], + [ + 'offset' => 0.5, + 'color' => '#44d693' + ], + [ + 'offset' => 1, + 'color' => '#2cc981' + ] + ] + ]] + ]; $chartdata['series'][] = ['name' => $chartdata['legend'][0], 'type' => 'bar', 'itemStyle' => $series1, 'data' => $data['pre']['price']];//分类1值 - $chartdata['series'][] = ['name' => $chartdata['legend'][1], 'type' => 'bar', 'itemStyle' => $series1, 'data' => $data['now']['price']];//分类1值 - $chartdata['series'][] = ['name' => $chartdata['legend'][2], 'type' => 'line', 'itemStyle' => $series2, 'data' => $data['pre']['count'], 'yAxisIndex' => 1];//分类2值 - $chartdata['series'][] = ['name' => $chartdata['legend'][3], 'type' => 'line', 'itemStyle' => $series2, 'data' => $data['now']['count'], 'yAxisIndex' => 1];//分类2值 + $chartdata['series'][] = ['name' => $chartdata['legend'][1], 'type' => 'bar', 'itemStyle' => $series2, 'data' => $data['now']['price']];//分类1值 + $chartdata['series'][] = ['name' => $chartdata['legend'][2], 'type' => 'line', 'itemStyle' => $series3, 'data' => $data['pre']['count'], 'yAxisIndex' => 1];//分类2值 + $chartdata['series'][] = ['name' => $chartdata['legend'][3], 'type' => 'line', 'itemStyle' => $series4, 'data' => $data['now']['count'], 'yAxisIndex' => 1];//分类2值 //统计总数上期 $pre_total = $this->dao->preTotalFind($datebefor, $dateafter); @@ -1109,10 +1145,46 @@ HTML; ] ]] ]; + $series3 = ['normal' => ['color' => [ + 'x' => 0, 'y' => 0, 'x2' => 0, 'y2' => 1, + 'colorStops' => [ + [ + 'offset' => 0, + 'color' => '#69cdff' + ], + [ + 'offset' => 0.5, + 'color' => '#3eb3f7' + ], + [ + 'offset' => 1, + 'color' => '#1495eb' + ] + ] + ]] + ]; + $series4 = ['normal' => ['color' => [ + 'x' => 0, 'y' => 0, 'x2' => 0, 'y2' => 1, + 'colorStops' => [ + [ + 'offset' => 0, + 'color' => '#6fdeab' + ], + [ + 'offset' => 0.5, + 'color' => '#44d693' + ], + [ + 'offset' => 1, + 'color' => '#2cc981' + ] + ] + ]] + ]; $chartdata['series'][] = ['name' => $chartdata['legend'][0], 'type' => 'bar', 'itemStyle' => $series1, 'data' => $data['pre']['price']];//分类1值 - $chartdata['series'][] = ['name' => $chartdata['legend'][1], 'type' => 'bar', 'itemStyle' => $series1, 'data' => $data['now']['price']];//分类1值 - $chartdata['series'][] = ['name' => $chartdata['legend'][2], 'type' => 'line', 'itemStyle' => $series2, 'data' => $data['pre']['count'], 'yAxisIndex' => 1];//分类2值 - $chartdata['series'][] = ['name' => $chartdata['legend'][3], 'type' => 'line', 'itemStyle' => $series2, 'data' => $data['now']['count'], 'yAxisIndex' => 1];//分类2值 + $chartdata['series'][] = ['name' => $chartdata['legend'][1], 'type' => 'bar', 'itemStyle' => $series2, 'data' => $data['now']['price']];//分类1值 + $chartdata['series'][] = ['name' => $chartdata['legend'][2], 'type' => 'line', 'itemStyle' => $series3, 'data' => $data['pre']['count'], 'yAxisIndex' => 1];//分类2值 + $chartdata['series'][] = ['name' => $chartdata['legend'][3], 'type' => 'line', 'itemStyle' => $series4, 'data' => $data['now']['count'], 'yAxisIndex' => 1];//分类2值 //统计总数上期 $pre_total = $this->dao->preTotalFind($datebefor, $dateafter); @@ -1228,10 +1300,46 @@ HTML; ] ]] ]; + $series3 = ['normal' => ['color' => [ + 'x' => 0, 'y' => 0, 'x2' => 0, 'y2' => 1, + 'colorStops' => [ + [ + 'offset' => 0, + 'color' => '#69cdff' + ], + [ + 'offset' => 0.5, + 'color' => '#3eb3f7' + ], + [ + 'offset' => 1, + 'color' => '#1495eb' + ] + ] + ]] + ]; + $series4 = ['normal' => ['color' => [ + 'x' => 0, 'y' => 0, 'x2' => 0, 'y2' => 1, + 'colorStops' => [ + [ + 'offset' => 0, + 'color' => '#6fdeab' + ], + [ + 'offset' => 0.5, + 'color' => '#44d693' + ], + [ + 'offset' => 1, + 'color' => '#2cc981' + ] + ] + ]] + ]; $chartdata['series'][] = ['name' => $chartdata['legend'][0], 'type' => 'bar', 'itemStyle' => $series1, 'data' => $data['pre']['price']];//分类1值 - $chartdata['series'][] = ['name' => $chartdata['legend'][1], 'type' => 'bar', 'itemStyle' => $series1, 'data' => $data['now']['price']];//分类1值 - $chartdata['series'][] = ['name' => $chartdata['legend'][2], 'type' => 'line', 'itemStyle' => $series2, 'data' => $data['pre']['count'], 'yAxisIndex' => 1];//分类2值 - $chartdata['series'][] = ['name' => $chartdata['legend'][3], 'type' => 'line', 'itemStyle' => $series2, 'data' => $data['now']['count'], 'yAxisIndex' => 1];//分类2值 + $chartdata['series'][] = ['name' => $chartdata['legend'][1], 'type' => 'bar', 'itemStyle' => $series2, 'data' => $data['now']['price']];//分类1值 + $chartdata['series'][] = ['name' => $chartdata['legend'][2], 'type' => 'line', 'itemStyle' => $series3, 'data' => $data['pre']['count'], 'yAxisIndex' => 1];//分类2值 + $chartdata['series'][] = ['name' => $chartdata['legend'][3], 'type' => 'line', 'itemStyle' => $series4, 'data' => $data['now']['count'], 'yAxisIndex' => 1];//分类2值 //统计总数上期 $pre_total = $this->dao->preTotalFind($datebefor, $dateafter); diff --git a/crmeb/app/services/product/product/StoreCategoryServices.php b/crmeb/app/services/product/product/StoreCategoryServices.php index d7bde1e0c..82c3d88a2 100644 --- a/crmeb/app/services/product/product/StoreCategoryServices.php +++ b/crmeb/app/services/product/product/StoreCategoryServices.php @@ -118,7 +118,6 @@ class StoreCategoryServices extends BaseServices throw new AdminException(100005); } else { $this->cacheDriver()->clear(); - $this->cacheDriver()->set('category_version', uniqid()); } } @@ -206,7 +205,6 @@ class StoreCategoryServices extends BaseServices if (!$res) throw new AdminException(100006); $this->cacheDriver()->clear(); - $this->cacheDriver()->set('category_version', uniqid()); return (int)$res->id; } @@ -246,7 +244,6 @@ class StoreCategoryServices extends BaseServices }); $this->cacheDriver()->clear(); - $this->cacheDriver()->set('category_version', uniqid()); } /** @@ -262,7 +259,6 @@ class StoreCategoryServices extends BaseServices if (!$res) throw new AdminException(100008); $this->cacheDriver()->clear(); - $this->cacheDriver()->set('category_version', uniqid()); } /** diff --git a/crmeb/app/services/user/UserAuthServices.php b/crmeb/app/services/user/UserAuthServices.php index b864e2fb9..7e1b1db82 100644 --- a/crmeb/app/services/user/UserAuthServices.php +++ b/crmeb/app/services/user/UserAuthServices.php @@ -50,7 +50,7 @@ class UserAuthServices extends BaseServices if ($token === 'undefined') { throw new AuthException(110002); } - if (!$token || !$tokenData = CacheService::get($md5Token, '', NULL, 'api')) + if (!$token || !$tokenData = CacheService::get($md5Token)) throw new AuthException(110002); if (!is_array($tokenData) || empty($tokenData) || !isset($tokenData['uid'])) { diff --git a/crmeb/app/services/wechat/WechatQrcodeServices.php b/crmeb/app/services/wechat/WechatQrcodeServices.php index 2cf187f4d..8e3db0072 100644 --- a/crmeb/app/services/wechat/WechatQrcodeServices.php +++ b/crmeb/app/services/wechat/WechatQrcodeServices.php @@ -49,6 +49,7 @@ class WechatQrcodeServices extends BaseServices $item['stop'] = $item['end_time'] ? $item['end_time'] > time() ? 1 : -1 : 0; $item['label_name'] = $userLabel->getColumn([['id', 'in', $item['label_id']]], 'label_name'); $item['end_time'] = date('Y-m-d H:i:s', $item['end_time']); + $item['add_time'] = date('Y-m-d H:i:s', $item['add_time']); } $count = $this->dao->count($where); return compact('list', 'count'); diff --git a/crmeb/public/install/crmeb.sql b/crmeb/public/install/crmeb.sql index a8a6ace13..589cd1782 100755 --- a/crmeb/public/install/crmeb.sql +++ b/crmeb/public/install/crmeb.sql @@ -26520,7 +26520,17 @@ INSERT INTO `eb_lang_code` (`id`, `type_id`, `code`, `remarks`, `lang_explain`, (24977, 7, '500028', '请填写邀请码', '초대 코드를 입력하십시오.', 1), (24978, 8, '500028', '请填写邀请码', 'Урилгын кодыг бөглөнө үү', 1), (24979, 9, '500028', '请填写邀请码', 'กรุณากรอกรหัสเชิญ', 1), -(24980, 10, '500028', '请填写邀请码', 'Vui lòng điền mã mời', 1); +(24980, 10, '500028', '请填写邀请码', 'Vui lòng điền mã mời', 1), +(24981, 1, '500029', '金额最多两位小数', '金额最多两位小数', 1), +(24982, 2, '500029', '金额最多两位小数', 'Amount Up to two decimal places', 1), +(24983, 3, '500029', '金额最多两位小数', '金額最多兩位小數', 1), +(24984, 4, '500029', '金额最多两位小数', 'Montant Jusquà deux décimales', 1), +(24985, 5, '500029', '金额最多两位小数', 'Importo Fino a due decimali', 1), +(24986, 6, '500029', '金额最多两位小数', '金額は小数点以下2桁まで', 1), +(24987, 7, '500029', '金额最多两位小数', '양 소수점 이하 두 자리까지', 1), +(24988, 8, '500029', '金额最多两位小数', 'Хэмжээ Хоёр аравтын бутархай газар хүртэл', 1), +(24989, 9, '500029', '金额最多两位小数', 'จำนวนทศนิยมสูงสุดสองตำแหน่ง', 1), +(24990, 10, '500029', '金额最多两位小数', 'Số tiền tối đa hai chữ số thập phân', 1); -- --------------------------------------------------------