Commit 69657c0e by 赵雅纹

Merge branch 'feature-zyw-sc' into 'dev_7.1.0'

Feature zyw sc

See merge request !120
parents 0c2bad3b b98b5dd9
......@@ -98,7 +98,7 @@ Component({
else if (rowObj.type == 7) { }
else if (rowObj.type == 8) {
// 商品
wxService.router(`/pages/productDetail/productDetail?productId=${currentClickRow}`)
wxService.router(`/pages/productDetail/productDetail?id=${currentClickRow}`)
}
else if (rowObj.type == 9) {
// 分类
......
......@@ -138,7 +138,7 @@ Component({
else if (rowObj.type == 7) { }
else if (rowObj.type == 8) {
// 商品
wxService.router(`/pages/productDetail/productDetail?productId=${currentClickRow}`)
wxService.router(`/pages/productDetail/productDetail?id=${currentClickRow}`)
}
else if (rowObj.type == 9) {
// 分类
......
......@@ -113,7 +113,7 @@ Component({
else if (rowObj.type == 7) { }
else if (rowObj.type == 8) {
// 商品
wxService.router(`/pages/productDetail/productDetail?productId=${currentClickRow}`)
wxService.router(`/pages/productDetail/productDetail?id=${currentClickRow}`)
}
else if (rowObj.type == 9) {
// 分类
......
......@@ -132,7 +132,7 @@ Component({
else if (rowObj.type == 7) { }
else if (rowObj.type == 8) {
// 商品
wxService.router(`/pages/productDetail/productDetail?productId=${currentClickRow}`)
wxService.router(`/pages/productDetail/productDetail?id=${currentClickRow}`)
}
else if (rowObj.type == 9) {
// 分类
......
......@@ -346,7 +346,8 @@ wxService.page({
console.log('id', this.data.currentShareContent.id)
console.log(path)
return {
path: path
path: path,
imageUrl: this.data.proData[0].productImgUrl, // 可以更换分享的图片
}
}
......
......@@ -4,7 +4,7 @@ const wxService = require('../../utils/wxService')
const utils = require('../../utils/util')
const envInfo = require('../../config/index').envInfo
import { Integer } from '../../utils/integerDigitalConvertion'
const { memberId } = wx.getStorageSync('_baseUserInfo')
const { memberId, member} = wx.getStorageSync('_baseUserInfo')
wxService.page({
/**
......@@ -49,16 +49,28 @@ wxService.page({
* 生命周期函数--监听页面显示
*/
onShow() {
let time = Date.parse(new Date())
if (member.premiumExpireTime && member.premiumExpireTime > time) {
this.setData({
plus: 1
})
} else {
this.setData({
plus: 0
})
}
this.getCategoryList()
this.getContentPermission()
this.data.currentShareContent = null;
},
// 发布内容权限
getContentPermission() {
console.log(member)
wxService.post(`/merchant/contentMobileTerminal/getReleasePermissions`, {
userId: memberId,
plus: 0,
level: 0
plus: this.data.plus,
level: member.level || 0
}).then(res => {
if (!res) return false
const { result, data } = res.data
......@@ -215,7 +227,8 @@ wxService.page({
var path = 'pages/wantToBuyDetail/wantToBuyDetail?i=' + id + '&t=' + tentacleId;
console.log(path)
return {
path: path
path: path,
imageUrl: this.data.cardUrl, // 可以更换分享的图片
}
}
......
......@@ -280,7 +280,8 @@ wxService.page({
var path = 'pages/productDetail/productDetail?i=' + id + '&t=' + tentacleId;
console.log(path)
return {
path: path
path: path,
imageUrl: this.data.productInfo.indexUrl, // 可以更换分享的图片
}
}
})
\ No newline at end of file
......@@ -35,7 +35,8 @@ wxService.page({
/**
* 生命周期函数--监听页面加载
*/
onLoad() {
onLoad(options) {
console.log('触点-----------',options)
this.setData(
{
pages: [],
......@@ -73,8 +74,11 @@ wxService.page({
* 生命周期函数--监听页面显示
*/
onShow() {
let tentacleInfo = wx.getStorageSync('TENTACLE_CONTENT');
// 取会员卡号
const baseUserInfo = wx.getStorageSync('_baseUserInfo')
const baseUserInfo = wx.getStorageSync('tentacleInfo')
console.log('会员信息------------', baseUserInfo)
const cardMember = wx.getStorageSync('_cardMember')
// 登录接口返回err
const reLoginErrFlag = wx.getStorageSync('reLoginErr')
......@@ -269,7 +273,9 @@ wxService.page({
wxService.getTentacleContent(tentacleInfo).then(res => {
if (res && res.tentacleId) {
let tentacleId = Integer.digit(res.tentacleId, 10, 64);
var path = `pages/userCenter/userCenter?t=${tentacleId}`;
// var path = `pages/userCenter/userCenter?t=${tentacleId}`;
var path = `pages/userCenter/userCenter?t=1`;
console.log(path)
return {
path: path
......
......@@ -90,7 +90,7 @@ wxService.page({
this.setData({
showCardModal: true,
cardTitle: this.data.contentInfo.headline,
cardUrl: this.data.contentInfo.url,
cardUrl: this.data.contentInfo.shareShowPictureRESDTOList[0].url,
pagePath: path
});
}
......@@ -184,7 +184,8 @@ wxService.page({
let tentacleId = Integer.digit(this.data.currentShareContent.tentacleId, 10, 64);
var path = 'pages/wantToBuyDetail/wantToBuyDetail?i=' + id + '&t=' + tentacleId;
return {
path: path
path: path,
imageUrl: this.data.cardUrl, // 可以更换分享的图片
}
}
......@@ -192,7 +193,7 @@ wxService.page({
title: this.data.contentInfo.headline,
id: this.data.contentInfo.id,
article: this.data.contentInfo.article,
url: this.data.contentInfo.url
url: this.data.contentInfo.shareShowPictureRESDTOList[0].url
}
let tentacleInfo = {
content: JSON.stringify(content),
......@@ -208,7 +209,8 @@ wxService.page({
let tentacleId = Integer.digit(res.tentacleId, 10, 64);
var path = 'pages/wantToBuyDetail/wantToBuyDetail?i=' + id + '&t=' + tentacleId;
return {
path: path
path: path,
imageUrl: this.data.cardUrl, // 可以更换分享的图片
}
}
});
......
......@@ -3,7 +3,7 @@ const app = getApp()
const wxService = require('../../../../utils/wxService')
const utils = require('../../../../utils/util')
const envInfo = require('../../../../config/index').envInfo
const { memberId } = wx.getStorageSync('_baseUserInfo')
const { memberId, member } = wx.getStorageSync('_baseUserInfo')
import { Integer } from '../../../../utils/integerDigitalConvertion'
wxService.page({
......@@ -37,18 +37,29 @@ wxService.page({
* 生命周期函数--监听页面显示
*/
onShow() {
let time = Date.parse(new Date())
if (member.premiumExpireTime && member.premiumExpireTime > time) {
this.setData({
plus: 1
})
} else {
this.setData({
plus: 0
})
}
this.getBannerInfo()
this.getContentList()
this.getContentPermission()
this.data.currentShareContent = null;
},
// 发布内容权限
getContentPermission(){
wxService.post(`/merchant/contentMobileTerminal/getReleasePermissions`, {
userId: memberId,
plus: 0,
level: 0
plus:this.data.plus,
level: member.level || 0
}).then(res => {
if (!res) return false
const { result, data } = res.data
......@@ -211,7 +222,8 @@ wxService.page({
var path = 'pages/wantToBuyDetail/wantToBuyDetail?i=' + id + '&t=' + tentacleId;
console.log(path)
return {
path: path
path: path,
imageUrl: this.data.cardUrl // 可以更换分享的图片
}
}
......
......@@ -66,7 +66,7 @@ wxService.page({
this.setData({
showCardModal: true,
cardTitle: this.data.contentInfo.headline,
cardUrl: this.data.contentInfo.url,
cardUrl: this.data.contentInfo.sspList[0].url,
pagePath:path
});
}
......@@ -206,7 +206,8 @@ wxService.page({
var path = 'pages/wantToBuyDetail/wantToBuyDetail?i=' + id + '&t=' + tentacleId;
console.log(path)
return {
path: path
path: path,
imageUrl: this.data.contentInfo.sspList[0].url
}
}
......@@ -214,7 +215,7 @@ wxService.page({
title: this.data.contentInfo.headline,
id: this.data.contentInfo.id,
article: this.data.contentInfo.article,
url: this.data.contentInfo.url
url: this.data.contentInfo.sspList[0].url
}
let tentacleInfo = {
content: JSON.stringify(content),
......
......@@ -99,10 +99,11 @@ wxService.page({
}
wxService.post(`/marketing/quickMark/getAppQrCodePicture`, data).then(res => {
const { result, data } = res.data
console.log(app.globalData.imageUrl + data)
if (result == 0) {
this.setData({
// codeImg: app.globalData.imageUrl + data
codeImg: "https://hwimagecdn.ihotwind.cn/usr/201908/miniQrCode-f00c5051fef7479395efb193431762c4.jpg"
codeImg: app.globalData.imageUrl + data
// codeImg: "https://hwimagecdn.ihotwind.cn/usr/201908/miniQrCode-f00c5051fef7479395efb193431762c4.jpg"
},()=>{
this.setData({
template: new Card().palette(this.data.posterImgData[0], this.data.codeImg, member.memberWeixin.nickname, avatarUrl),
......
......@@ -44,7 +44,7 @@
bindtap="switchPoster"
>
<image class="poster-img" src="{{navItem}}" ></image>
<image class="poster-img" src="{{navItem}}" mode="aspectFit"></image>
<view class="select-plus" wx:if="{{idx == currentTab}}">
<view class="circle-radio theme-color">
<image class="tick-success" src="/assets/imgs/7_1_0/tick-success.png" mode="widthFix"></image>
......
......@@ -100,6 +100,7 @@ swiper-item{
}
.poster-img{
width: 100%;
height: 215rpx;
}
.select-plus{
position: absolute;
......
......@@ -566,7 +566,9 @@ class WXService extends Http {
_self.initAppGlobalDataSync()
//修改参数
let pageIsFromShare = false, tentacleId = null;
console.log('args', args)
args.forEach(item => {
console.log('item===',item)
if (item['t']) {
pageIsFromShare = true;
tentacleId = Integer.digit(item['t'], 64, 10);
......@@ -584,6 +586,7 @@ class WXService extends Http {
config.onLoad && config.onLoad.apply(page, args);
},
onShow: function (...args) {
console.log('________',args)
const page = this
_self.currentPage = page
config.onShow && config.onShow.apply(page, args)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment