|
@@ -175,14 +175,20 @@ class UsersV2Controller extends Controller
|
|
}
|
|
}
|
|
|
|
|
|
private function createUser($openid,$unionid,$distribution_channel_id,$send_order_id,$ip){
|
|
private function createUser($openid,$unionid,$distribution_channel_id,$send_order_id,$ip){
|
|
- $user = UserService::addUser(
|
|
|
|
- ['openid' => $openid,
|
|
|
|
- 'unionid' => $unionid,
|
|
|
|
- 'distribution_channel_id' =>$distribution_channel_id,
|
|
|
|
- 'send_order_id'=>$send_order_id,
|
|
|
|
- 'is_new'=>1,
|
|
|
|
- 'register_ip'=>$ip
|
|
|
|
- ]);
|
|
|
|
|
|
+ $user = null;
|
|
|
|
+ try{
|
|
|
|
+ $user = UserService::addUser(
|
|
|
|
+ ['openid' => $openid,
|
|
|
|
+ 'unionid' => $unionid,
|
|
|
|
+ 'distribution_channel_id' =>$distribution_channel_id,
|
|
|
|
+ 'send_order_id'=>$send_order_id,
|
|
|
|
+ 'is_new'=>1,
|
|
|
|
+ 'register_ip'=>$ip
|
|
|
|
+ ]);
|
|
|
|
+ }catch (\Exception $e){
|
|
|
|
+ myLog('user-error')->info($e);
|
|
|
|
+ }
|
|
|
|
+
|
|
// 注册动作
|
|
// 注册动作
|
|
$action_type = 'Register';
|
|
$action_type = 'Register';
|
|
$param = [
|
|
$param = [
|