Commit b83df1bb authored by zjz1994's avatar zjz1994

deviceid获取

parent b39a8014
......@@ -12,6 +12,7 @@ import onNotSuccess from '../../new_wx/onNotSuccess';
import { showToast } from '../../new_wx/ctrls/toastCtrl';
import SAUP_sendLogData from '../../../src/SAUP_sendLogData';
import SAMap from '../../../src/SAMap';
import { GFun } from '../../tc/util/GFun';
// import { IExposureData } from '..';
......@@ -1461,23 +1462,42 @@ export class NetManager extends ABNetManager {
}
public hc_advert(callback: Function): void {
if(window['SNNativeClient']){
console.log("苏宁原生测试");
console.log(window['SNNativeClient']);
console.log('测试deviceid',window['SNNativeClient'].getNewDeviceIdentifier())
}
var deviceid:string = '';
const net: INetData = {
name: 'hc_advert',
uri: window['duiba'] + '/customActivity/happyclear/advert',
type: 'get',
dataType: 'json',
param: {
activityId: DataManager.ins.customCfgData.actId
activityId: DataManager.ins.customCfgData.actId,
deviceid:deviceid
},
hideMsg: true,
callback: callback
};
try{
if(window['SNNativeClient']){
console.log("苏宁原生测试",GFun.isIOS);
console.log(window['SNNativeClient']);
window['SNNativeClient'].getClientInfo(function(res){
console.log("啦啦啦SNNativeClientFunc",res);
if(res){
if(GFun.isIOS){
deviceid = res.imsi||'';
}else{
deviceid = res.imei||'';
}
}
console.log('新增deviceid',deviceid);
net.param.deviceid = deviceid;
this.send(net);
}.bind(this));
}else{
this.send(net);
}
}catch(e){
this.send(net);
}
}
public doSign(callback: Function, signActivityId: number): void {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment