OA获取信息-手机系统变更消息推送

master
Your Name 5 years ago
parent b2cecb6396
commit aa32624641

@ -1104,6 +1104,22 @@ class UserModel extends Model{
$data['fgame_id']=$game_id; $data['fgame_id']=$game_id;
$data['fgame_name']=$game_name; $data['fgame_name']=$game_name;
$model->save($data); $model->save($data);
$device_type = M('User','tab_')->where(['id' => $user['id']])->getField('device_type');
if(empty($device_type)){
$gameServer = substr($game_name, -10, 9);
if($gameServer == '安卓版'){
$arr['device_type'] = 'Android';
} elseif($gameServer == '苹果版') {
$arr['device_type'] = 'IOS';
}
$arr['time'] = time();
$arr['account'] = $account;
ksort($arr);
reset($arr);
$sign = md5(http_build_query($arr) . C('GET_INFO_KEY'));
$arr['sign'] = $sign;
$reData = curl_post('http://oa.76ba.com/api/wanmeng/deviceTypeUpdate',$arr);
}
} }
return $data["token"]; return $data["token"];
} }

Loading…
Cancel
Save