作者 王晓刚
1 个管道 的构建 通过 耗费 1 秒

我的分享

... ... @@ -36,6 +36,8 @@ class Server extends WechatBase
dump(cache('user_data'));
dump(cache('userId'));
dump(cache('row'));
dump(cache('a'));
dump(cache('b'));
}
public function responseMsg()
{
... ... @@ -125,6 +127,7 @@ class Server extends WechatBase
public function new_user($wechat_user,$openid,$appId,$share_id) {
$currentTime = time();
$ip = $this->request->ip(0, true);
cache('a',"a");
$userId = Db::name("user")->insertGetId([
'status' => 'normal',
'gender' => $wechat_user['original']['sex'],
... ... @@ -140,7 +143,7 @@ class Server extends WechatBase
'parent_id' => $share_id,
]);
cache('userId',$userId);
cache('b',"b");
$row=Db::name("third")->insert([
'openid' => $openid,
'user_id' => $userId,
... ...