更新vivo版本

This commit is contained in:
zhl 2021-01-18 21:01:24 +08:00
parent f410b0d9dc
commit 7475caaff6
2 changed files with 23 additions and 8 deletions

View File

@ -6,8 +6,8 @@ android {
applicationId "com.hnjc.wjtx.vivo" applicationId "com.hnjc.wjtx.vivo"
minSdkVersion 18 minSdkVersion 18
targetSdkVersion 28 targetSdkVersion 28
versionCode 3 versionCode 4
versionName "1.0.3" versionName "1.0.4"
ndk { ndk {
abiFilters 'armeabi-v7a' abiFilters 'armeabi-v7a'
} }

View File

@ -12,13 +12,16 @@ class GamePlatform {
this.jcGameId = 1009; this.jcGameId = 1009;
this.jcChannelId = getQueryString('channel') ? Number(getQueryString('channel')) : 7103; this.jcChannelId = getQueryString('channel') ? Number(getQueryString('channel')) : 7103;
console.log('jcchannelid: ' + this.jcChannelId); console.log('jcchannelid: ' + this.jcChannelId);
this.isDev = true; this.isDev = false;
this.orderIdUrl = `https://game1009proxy${this.isDev ? '-test':''}.kingsome.cn/webapp/index.php?c=Pay&a=preOrder`; this.orderIdUrl = `https://game1009proxy${this.isDev ? '-test':''}.kingsome.cn/webapp/index.php?c=Pay&a=preOrder`;
this.checkRegRewardUrl = `https://game1009proxy${this.isDev ? '-test':''}.kingsome.cn/webapp/index.php?c=GoProxy&a=checkRegisterReward`; this.checkRegRewardUrl = `https://game1009proxy${this.isDev ? '-test':''}.kingsome.cn/webapp/index.php?c=GoProxy&a=checkRegisterReward`;
this.regRewardUrl = `https://game1009proxy${this.isDev ? '-test':''}.kingsome.cn/webapp/index.php?c=GoProxy&a=registerReward`; this.regRewardUrl = `https://game1009proxy${this.isDev ? '-test':''}.kingsome.cn/webapp/index.php?c=GoProxy&a=registerReward`;
this.svrListUrl = `https://game1009gate${this.isDev ? '-test':''}.kingsome.cn/wjtxgate/common/login.aspx?pid=${this.jcChannelId}`; this.svrListUrl = `https://game1009gate${this.isDev ? '-test':''}.kingsome.cn/wjtxgate/common/login.aspx?pid=${this.jcChannelId}`;
this.wssHost = `game1009game${this.isDev ? '-test' : ''}.kingsome.cn`; this.wssHost = `game1009game${this.isDev ? '-test' : ''}.kingsome.cn`;
this.other = new GamePlatformOther(); this.other = new GamePlatformOther();
if (this.jcChannelId === 8004) {
this.quickChannelId = 8004;
}
} }
login() { login() {
return new Promise((resolve, reject) => { return new Promise((resolve, reject) => {
@ -36,6 +39,7 @@ class GamePlatform {
wxUserData.avatar_url = res.avatar_url; wxUserData.avatar_url = res.avatar_url;
wxUserData.gender = res.sex; wxUserData.gender = res.sex;
platform.code = res.openid; platform.code = res.openid;
platform.jcChannelId = res.channel;
//res.session_key //res.session_key
platform.session = res.session_id; platform.session = res.session_id;
resolve(res); resolve(res);
@ -77,6 +81,9 @@ class GamePlatform {
role_level: giant.Core.hero.level, role_level: giant.Core.hero.level,
server_name: giant.Core.serverVO.name server_name: giant.Core.serverVO.name
}; };
if (platform.quickChannelId) {
reqData.poly_sdk_channel = platform.quickChannelId;
}
var loginCount = 0; var loginCount = 0;
var loginMaxCount = 1; var loginMaxCount = 1;
@ -130,7 +137,14 @@ class GamePlatform {
if (isOk) { if (isOk) {
try { try {
var payData = JSON.parse(data); var payData = JSON.parse(data);
orderInfo = {orderId: payData.orderid, productCode: payData.goodid, count: 1}; Object.assign(payData, {
count: 1,
vipLevel: giant.Core.hero.vipLevel,
camp: giant.Core.hero.camp,
diamond: giant.Core.hero.diamond,
roleCreateTime: giant.Core.hero.ctime,
});
orderInfo = payData;
realPay(); realPay();
} catch (err) { } catch (err) {
obj.fail && obj.fail({ tipMessage: '解析接口数据失败' }); obj.fail && obj.fail({ tipMessage: '解析接口数据失败' });
@ -380,19 +394,20 @@ class GamePlatformOther {
reportRoleCreate(isNew) { reportRoleCreate(isNew) {
let data = { let data = {
isCreateRole: isNew, isCreateRole: isNew || false,
roleCreateTime: Date.now(), roleCreateTime: giant.Core.hero.ctime,
serverId: giant.Core.serverVO.id, serverId: giant.Core.serverVO.id,
serverName: giant.Core.serverVO.name, serverName: giant.Core.serverVO.name,
userRoleId: giant.Core.hero.id, userRoleId: giant.Core.hero.id,
userRoleName: giant.Core.hero.name, userRoleName: giant.Core.hero.name,
userRoleBalance: giant.Core.hero.coin, userRoleBalance: giant.Core.hero.diamond,
vipLevel: giant.Core.hero.vipLevel, vipLevel: giant.Core.hero.vipLevel,
userRoleLevel: giant.Core.hero.level, userRoleLevel: giant.Core.hero.level,
partyId: 0, partyId: giant.Core.guildId || 0,
partyName: giant.Core.hero.camp, partyName: giant.Core.hero.camp,
gameRoleGender: giant.Core.hero.gender, gameRoleGender: giant.Core.hero.gender,
gameRolePower: giant.Core.hero.power, gameRolePower: giant.Core.hero.power,
job: giant.Core.hero.job,
}; };
jc.plat.reportRoleInfo(data) jc.plat.reportRoleInfo(data)
.then(res => {}) .then(res => {})