|
@ -25,8 +25,9 @@ export const myMixins ={ |
|
|
const pages = getCurrentPages(); // 获取加载的页面
|
|
|
const pages = getCurrentPages(); // 获取加载的页面
|
|
|
const view = pages[pages.length - 1]; // 获取当前页面的对象
|
|
|
const view = pages[pages.length - 1]; // 获取当前页面的对象
|
|
|
let url = ''; |
|
|
let url = ''; |
|
|
if (view.options.url) { |
|
|
console.log(view) |
|
|
url = view.options.url; |
|
|
if (view.$page.fullPath) { |
|
|
|
|
|
url = view.options.fullPath; |
|
|
} else { |
|
|
} else { |
|
|
url = uni.getStorageSync('webUrl'); |
|
|
url = uni.getStorageSync('webUrl'); |
|
|
} |
|
|
} |
|
@ -34,7 +35,7 @@ export const myMixins ={ |
|
|
console.log(111,url,`${view.route}?url=${url}`) |
|
|
console.log(111,url,`${view.route}?url=${url}`) |
|
|
return { |
|
|
return { |
|
|
title: '时味苏州', // 分享的名称
|
|
|
title: '时味苏州', // 分享的名称
|
|
|
path: `${view.route}?url=${url}`, // 将 url 作为参数传递
|
|
|
path: `${view.$page.fullPath}`, |
|
|
imageUrl: "https://static.ticket.sz-trip.com/uploads/20250818/5ea2c18a15db8a438f2ce642194b6051.jpg", |
|
|
imageUrl: "https://static.ticket.sz-trip.com/uploads/20250818/5ea2c18a15db8a438f2ce642194b6051.jpg", |
|
|
mpId: 'wx699ed131345cf8dd' // 此处配置微信小程序的 AppId
|
|
|
mpId: 'wx699ed131345cf8dd' // 此处配置微信小程序的 AppId
|
|
|
}; |
|
|
}; |
|
|