Commit 24ac8405 by 张立顺

Merge branch 'develop' of 192.168.3.233:saas_plus/business-assistant into develop

2 parents b796e92a f4410bf1
......@@ -91,7 +91,7 @@ Page({
onRoute(options) {
// console.log("options: ", options);
//选中场景的index,和产品的index
let { actNum, activeNavIdx, apiData } = options;
let { actNum, activeNavIdx, apiData} = options;
this.setData({
actNum,
activeNavIdx,
......@@ -100,7 +100,7 @@ Page({
});
let apiDataJson = JSON.stringify(apiData)
let item = apiData[actNum]?.productList[activeNavIdx];
this.shareQuery = `sceneCode=${apiData[actNum].sceneCode}&productCode=${item?.productCode}&productDesc=${item?.productName}&category=${item?.category}&actNum=${actNum}&activeNavIdx=${activeNavIdx}&apiData=${apiDataJson}`;
this.shareQuery = `sceneCode=${apiData[actNum].sceneCode}&productCode=${item?.productCode}&isShare=${true}&productDesc=${item?.productName}&category=${item?.category}&actNum=${actNum}&activeNavIdx=${activeNavIdx}&apiData=${apiDataJson}`;
this.shareTrackData = {
sceneCode: apiData[actNum]?.sceneCode,
productCode: item?.productCode,
......@@ -256,9 +256,11 @@ Page({
* 生命周期函数--监听页面加载 ()
*/
onLoad(options) {
console.log('options: ', options);
// actNum,activeNavIdx isShare
// 扫码进来
let { actNum, activeNavIdx, isShare, merchantId } = options;
console.log('isShare: ', isShare);
if (merchantId) {
this.setData({
isShow: false,
......@@ -276,7 +278,7 @@ Page({
// 发请求
let senceItem = senceData[actNum];
let item = senceData[actNum]?.productList[activeNavIdx];
this.shareQuery = `sceneCode=${senceItem?.sceneCode}&productCode=${item?.productCode}&productDesc=${item?.productName}&category=${item?.category}&actNum=${actNum}&activeNavIdx=${activeNavIdx}`;
this.shareQuery = `sceneCode=${senceItem?.sceneCode}&productCode=${item?.productCode}&isShare=${isShare}&productDesc=${item?.productName}&category=${item?.category}&actNum=${actNum}&activeNavIdx=${activeNavIdx}`;
this.shareTrackData = {
sceneCode: senceItem?.sceneCode,
productCode: item?.productCode,
......
......@@ -114,9 +114,9 @@ class Share {
const {
WXUSERINFO,
USERINFO
} = this.getCommonData()
query = `${query? `?${query}&`:'?'}merchantId=${USERINFO.merchantId}&shareOpenId=${WXUSERINFO.openId}`
if (USERINFO.phone) query += `&sharePhone=${USERINFO.phone}`
} = this.getCommonData(),
thisPage = wx.$router.getPageInstance()
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!