fix:修复微信公众号分享时,缺少 updateAppMessageShareData 导致 url 无法设置
parent
08fa88129e
commit
1b936a3988
|
|
@ -14,9 +14,9 @@
|
||||||
>
|
>
|
||||||
<template #rightBottom>
|
<template #rightBottom>
|
||||||
<view class="ss-flex ss-row-between">
|
<view class="ss-flex ss-row-between">
|
||||||
<view class="commission-num" v-if="item.brokerageMinPrice === undefined"
|
<view class="commission-num" v-if="item.brokerageMinPrice === undefined">
|
||||||
>预计佣金:计算中</view
|
预计佣金:计算中
|
||||||
>
|
</view>
|
||||||
<view
|
<view
|
||||||
class="commission-num"
|
class="commission-num"
|
||||||
v-else-if="item.brokerageMinPrice === item.brokerageMaxPrice"
|
v-else-if="item.brokerageMinPrice === item.brokerageMaxPrice"
|
||||||
|
|
|
||||||
|
|
@ -30,7 +30,7 @@ export default {
|
||||||
}
|
}
|
||||||
|
|
||||||
// 调用后端接口,获得 JSSDK 初始化所需的签名
|
// 调用后端接口,获得 JSSDK 初始化所需的签名
|
||||||
const url = location.href.split('#')[0];
|
const url = location.origin;
|
||||||
const { code, data } = await AuthUtil.createWeixinMpJsapiSignature(url);
|
const { code, data } = await AuthUtil.createWeixinMpJsapiSignature(url);
|
||||||
if (code === 0) {
|
if (code === 0) {
|
||||||
jweixin.config({
|
jweixin.config({
|
||||||
|
|
@ -43,6 +43,7 @@ export default {
|
||||||
'chooseWXPay',
|
'chooseWXPay',
|
||||||
'openLocation',
|
'openLocation',
|
||||||
'getLocation',
|
'getLocation',
|
||||||
|
'updateAppMessageShareData',
|
||||||
'updateTimelineShareData',
|
'updateTimelineShareData',
|
||||||
'scanQRCode',
|
'scanQRCode',
|
||||||
], // TODO 芋艿:后续可以设置更多权限;
|
], // TODO 芋艿:后续可以设置更多权限;
|
||||||
|
|
@ -55,13 +56,11 @@ export default {
|
||||||
// 监听结果
|
// 监听结果
|
||||||
configSuccess = true;
|
configSuccess = true;
|
||||||
jweixin.error((err) => {
|
jweixin.error((err) => {
|
||||||
debugger;
|
|
||||||
configSuccess = false;
|
configSuccess = false;
|
||||||
console.error('微信 JSSDK 初始化失败', err);
|
console.error('微信 JSSDK 初始化失败', err);
|
||||||
// $helper.toast('微信JSSDK:' + err.errMsg);
|
$helper.toast('微信JSSDK:' + err.errMsg);
|
||||||
});
|
});
|
||||||
jweixin.ready(() => {
|
jweixin.ready(() => {
|
||||||
debugger;
|
|
||||||
if (configSuccess) {
|
if (configSuccess) {
|
||||||
console.log('微信 JSSDK 初始化成功');
|
console.log('微信 JSSDK 初始化成功');
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue