|
|
|
@ -1051,7 +1051,7 @@ class UserModel extends Model{
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
public function login_sdk($account,$password,$type=1,$game_id,$game_name,$sdk_version){
|
|
|
|
|
public function login_sdk($account,$password,$type=1,$game_id,$game_name,$sdk_version){
|
|
|
|
|
$map['account'] = $account;
|
|
|
|
|
/* 获取用户数据 */
|
|
|
|
|
$user = $this->where($map)->find();
|
|
|
|
@ -1077,6 +1077,7 @@ class UserModel extends Model{
|
|
|
|
|
$data["login_time"] = NOW_TIME;
|
|
|
|
|
$data["login_ip"] = get_client_ip();
|
|
|
|
|
$data["token"] = $this->generateToken($uid,$account,$password);
|
|
|
|
|
$data["user_token"] = $this->generateToken($uid,$account,$password);
|
|
|
|
|
if($user_fgame_id){
|
|
|
|
|
$model->save($data);
|
|
|
|
|
}else{
|
|
|
|
|