Commit d0b067e9 by 李伟康

小程序码增加参数

1 parent c5341aae
......@@ -257,18 +257,27 @@ Page({
async download() {
let { actNum, activeNavIdx, imgHeightArr ,imgPath} = this.data;
const { appId } = wx.getAccountInfoSync().miniProgram
let { userInfo } = wx.$storage.get()
let { userInfo } = wx.$storage.get(),
wx_user_info = wx.$storage.get('wx_user_info'),
senceItem = senceData[actNum], item = senceData[actNum]?.productList[activeNavIdx];
// let wx_user_info = wx.$storage.get("wx_user_info");
// console.log('wx_user_info: ', wx_user_info.appId);
wx.showLoading({
title: "海报生成中...",
});
console.log(wx_user_info)
let params = {
actNum,
activeNavIdx,
isShare: true,
merchantId:userInfo.merchantId || '',
shareOpenId: wx_user_info.openId || '',
sharePhone: userInfo.phone || '',
sceneCode: senceItem?.sceneCode || '',
productCode: item?.productCode || '',
productDesc: item?.productName || '',
category: item?.category || ''
};
// console.log(' wx_user_info.appId', wx_user_info)
let res = await createQrCodeApi({
appId: appId,
......@@ -419,7 +428,9 @@ Page({
});
let ercodeParams = await this.analysisQRcode(options.scene);
options = JSON.parse(ercodeParams.scene)
this.options = options
console.log('====================',this.options)
this.onLoad(null)
}
let {senceData} = this.data
// 扫码进来
......
......@@ -116,7 +116,7 @@ class Share {
USERINFO
} = this.getCommonData(),
thisPage = wx.$router.getPageInstance().options
query = `${query? `?${query}&`:'?'}merchantId=${thisPage.merchantId ||USERINFO.merchantId || ''}&shareOpenId=${thisPage.shareOpenId || WXUSERINFO.openId || ''}&sharePhone=${thisPage.sharePhone || USERINFO.phone || ''}`
query = `${query? `?${query}&`:'?'}merchantId=${thisPage.merchantId || USERINFO.merchantId || ''}&shareOpenId=${thisPage.shareOpenId || WXUSERINFO.openId || ''}&sharePhone=${thisPage.sharePhone || USERINFO.phone || ''}`
return query
}
reportShareData(shareTrackData) {
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!