|
@@ -30,10 +30,6 @@ export async function getSdkSign (url: string) {
|
|
}
|
|
}
|
|
|
|
|
|
/* 微信自定义分享封装函数 */
|
|
/* 微信自定义分享封装函数 */
|
|
-/**
|
|
|
|
- * url:获取微信分享签名的url地址
|
|
|
|
- * isShare:当前所在路径是否需要分享
|
|
|
|
- * */
|
|
|
|
export async function weChatShare (options: any) {
|
|
export async function weChatShare (options: any) {
|
|
if (!inWeiXinBrowser) return
|
|
if (!inWeiXinBrowser) return
|
|
|
|
|
|
@@ -41,8 +37,7 @@ export async function weChatShare (options: any) {
|
|
// 获取并注册sdkSign
|
|
// 获取并注册sdkSign
|
|
let url = location.href.split('#')[0]
|
|
let url = location.href.split('#')[0]
|
|
if (device === 'ios') {
|
|
if (device === 'ios') {
|
|
- url = (Vue as any).$firstUrl
|
|
|
|
- console.log(url)
|
|
|
|
|
|
+ url = (Vue as any).prototype.$firstUrl
|
|
}
|
|
}
|
|
const wxSdk: any = await getSdkSign(url)
|
|
const wxSdk: any = await getSdkSign(url)
|
|
Vue.prototype.$wxSdk = wxSdk
|
|
Vue.prototype.$wxSdk = wxSdk
|