From 55cbf96679454a9987e1c2cc57e60bf14e98f1da Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=90=B4=E6=98=8A=E5=A4=A9?= <442384644@qq.com> Date: Fri, 16 Dec 2022 16:55:35 +0800 Subject: [PATCH] =?UTF-8?q?=E3=80=90=E7=A8=8B=E5=BA=8F=E7=9B=AE=E5=BD=95?= =?UTF-8?q?=E3=80=91=E5=88=A0=E9=99=A4=E6=97=A0=E7=94=A8=E4=BB=A3=E7=A0=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- crmeb/app/adminapi/route/user.php | 2 -- .../services/message/notice/SmsService.php | 14 ---------- crmeb/app/services/user/UserServices.php | 27 ------------------- .../crmeb/services/pay/storage/WechatPay.php | 2 -- 4 files changed, 45 deletions(-) diff --git a/crmeb/app/adminapi/route/user.php b/crmeb/app/adminapi/route/user.php index 0a0116732..eac7a87b1 100644 --- a/crmeb/app/adminapi/route/user.php +++ b/crmeb/app/adminapi/route/user.php @@ -22,8 +22,6 @@ Route::group('user', function () { Route::get('user/syncUsers', 'v1.user.user/syncWechatUsers')->option(['real_name' => '同步微信用户']); //用户信息 Route::get('user/user_save_info/:uid', 'v1.user.user/userSaveInfo')->option(['real_name' => '添加编辑用户信息时候的信息']); - //用户表单头 - Route::get('user/type_header', 'v1.user.user/type_header')->option(['real_name' => '用户列表头部数据']); //赠送会员等级 Route::get('give_level/:id', 'v1.user.user/give_level')->option(['real_name' => '赠送用户等级']); //执行赠送会员等级 diff --git a/crmeb/app/services/message/notice/SmsService.php b/crmeb/app/services/message/notice/SmsService.php index 0d8d53bbb..c4a24252b 100644 --- a/crmeb/app/services/message/notice/SmsService.php +++ b/crmeb/app/services/message/notice/SmsService.php @@ -13,15 +13,12 @@ namespace app\services\message\notice; use app\jobs\notice\SmsJob; use app\jobs\TaskJob; -use app\model\system\SystemNotification; use app\services\message\NoticeService; use app\services\kefu\service\StoreServiceServices; use app\services\message\SystemNotificationServices; -use app\services\yihaotong\SmsRecordServices; use app\services\serve\ServeServices; use crmeb\exceptions\ApiException; use crmeb\services\CacheService; -use crmeb\services\sms\Sms; use think\facade\Log; @@ -109,17 +106,6 @@ class SmsService extends NoticeService $res = $smsMake->send($phone, $templateId, $data); if ($res === false) { throw new ApiException($smsMake->getError()); - } else { - /** @var SmsRecordServices $recordServices */ - $recordServices = app()->make(SmsRecordServices::class); - $recordServices->save([ - 'uid' => sys_config('sms_account'), - 'phone' => $phone, - 'content' => $res['content'] ?? '', - 'add_time' => time(), - 'template' => $res['template'] ?? '', - 'record_id' => $res['id'] ?? '' - ]); } TaskJob::dispatchDo('modifyResultCode'); return true; diff --git a/crmeb/app/services/user/UserServices.php b/crmeb/app/services/user/UserServices.php index 3a49eface..6d522b7df 100644 --- a/crmeb/app/services/user/UserServices.php +++ b/crmeb/app/services/user/UserServices.php @@ -544,33 +544,6 @@ class UserServices extends BaseServices return $data; } - /** - * 显示资源列表头部 - * @return array[] - */ - public function typeHead() - { - //全部会员 - $all = $this->getCount([]); - /** @var UserWechatuserServices $userWechatUser */ - $userWechatUser = app()->make(UserWechatuserServices::class); - //小程序会员 - $routine = $userWechatUser->getCount([['w.user_type', '=', 'routine']]); - //公众号会员 - $wechat = $userWechatUser->getCount([['w.user_type', '=', 'wechat']]); - //H5会员 - $h5 = $userWechatUser->getCount(['w.openid' => '', 'u.user_type' => 'h5']); - //pc会员 - $pc = $userWechatUser->getCount(['w.openid' => '', 'u.user_type' => 'pc']); - return [ - ['user_type' => '', 'name' => '全部会员', 'count' => $all], - ['user_type' => 'routine', 'name' => '小程序会员', 'count' => $routine], - ['user_type' => 'wechat', 'name' => '公众号会员', 'count' => $wechat], - ['user_type' => 'h5', 'name' => 'H5会员', 'count' => $h5], - ['user_type' => 'pc', 'name' => 'PC会员', 'count' => $pc], - ]; - } - /** * 会员列表 * @param array $where diff --git a/crmeb/crmeb/services/pay/storage/WechatPay.php b/crmeb/crmeb/services/pay/storage/WechatPay.php index f8ec38463..93e0195b4 100644 --- a/crmeb/crmeb/services/pay/storage/WechatPay.php +++ b/crmeb/crmeb/services/pay/storage/WechatPay.php @@ -54,10 +54,8 @@ class WechatPay extends BasePay implements PayInterface switch ($this->payType) { case Order::NATIVE: return WechatService::nativePay(null, $orderId, $totalFee, $attach, $body, $detail); - break; case Order::APP: return WechatService::appPay($options['openid'], $orderId, $totalFee, $attach, $body, $detail); - break; case Order::JSAPI: if (empty($options['openid'])) { throw new PayException('缺少openid');