Browse Source

2024年2月22日11:33:24

yxb
wq 1 year ago
parent
commit
6d17519456

+ 0
- 5
pages/bluetooth/bluetooth.vue View File

@@ -530,11 +530,6 @@
url: "/subpackage/after-sale/activation/activate",
});
} else if (routeType.value == "2") {
// #ifdef MP-ALIPAY
// uni.navigateTo({
// url: `/pages/recharge/recharge?connectSuccess=1&&cardId=${state.cardId}&&fee=${state.fee}`,
// });
// #endif
uni.navigateTo({
url: `/pages/recharge/recharge-weixin?connectSuccess=${state.connectSuccess}`,
});

+ 4
- 3
pages/recharge/recharge-weixin.vue View File

@@ -157,7 +157,7 @@
version: "",
type: "",
favourable: "",
money: undefined,
money: 0,
v_userType: "",
});
onLoad((option) => {
@@ -184,11 +184,13 @@
/*读卡*/
getCardId(1);
} else {
//进行真实圈层检测
quanCheckActionTrue().then((val : any) => {
console.log("圈层检测val", val)
//如果 圈层检测正常
if (val.chargeStatus === 1) {
console.log(`进行充值检测`);
//充值检测
czCheckAction().then((checkResult : any) => {
//判断订单逻辑如果有订单充值 则直接拿到订单去链接蓝牙
if (checkResult.orders && checkResult.orders.length > 0) {
@@ -330,7 +332,7 @@
};

/*读卡*/
const getCardId = (readCard) => {
const getCardId = (readCard: number) => {
console.log("======获取卡信息======");
let cmdArr = [
cmd.HOME_DIRECTORY,
@@ -849,7 +851,6 @@
console.log('my.getAuthCode 调用失败', err)
}
});

// #endif
};


+ 11
- 9
pages/recharge/recharge.vue View File

@@ -513,7 +513,7 @@
reject(error);
});
};
const quanCheckActionTrue = () => {
const quanCheckActionTrue = async () => {
console.log("进行真实圈层检测");
var data = {
cardId: card.cardId,
@@ -527,13 +527,15 @@
method: "POST",
showLoading: true,
};
return new Promise(async (resolve, reject) => {
const res = await request(quanCheck, options);
const data = stringToJson(res.bizContent);
resolve(data);
}).catch((error) => {
reject(error);
});
try {
return await new Promise(async (resolve) => {
const res = await request(quanCheck, options);
const data_1 = stringToJson(res.bizContent);
resolve(data_1);
});
} catch (error) {
console.log('输出内容', error);
}
};
/*充值消费*/
@@ -825,7 +827,7 @@
checkOrder();
},
fail: res => {
confirm(res, () => {}, "支付失败", false);
confirm(res, () => { }, "支付失败", false);
},
});

+ 1
- 0
static/etcUtil/index.js View File

@@ -203,6 +203,7 @@ function transCmd(cmdArr, type, func, callBack = null) {
break;
case "JT":
jtApi.transCmd(cmdArr, type, function(res) {
console.log('指令执行结果:',res)
if (res.code == 0) {
func(res.data);
} else {

Loading…
Cancel
Save