فهرست منبع

Merge branch 'wx-kw' into test

zqwang 1 سال پیش
والد
کامیت
38430ea624
1فایلهای تغییر یافته به همراه5 افزوده شده و 5 حذف شده
  1. 5 5
      modules/WechatPlatform/Services/WechatCommonService.php

+ 5 - 5
modules/WechatPlatform/Services/WechatCommonService.php

@@ -92,19 +92,19 @@ class WechatCommonService extends BaseService
         return  $back;
     }
 
-    private static function updateUserActivityTime($app,$appid,$opendId)
+    private static function updateUserActivityTime($app,$appid,$openId)
     {
 
-        $info = WechatOfficialUserInfo::query()->where('mp_openid',$opendId)->where('gzh_appid',$appid)->first();
+        $info = WechatOfficialUserInfo::query()->where('mp_openid',$openId)->where('gzh_appid',$appid)->first();
         $data = [
-            'mp_openid' => $opendId,
+            'mp_openid' => $openId,
             'gzh_appid' => $appid,
             'active_at' =>  time(),
         ];
         if (is_empty($info)){
-            $user = $app->user->get();
+            $user = $app->user->get($openId);
             $data = [
-                'mp_openid' => $opendId,
+                'mp_openid' => $openId,
                 'gzh_appid' => $appid,
                 'unionid' => $user['unionid'],
                 'is_subscribe' => $user['subscribe'],