Commit 7d086788 by chenwq

膨胀金活动

1 parent c260c5ea
...@@ -29,6 +29,10 @@ Component({ ...@@ -29,6 +29,10 @@ Component({
activeUrl: { activeUrl: {
type: String, type: String,
value: '' value: ''
},
sharephone: {
type: String,
value: ''
} }
}, },
......
...@@ -36,11 +36,11 @@ ...@@ -36,11 +36,11 @@
<!-- <button class="check-act" type="default" plain="true" bindtap="checkActive">查看活动详情</button> --> <!-- <button class="check-act" type="default" plain="true" bindtap="checkActive">查看活动详情</button> -->
</block> </block>
<!-- 获取更多详情 --> <!-- 获取更多详情 -->
<block wx:if="{{ index == 2 && showLeftFlag}}"> <!-- <block wx:if="{{ index == 2 && showLeftFlag}}">
<button class="more-btn" data-index="{{index}}" bindgetphonenumber="getUserInfo" open-type="getPhoneNumber"> <button class="more-btn" data-index="{{index}}" bindgetphonenumber="getUserInfo" open-type="getPhoneNumber">
点击查看更多详情 点击查看更多详情
</button> </button>
</block> </block> -->
</image> </image>
<image webp wx:if="{{ index >= 3 && !showLeftFlag}}" webp class="img-item {{item.className?item.className:''}} img-item{{index}} img-item{{actNum}}{{index}}" src="{{item.url?item.url:item}}?v={{img_version}}" /> <image webp wx:if="{{ index >= 3 && !showLeftFlag}}" webp class="img-item {{item.className?item.className:''}} img-item{{index}} img-item{{actNum}}{{index}}" src="{{item.url?item.url:item}}?v={{img_version}}" />
</block> </block>
......
...@@ -10,9 +10,9 @@ ...@@ -10,9 +10,9 @@
"integrity": "sha512-R2FyCk0mK2xvUX2dMgVZjVG512RKBj7ELMDxjRJjhQWtw4495WBgbl5Yb4v2A6d4vWJe6z9toKgDJTciN0Bo9A==" "integrity": "sha512-R2FyCk0mK2xvUX2dMgVZjVG512RKBj7ELMDxjRJjhQWtw4495WBgbl5Yb4v2A6d4vWJe6z9toKgDJTciN0Bo9A=="
}, },
"glsx-applet-component": { "glsx-applet-component": {
"version": "1.0.30", "version": "1.0.32",
"resolved": "https://registry.npmmirror.com/glsx-applet-component/-/glsx-applet-component-1.0.30.tgz", "resolved": "https://registry.npmjs.org/glsx-applet-component/-/glsx-applet-component-1.0.32.tgz",
"integrity": "sha512-knFullgv2HGJtYZZl809dBIgehzaftLCovDj2SQ+VOsASMNPa22LMzOPLL2n8y4oy5bgS7zMgLEwgUailTAbhw==" "integrity": "sha512-1YnE+r/tHpQS0FYLN/YV7EHvhOhY3leprkghtSpl3jjNP6KkMzrQoRuTatSIe3AWzVOKeXVP6ZsCIm9cdtB4pQ=="
} }
} }
} }
...@@ -5,7 +5,7 @@ ...@@ -5,7 +5,7 @@
"main": "app.js", "main": "app.js",
"dependencies": { "dependencies": {
"@vant/weapp": "^1.10.7", "@vant/weapp": "^1.10.7",
"glsx-applet-component": "^1.0.30" "glsx-applet-component": "^1.0.32"
}, },
"devDependencies": {}, "devDependencies": {},
"scripts": { "scripts": {
......
{ {
"usingComponents": { "usingComponents": {
"pro-detail": "../../../components/proDetail/proDetail", "pro-detail": "../../../components/proDetail/proDetail",
"pro-phone-number": "../../../components/PhoneNumber/PhoneNumber" "apply-button": "../../../pages/viewVideo/components/apply-button/index"
} }
} }
\ No newline at end of file \ No newline at end of file
...@@ -10,3 +10,19 @@ ...@@ -10,3 +10,19 @@
height: 100vh; height: 100vh;
overflow: hidden; overflow: hidden;
} }
.more-btn {
position: absolute;
left: 50%;
bottom: 50px;
transform: translateX(-50%);
width: 622rpx;
height: 96rpx;
background-image: url("https://img02.glsx.com.cn/weapp/resource/saas/business-assistant/index/btn.png");
background-size: 100% 100%;
font-weight: 500;
font-size: 16px;
color: #ffffff;
text-align: center;
line-height: 96rpx;
}
<!--packagesList/pages/productDetail/productDetail.wxml--> <!--packagesList/pages/productDetail/productDetail.wxml-->
<pro-detail id="pro-detail" custom-class="{{!hasPhoneNumber?'max_page_height':''}}" activeUrl="{{activeUrl}}" actNum="{{actNum}}" cardInfo="{{cardInfo}}" activeNavIdx="{{activeNavIdx}}"></pro-detail> <pro-detail id="pro-detail" custom-class="{{showLeftFlag?'max_page_height':''}}" sharephone="{{sharephone}}" actNum="{{actNum}}" activeNavIdx="{{activeNavIdx}}" activeUrl="{{activeUrl}}"></pro-detail>
<pro-phone-number custom-class="pro_phone_number" type="product" hasPhoneNumber="{{hasPhoneNumber}}" bind:updatePhoneNumber="updatePhoneNumber"></pro-phone-number>
\ No newline at end of file \ No newline at end of file
<block wx:if="{{showLeftFlag}}">
<button class="more-btn" bindgetphonenumber="getUserInfo" open-type="getPhoneNumber">
点击查看更多详情
</button>
</block>
<!-- 申请按钮 不是分享出去的显示按钮 -->
<apply-button wx:if="{{!isShare}}" downShow="{{false}}"></apply-button>
<!-- 授权昵称 -->
<view wx:if="{{authNcknameShow}}" class="user-profile" bindtap="getUserProfile"></view>
\ No newline at end of file \ No newline at end of file
// packagesList/pages/videoDetal/videoDetal.js // packagesList/pages/videoDetal/videoDetal.js
import { IMG_URL } from "~/utils/constantData.js";
import { senceData, productData } from "~/pages/tab/index/constant/senceData";
// 导入方法
import { behavior as computedBehavior } from "~/utils/lib/miniprogram-computed";
import utils from '~/utils/util.js'
Page({ Page({
noPageAuth: true,
/** /**
* 页面的初始数据 * 页面的初始数据
*/ */
data: { data: {
senceData,
productData,
videoItem: { videoItem: {
index: 0, index: 0,
videoList: [], videoList: [],
videoUrl: '', videoUrl: '',
hasPhoneNumber: false isShare: false,//是否是被分享出去
} },
videoObj: {}
}, },
/** /**
* 生命周期函数--监听页面加载 * 生命周期函数--监听页面加载
*/ */
onLoad(options) { onLoad(options) {
console.log(options)
wx.$router.getData(res => { wx.$router.getData(res => {
console.log(res)
this.setData({ this.setData({
videoItem: res videoItem: res
}) })
}) })
if (!utils.isEmptyObj(options)) {
let { isShare, videoIndex, tabActive, sceneCode } = options;
let item = this.data.productData[tabActive].find(item => item.sceneCode == sceneCode)
let videoItem = {
index: videoIndex,
videoList: item?.videoList,
videoUrl: item?.videoList[videoIndex]
}
this.setData({
videoItem: videoItem,
isShare: isShare, //
})
this.shareDataFn(options)
}
},
//接受跳转的路由参数(小程序页面跳转)
onRoute(options) {
console.log(options, 'onroute')
if (!options || utils.isEmptyObj(options)) return
let { videoList, index } = options
options.videoIndex = index
this.setData({
videoObj: videoList[index]
})
this.setpagesTitle()
this.shareDataFn(options)
},// 分享数据函数
shareDataFn(options) {
if (!options || utils.isEmptyObj(options)) return
let { tabActive, videoIndex } = options
// console.log("options: ", options, !!options);
// console.log('tabActive,videoIndex: ', tabActive,videoIndex);
this.setData({
tabActive: tabActive,
videoIndex: videoIndex,
});
//
//分享的数据
this.changeShareData()
},
changeShareData() {
let { senceData, tabActive, videoIndex, videoObj } = this.data
// // 设置转发标题
// let userInfoObj = wx.$storage.get("userInfo");
// // #服务商账号#取该分享者商户的联系人字段,无则取商户简称,无则取商户全称
// let name = userInfoObj.merchantName;
tabActive = 99
this.shareTitle = `给您分享一个${videoObj.name} 视频`;
//分享的数据
let senceItem = productData[tabActive][videoIndex]
this.shareQuery = `sceneCode=${senceItem?.sceneCode}&isShare=${true}&tabActive=${tabActive}&videoIndex=${videoIndex}`
}, },
// 下载视频 // 下载视频
downVideo() { downVideo() {
let {videoItem: {url}} = this.data let { videoItem: { url } } = this.data
console.log(url) console.log(url)
}, },
// 申请合作 // 申请合作
...@@ -43,8 +101,12 @@ Page({ ...@@ -43,8 +101,12 @@ Page({
/** /**
* 生命周期函数--监听页面初次渲染完成 * 生命周期函数--监听页面初次渲染完成
*/ */
onReady() { onReady() { },
//设置标题
setpagesTitle() {
//设置标题
let { videoObj } = this.data
utils.setNavigationBarTitle(videoObj.name)
}, },
/** /**
......
{ {
"usingComponents": { "usingComponents": {
"gl-video-detail": "glsx-applet-component/video-detail/index" "gl-video-detail": "glsx-applet-component/video-detail/index",
"apply-button": "../../../pages/viewVideo/components/apply-button/index"
} }
} }
\ No newline at end of file \ No newline at end of file
<!--packagesList/pages/videoDetal/videoDetal.wxml--> <!--packagesList/pages/videoDetal/videoDetal.wxml-->
<!-- aaa --> <!-- aaa -->
<gl-video-detail list="{{videoItem.videoList}}" index="{{videoItem.index}}"></gl-video-detail> <gl-video-detail list="{{videoItem.videoList}}" index="{{videoItem.index}}"></gl-video-detail>
<phone-number type="{{'video'}}" bindvideodown="downVideo" bindtoForward="toForward" bindtoApplication="toApplication" hasPhoneNumber="{{videoItem.hasPhoneNumber}}"></phone-number>
\ No newline at end of file \ No newline at end of file
<!-- 申请按钮 -->
<apply-button wx:if="{{!isShare}}" bindvideodown="downVideo"></apply-button>
\ No newline at end of file \ No newline at end of file
...@@ -120,7 +120,7 @@ ...@@ -120,7 +120,7 @@
.van-tab--active { .van-tab--active {
.van-ellipsis { .van-ellipsis {
font-weight: 600; font-weight: 600;
font-size: 40rpx; font-size: 36rpx;
color: #323436; color: #323436;
overflow: visible; overflow: visible;
text-overflow: auto; text-overflow: auto;
......
...@@ -188,7 +188,7 @@ var senceData = [ ...@@ -188,7 +188,7 @@ var senceData = [
// name: "0-12个月", // name: "0-12个月",
msg: "1.2次新车膨胀金活动", msg: "1.2次新车膨胀金活动",
"sceneCode":"SC003", "sceneCode":"SC003",
tabname:'膨胀金活动', tabname:'客户线上化',
banner:`${IMG_URL}index/banner/banner3.png`, banner:`${IMG_URL}index/banner/banner3.png`,
scrollText:'已发布种草软文100+篇,促进门店二次转化客户到店,欢迎各经销商咨询', scrollText:'已发布种草软文100+篇,促进门店二次转化客户到店,欢迎各经销商咨询',
sceneImgs:[ sceneImgs:[
...@@ -459,6 +459,63 @@ var senceData = [ ...@@ -459,6 +459,63 @@ var senceData = [
] ]
}, },
{
name: '',
img: 'scene_within_12mth.png',
active: 'icon-car21',
playImg: 'img2',
src: `${IMG_URL}index/car3.png`,
msg: "1.2次新车膨胀金活动",
"sceneCode":"SC005",
tabname:'膨胀金活动',
banner:`${IMG_URL}index/banner/banner5.png`,
scrollText:'已发布种草软文100+篇,促进门店二次转化客户到店,欢迎各经销商咨询',
sceneImgs:[
`${IMG_URL}index/scene/scene20.png`,
`${IMG_URL}index/scene/scene21.png`,
`${IMG_URL}index/scene/scene22.png`,
`${IMG_URL}index/scene/scene23.png`,
],
productImgs:[
`${IMG_URL}index/productImgs/product60.webp`,
`${IMG_URL}index/productImgs/product61.webp`,
`${IMG_URL}index/productImgs/product62.webp`,
`${IMG_URL}index/productImgs/product63.webp`,
`${IMG_URL}index/productImgs/product64.webp`,
`${IMG_URL}index/productImgs/product65.webp`,
],
productList: [
{
img: 'product-img3',
proName: '膨胀金',
price: '100',
profit: '180000',
type: 'service',
productType: 'protectMembrane',
path: 'paintProtect',
sale:100, //销量
varType: 0,
flow:10000,
"productCode":"PC010",
"productName":"膨胀金",
"category":"服务类",
prodImg: `${IMG_URL}index/prod2/prod5-0.png`,
tabList: ['项目介绍', '活动方案', '销售场景', '合作案例', '合作方式', 'FAQ']
}
],
//无视频时显示的图片
noVideoPicture: [],
videoList:[
{
videoUrl: `${videoBaseUrl}video/fragrance.mp4`,
posterUrl: `${IMG_URL}index/poster/fragrance.png`,
name: '售后膨胀金活动',
manufacturer: '嘀加智慧',
view: 3298
}
],
posterList:[]
},
// { // {
// name: '3年以上', // name: '3年以上',
// img: 'scene_talk.png', // img: 'scene_talk.png',
......
...@@ -75,6 +75,7 @@ const scenario_0 = [ ...@@ -75,6 +75,7 @@ const scenario_0 = [
sceneImgs: sceneImgs0, sceneImgs: sceneImgs0,
// 产品详情图片 // 产品详情图片
productImgs: productImgs0, productImgs: productImgs0,
"sceneCode":"SC001",
productList: [ productList: [
{ {
id: 0, id: 0,
...@@ -134,6 +135,7 @@ const scenario_1 = [ ...@@ -134,6 +135,7 @@ const scenario_1 = [
name: '膜类', name: '膜类',
sceneImgs: sceneImgs1, sceneImgs: sceneImgs1,
productImgs: productImgs1, productImgs: productImgs1,
"sceneCode":"SC002",
productList: [ productList: [
{ {
id: 0, id: 0,
...@@ -185,6 +187,7 @@ const scenario_2 = [ ...@@ -185,6 +187,7 @@ const scenario_2 = [
name: '膜类', name: '膜类',
sceneImgs: sceneImgs2, sceneImgs: sceneImgs2,
productImgs: productImgs2, productImgs: productImgs2,
"sceneCode":"SC003",
productList: [ productList: [
{ {
id: 0, id: 0,
...@@ -301,6 +304,7 @@ const posterList3 = [ ...@@ -301,6 +304,7 @@ const posterList3 = [
const scenario_3 = [ const scenario_3 = [
{ {
name: '美容类', name: '美容类',
"sceneCode":"SC004",
productList: [ productList: [
{ {
id: 0, id: 0,
......
...@@ -44,6 +44,7 @@ const subscriptionSystemData = [ ...@@ -44,6 +44,7 @@ const subscriptionSystemData = [
// sceneImgs: sceneImgs5, // sceneImgs: sceneImgs5,
// 产品详情图片 // 产品详情图片
productImgs: productImgs0, productImgs: productImgs0,
"sceneCode":"SC005",
productList: [ productList: [
{ {
id: 0, id: 0,
...@@ -117,6 +118,7 @@ const subscriptionSystemData = [ ...@@ -117,6 +118,7 @@ const subscriptionSystemData = [
name: '客户活跃', name: '客户活跃',
//场景详情图片 //场景详情图片
sceneImgs: sceneImgs5, sceneImgs: sceneImgs5,
"sceneCode":"SC006",
// 产品详情图片 // 产品详情图片
productImgs: productImgs0, productImgs: productImgs0,
productList: [ productList: [
......
...@@ -61,21 +61,17 @@ Page({ ...@@ -61,21 +61,17 @@ Page({
proClick(e) { proClick(e) {
let { detail } = e let { detail } = e
//登录的用户手机号 //登录的用户手机号
console.log(detail) let userInfo = wx.$storage.get("userInfo");
// let userInfo = wx.$storage.get("userInfo")
const { cardInfo } = this.data
let obj = { let obj = {
// || 99 // || 99
actNum: isNaN(detail.scenIndex) ? 99 : detail.scenIndex, //选中的场景 没有就是订阅系统的 actNum: isNaN(detail.scenIndex) ? 99 : detail.scenIndex, //选中的场景 没有就是订阅系统的
activeNavIdx: detail.id, //选中的产品, activeNavIdx: detail.id, //选中的产品,
cardInfo, phone: userInfo.phone
hasPhoneNumber: this.data.hasPhoneNumber
} }
wx.$router.go('/packagesList/pages/productDetail/productDetail', obj) wx.$router.go('/packagesList/pages/productDetail/productDetail', obj)
}, },
// 跳转视频详情 // 跳转视频详情
videoClick(e) { videoClick(e) {
console.log(e.detail)
const { const {
index, index,
info: { videoUrl }, info: { videoUrl },
...@@ -88,28 +84,30 @@ Page({ ...@@ -88,28 +84,30 @@ Page({
// console.log(productData[0]) // console.log(productData[0])
//const videoList = productData[scenIndex][0].videoList //const videoList = productData[scenIndex][0].videoList
const videoList = list const videoList = list
let userInfo = wx.$storage.get("userInfo");
wx.$router.go('/packagesList/pages/videoDetal/videoDetal', { wx.$router.go('/packagesList/pages/videoDetal/videoDetal', {
index, index,
videoList, videoList,
scenIndex: scenIndex,
videoUrl: videoUrl, videoUrl: videoUrl,
hasPhoneNumber: this.data.hasPhoneNumber phone: userInfo.phone
}) })
}, },
// 跳转活动页 // 跳转活动页
activityClick(e) { activityClick(e) {
const { hasPhoneNumber } = this.data
const id = e.detail const id = e.detail
console.log(e) let userInfo = wx.$storage.get("userInfo");
wx.$router.go('/packagesList/pages/activityDetail/activityDetail', { hasPhoneNumber, id }) wx.$router.go('/packagesList/pages/activityDetail/activityDetail', {
phone: userInfo.phone, id })
}, },
// 场景跳转 // 场景跳转
senceClick(e) { senceClick(e) {
const { hasPhoneNumber } = this.data
console.log(e)
const { scenIndex } = e.detail const { scenIndex } = e.detail
wx.$router.go('/packagesList/pages/scenarioDetail/scenarioDetail', { hasPhoneNumber, actNum: scenIndex }) let userInfo = wx.$storage.get("userInfo");
wx.$router.go('/packagesList/pages/scenarioDetail/scenarioDetail', { actNum: scenIndex,
phone: userInfo.phone })
}, },
//引导图 //引导图
guideFn() { guideFn() {
...@@ -129,13 +127,10 @@ Page({ ...@@ -129,13 +127,10 @@ Page({
// navbar高度设置 // navbar高度设置
navbarReady(e) { navbarReady(e) {
let { height, statusBarHeight } = e.detail let { height, statusBarHeight } = e.detail
// console.log('height, statusBarHeight: ', height, statusBarHeight);
this.setData({ this.setData({
headerHeight: height / 2 + statusBarHeight, headerHeight: height / 2 + statusBarHeight,
// headerHeight: height / 2 + statusBarHeight + 88 * 2 // headerHeight: height / 2 + statusBarHeight + 88 * 2
}) })
// console.log(e)
// console.log(this.data.headerHeight)
}, },
selectCar(e) { selectCar(e) {
let actNum = e.detail let actNum = e.detail
...@@ -145,7 +140,7 @@ Page({ ...@@ -145,7 +140,7 @@ Page({
}, },
// 头部看线索,产品切换 // 头部看线索,产品切换
changeTabIndx(e) { changeTabIndx(e) {
console.log('e.detail: ', e.detail) // console.log('e.detail: ', e.detail)
let { sessionId } = wx.$storage.get() let { sessionId } = wx.$storage.get()
// console.log("sessionId: ", sessionId); // console.log("sessionId: ", sessionId);
let param = { let param = {
...@@ -174,12 +169,12 @@ Page({ ...@@ -174,12 +169,12 @@ Page({
}, },
// 跳转咨询页面 // 跳转咨询页面
goConsult() { goConsult() {
console.log('跳转到咨询页面') // console.log('跳转到咨询页面')
wx.pro.openCustomerServiceChat({ wx.pro.openCustomerServiceChat({
extInfo: { url: 'https://work.weixin.qq.com/kfid/kfcf7b721472201345e' }, extInfo: { url: 'https://work.weixin.qq.com/kfid/kfcf7b721472201345e' },
corpId: 'ww047bdc0f1e76cc13', corpId: 'ww047bdc0f1e76cc13',
complete: r => { complete: r => {
console.log(r) // console.log(r)
} }
}) })
}, },
......
...@@ -4,7 +4,8 @@ import { IMG_URL } from "~/utils/constantData.js"; ...@@ -4,7 +4,8 @@ import { IMG_URL } from "~/utils/constantData.js";
import { senceData } from "~/pages/tab/index/constant/data"; import { senceData } from "~/pages/tab/index/constant/data";
import USERAPI from '~/api/usersApi/index' import USERAPI from '~/api/usersApi/index'
import utils from '~/utils/util.js' import utils from '~/utils/util.js'
import {getActiveApi} from "~/api/viewprod" import { getActiveApi } from "~/api/viewprod"
const norTabList = ['项目亮点', '合作案例', '合作方式', '适配产品']
Page({ Page({
/** /**
...@@ -15,18 +16,19 @@ Page({ ...@@ -15,18 +16,19 @@ Page({
data: { data: {
IMG_URL, IMG_URL,
senceData, senceData,
isShare:false, //是否是分享出去的 isShare: false, //是否是分享出去的
actNum: 0, actNum: 0,
tabAct: 0, tabAct: 0,
showLeft:false, //更多按钮显示的内容 showLeft: false, //更多按钮显示的内容
scrollTop:0, scrollTop: 0,
img_version: '0.1.0', img_version: '0.1.0',
// 是否授权昵称 // 是否授权昵称
hasUserInfo: false, hasUserInfo: false,
// phone: '', //授权手机号 // phone: '', //授权手机号
prodItemVideo:'', //选中的场景下的video的第一个 prodItemVideo: '', //选中的场景下的video的第一个
activeUrl:'', // 1.3场景才有的活动配置 activeUrl: '', // 1.3场景才有的活动配置
sharephone:'' //主要微信用户,服务商 sharephone: '', //主要微信用户,服务商,
tabList: []
}, },
// 计算属性 // 计算属性
computed: { computed: {
...@@ -35,16 +37,16 @@ Page({ ...@@ -35,16 +37,16 @@ Page({
// 2.点击可以改变状态 // 2.点击可以改变状态
return data.isShare && !data.showLeft return data.isShare && !data.showLeft
}, },
prodItemVideo(data){ prodItemVideo(data) {
let {senceData,actNum,activeNavIdx} = data let { senceData, actNum, activeNavIdx } = data
// return senceData[actNum]?.productList[activeNavIdx] // return senceData[actNum]?.productList[activeNavIdx]
if(actNum == 2){ if (actNum == 2) {
return senceData[actNum]?.noVideoPicture[0] return senceData[actNum]?.noVideoPicture[0]
} }
return senceData[actNum]?.videoList[activeNavIdx] return senceData[actNum]?.videoList[activeNavIdx]
}, },
// 授权昵称弹框显示 // 授权昵称弹框显示
authNcknameShow(data){ authNcknameShow(data) {
return data.isShare && !data.hasUserInfo return data.isShare && !data.hasUserInfo
} }
...@@ -59,8 +61,8 @@ Page({ ...@@ -59,8 +61,8 @@ Page({
this.isgetAuthphone() this.isgetAuthphone()
if (!options || utils.isEmptyObj(options)) return if (!options || utils.isEmptyObj(options)) return
let { actNum, activeNavIdx, isShare,sharephone } = options let { actNum, activeNavIdx, isShare, sharephone } = options
if(isShare){ if (isShare) {
wx.hideHomeButton() wx.hideHomeButton()
} }
...@@ -74,14 +76,14 @@ Page({ ...@@ -74,14 +76,14 @@ Page({
//分享数据 //分享数据
let senceItem = senceData[actNum] let senceItem = senceData[actNum]
let item = senceData[actNum]?.productList[activeNavIdx] let item = senceData[actNum]?.productList[activeNavIdx]
console.log('title',item.productName) console.log('title', item.productName)
setTimeout(() => { setTimeout(() => {
// wx.setNavigationBarTitle({ // wx.setNavigationBarTitle({
// title: " "+item.productName, // title: " "+item.productName,
// }); // });
utils.setNavigationBarTitle(item.productName) utils.setNavigationBarTitle(item.productName)
},100) }, 100)
let wx_user_info = wx.$storage.get('wx_user_info'), let wx_user_info = wx.$storage.get('wx_user_info'),
shareOpenId = wx_user_info.openId || '' shareOpenId = wx_user_info.openId || ''
...@@ -95,7 +97,7 @@ Page({ ...@@ -95,7 +97,7 @@ Page({
productName: item?.productName, productName: item?.productName,
category: item?.category, category: item?.category,
productDesc: item?.productName, productDesc: item?.productName,
shareOpenId:shareOpenId shareOpenId: shareOpenId
// actNum, // actNum,
// activeNavIdx, // activeNavIdx,
} }
...@@ -104,12 +106,13 @@ Page({ ...@@ -104,12 +106,13 @@ Page({
//接受跳转的路由参数(小程序页面跳转) //接受跳转的路由参数(小程序页面跳转)
onRoute(options) { onRoute(options) {
if (!options || utils.isEmptyObj(options)) return if (!options || utils.isEmptyObj(options)) return
let { actNum = 0, activeNavIdx = 0,phone=123 } = options; let { actNum = 0, activeNavIdx = 0, phone = 123 } = options;
this.setData({ this.setData({
actNum, //选中的场景下标 actNum, //选中的场景下标
activeNavIdx, //选中的产品 activeNavIdx, //选中的产品
sharephone:phone //联系电话 (登陆的用户) sharephone: phone, //联系电话 (登陆的用户)
tabList: senceData[actNum]?.productList[activeNavIdx].tabList || norTabList
}); });
// 设置转发标题 // 设置转发标题
...@@ -122,14 +125,14 @@ Page({ ...@@ -122,14 +125,14 @@ Page({
//分享数据 //分享数据
let item = senceData[actNum]?.productList[activeNavIdx] let item = senceData[actNum]?.productList[activeNavIdx]
console.log('title2',item.productName) console.log('title2', item.productName)
setTimeout(() => { setTimeout(() => {
// wx.setNavigationBarTitle({ // wx.setNavigationBarTitle({
// title: " "+item.productName, // title: " "+item.productName,
// }); // });
utils.setNavigationBarTitle(item.productName) utils.setNavigationBarTitle(item.productName)
},100) }, 100)
//分享人openId //分享人openId
let wx_user_info = wx.$storage.get('wx_user_info'), let wx_user_info = wx.$storage.get('wx_user_info'),
...@@ -143,7 +146,7 @@ Page({ ...@@ -143,7 +146,7 @@ Page({
productName: item?.productName, productName: item?.productName,
category: item?.category, category: item?.category,
productDesc: item?.productName, productDesc: item?.productName,
shareOpenId:shareOpenId shareOpenId: shareOpenId
// actNum, // actNum,
// activeNavIdx, // activeNavIdx,
// apiData, // apiData,
...@@ -151,22 +154,22 @@ Page({ ...@@ -151,22 +154,22 @@ Page({
}, },
//获取配置url //获取配置url
async getActiveApiFn(){ async getActiveApiFn() {
let {code,data} = await getActiveApi() let { code, data } = await getActiveApi()
if(code == 0){ if (code == 0) {
this.setData({ this.setData({
activeUrl: data activeUrl: data
}) })
} }
}, },
// 是否已经查看详情 // 是否已经查看详情
isgetAuthphone(){ isgetAuthphone() {
let authphone = wx.$storage.get("authphone"); let authphone = wx.$storage.get("authphone");
if(authphone){ if (authphone) {
// 显示后面的内容 // 显示后面的内容
setTimeout(() => { setTimeout(() => {
this.getImgHeight() this.getImgHeight()
},300) }, 300)
this.setData({ this.setData({
showLeft: true showLeft: true
...@@ -201,16 +204,16 @@ Page({ ...@@ -201,16 +204,16 @@ Page({
// wx.$eventbus.emit('evt_page_scroll', { scrollTop: e.scrollTop }) // wx.$eventbus.emit('evt_page_scroll', { scrollTop: e.scrollTop })
wx.nextTick(() => { wx.nextTick(() => {
let idx let idx
if(imgTopArr[0]>e.scrollTop){ if (imgTopArr[0] > e.scrollTop) {
idx = 0 idx = 0
}else if(imgTopArr[imgTopArr.length-1]>e.scrollTop && imgTopArr[0]<e.scrollTop){ } else if (imgTopArr[imgTopArr.length - 1] > e.scrollTop && imgTopArr[0] < e.scrollTop) {
idx = imgTopArr.findIndex((item) => item >e.scrollTop) - 1; idx = imgTopArr.findIndex((item) => item > e.scrollTop) - 1;
} else{ } else {
idx = imgTopArr.length-1 idx = imgTopArr.length - 1
} }
this.setData({ this.setData({
tabAct: idx, tabAct: idx,
scrollTop:e.scrollTop scrollTop: e.scrollTop
}); });
}); });
}, 100); }, 100);
...@@ -229,7 +232,7 @@ Page({ ...@@ -229,7 +232,7 @@ Page({
let imgTopArr = []; let imgTopArr = [];
let s = 0; let s = 0;
let top; let top;
let {scrollTop} = this.data let { scrollTop } = this.data
let _this = this; let _this = this;
query query
...@@ -299,7 +302,7 @@ Page({ ...@@ -299,7 +302,7 @@ Page({
// 显示后面的内容 // 显示后面的内容
setTimeout(() => { setTimeout(() => {
this.getImgHeight() this.getImgHeight()
},300) }, 300)
this.setData({ this.setData({
showLeft: true showLeft: true
...@@ -346,45 +349,54 @@ Page({ ...@@ -346,45 +349,54 @@ Page({
}) })
}, },
// 1.3查看活动详情按钮 // 1.3查看活动详情按钮
checkActive(){ checkActive() {
// 跳转 // 跳转
// console.log('跳转') // console.log('跳转')
let {activeUrl} = this.data let { activeUrl } = this.data
wx.$router.jumpH5(activeUrl); wx.$router.jumpH5(activeUrl);
}, },
// 长按图片
handleLongPress(e) {
let { actnum, index } = e.target.dataset
// 膨胀金活动,合作方式
if (actnum == 4 && index == 4) {
wx.$router.jumpH5('https://1064147.ma3you.cn/articles/OdEQmwb/');
}
},
/** /**
* 生命周期函数--监听页面显示 * 生命周期函数--监听页面显示
*/ */
onShow() {}, onShow() { },
/** /**
* 生命周期函数--监听页面隐藏 * 生命周期函数--监听页面隐藏
*/ */
onHide() {}, onHide() { },
/** /**
* 生命周期函数--监听页面卸载 * 生命周期函数--监听页面卸载
*/ */
onUnload() {}, onUnload() { },
/** /**
* 页面相关事件处理函数--监听用户下拉动作 * 页面相关事件处理函数--监听用户下拉动作
*/ */
onPullDownRefresh() {}, onPullDownRefresh() { },
/** /**
* 页面上拉触底事件的处理函数 * 页面上拉触底事件的处理函数
*/ */
onReachBottom() {}, onReachBottom() { },
/** /**
* 用户点击右上角分享 * 用户点击右上角分享
*/ */
onShareAppMessage() {}, onShareAppMessage() { },
/** /**
* 浏览埋点 * 浏览埋点
*/ */
onShareTimeline() {}, onShareTimeline() { },
onViewTrack: true onViewTrack: true
}); });
...@@ -212,6 +212,36 @@ page { ...@@ -212,6 +212,36 @@ page {
width: 100%; width: 100%;
height: 2002rpx; height: 2002rpx;
} }
// // 流程图五
.img-item40 {
width: 100%;
height: 1564rpx;
}
.img-item41 {
width: 100%;
height: 1224rpx;
}
.img-item42 {
width: 100%;
height: 1148rpx;
}
.img-item43 {
width: 100%;
height: 3504rpx;
}
.img-item44 {
width: 100%;
height: 2220rpx;
}
.img-item45 {
width: 100%;
height: 1092rpx;
}
} }
} }
/* 用户授权 */ /* 用户授权 */
......
...@@ -15,10 +15,11 @@ ...@@ -15,10 +15,11 @@
<!-- <image class="no-video" wx:if="{{actNum == 2}}" src="{{IMG_URL}}index/poster/no-video.png?v={{img_version}}" /> --> <!-- <image class="no-video" wx:if="{{actNum == 2}}" src="{{IMG_URL}}index/poster/no-video.png?v={{img_version}}" /> -->
<view class="tab-wrap"> <view class="tab-wrap">
<van-tabs sticky bind:click="onClickTab" active="{{tabAct}}"> <van-tabs sticky bind:click="onClickTab" active="{{tabAct}}">
<van-tab title="项目亮点"></van-tab> <van-tab wx:for="{{tabList}}" title="{{item}}" wx:key="idnex" />
<!-- <van-tab title="项目亮点"></van-tab>
<van-tab title="合作案例"></van-tab> <van-tab title="合作案例"></van-tab>
<van-tab title="合作方式"></van-tab> <van-tab title="合作方式"></van-tab>
<van-tab title="适配产品"></van-tab> <van-tab title="适配产品"></van-tab> -->
</van-tabs> </van-tabs>
</view> </view>
<view class="prod-detail"> <view class="prod-detail">
...@@ -49,7 +50,7 @@ ...@@ -49,7 +50,7 @@
</button> </button>
</block> </block>
</image> </image>
<image wx:if="{{ index >= 3 && !showLeftFlag}}" webp class="img-item img-item{{index}} img-item{{actNum}}{{index}}" src="{{item}}?v={{img_version}}"> <image wx:if="{{ index >= 3 && !showLeftFlag}}" webp class="img-item img-item{{index}} img-item{{actNum}}{{index}}" src="{{item}}?v={{img_version}}" bindlongpress="handleLongPress" data-actnum="{{actNum}}" data-index="{{index}}">
</image> </image>
</block> </block>
<view class="occupancy" wx:if="{{!isShare}}"> <view class="occupancy" wx:if="{{!isShare}}">
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!