Commit 40f3d0b3 by 张立顺

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

2 parents 0dc42bb2 34691f37
......@@ -6,5 +6,6 @@
"type-list": "./components/TypeList/TypeList",
"agree": "./components/Agree/Agree"
},
"navigationStyle": "custom"
"navigationStyle": "custom",
"disableScroll": true
}
\ No newline at end of file
......@@ -115,11 +115,14 @@
bottom: 0;
left: 0;
width: 100%;
height: 88rpx;
line-height: 88rpx;
text-align: center;
background: #3666FE;
font-size: 28rpx;
color: #FFFFFF;
.btn {
width: 100%;
height: 88rpx;
line-height: 88rpx;
text-align: center;
background: #3666FE;
font-size: 28rpx;
color: #FFFFFF;
}
}
}
\ No newline at end of file
......@@ -32,5 +32,7 @@
</view>
</view>
</view>
<view wx:if="{{activityList[activityActive].productStatus != 2 && !merchantInfo.isSuper}}" class="btn-blue" bindtap="handleJump">点击开通</view>
<view class="isFullSucreen btn-blue">
<view wx:if="{{activityList[activityActive].productStatus != 2 && !merchantInfo.isSuper}}" class="btn" bindtap="handleJump">点击开通</view>
</view>
</view>
\ No newline at end of file
......@@ -4,6 +4,5 @@
},
"navigationStyle": "custom",
"onReachBottomDistance": 10,
"backgroundColor": "#FC5B32",
"enablePullDownRefresh": true
}
......@@ -68,3 +68,14 @@
}
}
}
/* 用户授权 */
.user-profile {
position: fixed;
top: 0;
left: 0;
right: 0;
bottom: 0;
z-index: 2;
background-color: transparent;
}
......@@ -4,7 +4,7 @@
</view>
<product stickyTop="{{headerHeight}}" actNum="{{actNum}}" senceData="{{senceData}}" isShare="{{isShare}}" bindauthorized="authorizedFn" />
<product stickyTop="{{headerHeight}}" actNum="{{actNum}}" wrapactiveNavIdx="{{activeNavIdx}}" outshowVideo="{{outshowVideo}}" senceData="{{senceData}}" outshowVideo="{{outshowVideo}}" isShare="{{isShare}}" bindauthorized="authorizedFn" />
<!-- 分享弹框 -->
<!-- <shareModel actNum="{{actNum}}" isShow="{{isShow}}" bindmodelclose="modelcloseFn" /> -->
<view class="share-wrap" wx:if="{{isShow}}">
......@@ -34,3 +34,6 @@
<view class="btom" bindtap="modelcloseFn">取消</view>
</view>
</view>
<!-- 授权昵称 -->
<!-- !hasUserInfo && !isShow -->
<view wx:if="{{!hasUserInfo && isShare}}" class="user-profile" bindtap="getUserProfile"></view>
......@@ -13,12 +13,18 @@ Component({
properties: {
stickyTop: Number,
actNum: Number,
wrapactiveNavIdx:Number,
senceData: Object, //本地数据
apiData:Object, //后端接口数据
isShare: {
type: Boolean,
value: false,
},
origin:String, //来源
outshowVideo: {
type: Boolean,
value: true,
}, //显示视频列表
},
/**
......@@ -41,11 +47,24 @@ Component({
intoViewId: "to-0",
IMGURL: `${IMG_URL}index/`,
videoBaseUrl,
getMoreBtn:false,
showVideo:true //显示视频列表
},
lifetimes: {
ready: function () {
if(this.data.wrapactiveNavIdx){
this.setData({
activeNavIdx:this.data.wrapactiveNavIdx
})
}
if(!this.data.outshowVideo){
console.log('outshowVideo', this.data.outshowVideo)
this.setData({
showVideo:false
})
}
this.init();
// console.log('stickyTop',this.data.stickyTop)
this.getImgHeight();
//如果不是分享,初始化的时候调用函数
if (!this.data.isShare) {
......@@ -166,22 +185,29 @@ Component({
},
// 获取用户信息
getUserInfo({ detail }) {
console.log(detail);
// console.log(detail);
if (!detail.code) return;
// this.setBtnLoading()
USERAPI.getUserProfile(this.loginToken, detail)
.then((result) => {
// console.log(result)
let userInfo = wx.$storage.get('wx_user_info')
// console.log('userInfo: ', userInfo);
let { phone } = result;
// let {
wx.$storage.set('wx_user_info', result);
// console.log('phone: ', phone);
wx.$storage.set('wx_user_info', {...userInfo,phone});
// }
this.triggerEvent("authorized", {
phone,
isShare: false,
// isShare: false,
});
// this.
//隐藏更多按钮,显示视频列表
this.setData({
getMoreBtn:true,
isShare: false,
outshowVideo:true
})
this.getMoreFn()
})
.catch(({ errMsg }) => {
......@@ -228,6 +254,8 @@ Component({
actNum,
activeNavIdx,
apiData,
outshowVideo:true
// origin:'home' //跟首页类似情况
// isShare: true
});
},
......
<!-- pages/tab/discovery/components/product/product.wxml -->
<view class="prod-wrap">
<text class="big-title">特色产品</text>
<scroll-view class="nav-wrap" scroll-x="{{true}}" wx:if="{{!isShare}}">
<scroll-view class="nav-wrap" scroll-x="{{true}}" wx:if="{{!isShare && origin =='home'}}">
<block wx:for="{{navList}}" wx:key="index">
<text class='nav {{activeNavIdx==index ? "active-nav": ""}}' bindtap="changeNav" data-index="{{index}}">{{item}}</text>
</block>
......@@ -17,10 +17,10 @@
<text class="title">{{senceData[actNum].productList[activeNavIdx].proName}}</text>
<text class="sale" decode="{{true}}">{{senceData[actNum]['productList'][activeNavIdx].varType == 1 ? '三年售后存量数':'新车销量'}}&nbsp;<text class="sale-num">{{senceData[actNum]['productList'][activeNavIdx].changeSale || senceData[actNum]['productList'][activeNavIdx].sale}}</text>
</text>
<text class="earnings" decode="{{true}}">{{stickyTop}}预估收益&nbsp;<text class="earnings-num">{{senceData[actNum]['productList'][activeNavIdx].profit}}</text>
<text class="earnings" decode="{{true}}">预估收益&nbsp;<text class="earnings-num">{{senceData[actNum]['productList'][activeNavIdx].profit}}</text>
</text>
</view>
<view class="share-btn" wx:if="{{!isShare}}" bindtap="onShareFn">
<view class="share-btn" wx:if="{{!isShare && origin =='home'}}" bindtap="onShareFn">
<image class="icon" src="{{IMGURL}}share.png" />
<text>分享</text>
</view>
......@@ -46,9 +46,10 @@
scroll-y="{{true}}"
>
<block wx:for="{{tab}}" wx:key="index">
<view id="to-{{index}}" class="img-item img-item{{actNum+1}}{{index+1}}" >
<!-- {{item}} -->
<image class="img-item{{actNum+1}}{{index+1}}" src="{{IMGURL}}scene{{actNum+1}}{{index+1}}.png" wx:if="{{index!=5}}" />
<!-- wx:if="{{showVideo && index==5 && tab.length < 5}}" -->
<view id="to-{{index}}" class="img-item img-item{{actNum+1}}{{index+1}}" wx:if="{{index != 5}}">
<!-- wx:if="{{index!=5}}" -->
<image class="img-item{{actNum+1}}{{index+1}}" src="{{IMGURL}}scene{{actNum+1}}{{index+1}}.png" />
<view class="video-bg" wx:if="{{!isShare && index==5 && senceData[actNum].videoList.length}}">
<view class="video-list">
<block wx:for="{{senceData[actNum].videoList}}" wx:key="i">
......@@ -62,8 +63,9 @@
</view>
<!-- wx:if="{{ actNum != 2 && index == 4}}" -->
<!-- wx:if="{{isShare && actNum != 2 && index == 4}}" -->
<!-- wx:if="{{ isShare && actNum != 2 && index == 4}}" -->
<button
wx:if="{{ isShare && actNum != 2 && index == 4}}"
wx:if="{{ isShare && !getMoreBtn && actNum != 2 && index == 4}}"
class="more-btn"
data-index="{{index}}"
bindgetphonenumber="getUserInfo"
......@@ -72,6 +74,22 @@
点击查看更多详情
</button>
</view>
<view id="to-{{index}}" class="img-item img-item{{actNum+1}}{{index+1}}" wx:if="{{index == 5 && outshowVideo}}">
<!-- wx:if="{{index!=5}}" -->
<image class="img-item{{actNum+1}}{{index+1}}" src="{{IMGURL}}scene{{actNum+1}}{{index+1}}.png" />
<view class="video-bg" wx:if="{{!isShare && index==5 && senceData[actNum].videoList.length}}">
<view class="video-list">
<block wx:for="{{senceData[actNum].videoList}}" wx:key="i">
<view class="video-item">
<video poster="{{videoBaseUrl}}video/{{item.posterUrl}}.png?v={{img_version}}" title="{{item.name}}" src="{{videoBaseUrl}}video/{{item.videoUrl}}.mp4?v={{img_version}}" />
<view class="video-text">{{item.name}}</view>
</view>
</block>
</view>
</view>
</view>
</block>
</scroll-view>
</view>
......
// 1.视频默认进来是true,显示,
// 2.扫码,分享链接进来,不显示
// 3.点击更多详情,隐藏更多按钮,显示视频
// 4.视频的位置最后一个 下标5
// var showVideo = function(index){
// if(index == 5){
// a
// }
// };
// module.exports = {
// showVideo:showVideo
// }
......@@ -14,9 +14,9 @@ var senceData = [
{
img: 'product-img1',
proName: '数字无忧权益卡',
price: '1500',
price: '100',
// profit: '92.4万',
profit: '120万',
profit: '1200000',
type: 'service',
productType: 'benefitCard',
path: 'equity',
......@@ -63,8 +63,8 @@ var senceData = [
{
img: 'product-img2',
proName: '汽车太阳膜',
price: '1500',
profit: '1008万',
price: '100',
profit: '10080000',
type: 'membrane',
productType: 'sunMembrane',
path: 'solarFilm',
......@@ -96,8 +96,8 @@ var senceData = [
{
img: 'product-img3',
proName: '漆面保护膜',
price: '12000',
profit: '216万',
price: '100',
profit: '2160000',
type: 'membrane',
productType: 'protectMembrane',
path: 'paintProtect',
......@@ -110,8 +110,8 @@ var senceData = [
{
img: 'product-img4',
proName: '改色膜',
price: '5000',
profit: '30万',
price: '100',
profit: '300000',
type: 'membrane',
productType: 'colorMembrane',
path: 'changingFilm',
......@@ -136,8 +136,8 @@ var senceData = [
{
img: 'product-img5',
proName: '数字化美容',
price: '300',
profit: '36万',
price: '100',
profit: '72000',
type: 'beauty',
productType: 'digitBeauty',
path: 'carBeauty',
......@@ -150,8 +150,8 @@ var senceData = [
{
img: 'product-img6',
proName: '座椅通风',
price: '1500',
profit: '1008万',
price: '10000',
profit: '232200',
type: 'light',
productType: 'chair',
path: 'seatVentilate',
......@@ -164,8 +164,8 @@ var senceData = [
{
img: 'product-img7',
proName: 'AR导航',
price: '1680',
profit: '22.68万',
price: '10000',
profit: '226800',
type: 'light',
productType: 'ar',
path: 'arNavigation',
......@@ -178,8 +178,8 @@ var senceData = [
{
img: 'product-img8',
proName: '氛围灯',
price: '2680',
profit: '36.18万',
price: '10000',
profit: '361800',
type: 'light',
productType: 'lamp',
path: 'ambientLighting',
......@@ -192,8 +192,8 @@ var senceData = [
{
img: 'product-img9',
proName: '360全景导航',
price: '2880',
profit: '38.88万',
price: '10000',
profit: '388800',
type: 'service',
productType: 'navigation',
path: 'navigationArround',
......
......@@ -48,7 +48,7 @@ Page({
},
],
apiData: [],
actNum: 0, //car 场景选择
actNum: 3, //car 场景选择
tabIndx: 1,
navList: ["看线索", "看产品"],
typeList: ["联系电话", "意向客户", "线索来源", "重置"],
......@@ -350,7 +350,7 @@ Page({
}
console.log(profit.length);
console.log(productType, sales, flow, profit);
if (profit.length > 8) {
if (profit.length > 9) {
return (profit / 10000).toFixed(0) + "万";
} else {
return profit;
......@@ -391,7 +391,7 @@ Page({
apiData: data,
});
this.compositionData(senceData, this.data.apiData);
this.getFirstSenceIndex();
// this.getFirstSenceIndex();
}
});
// 看线索
......
......@@ -237,9 +237,9 @@ page {
.scene {
margin: 0 10px 16px;
display: flex;
// justify-content: space-between;
justify-content: space-between;
.item-wrap {
margin-right: 4px;
// margin-right: 4px;
position: relative;
width: 86px;
height: 90px;
......
......@@ -23,7 +23,7 @@
</view>
</view>
</view>
<product stickyTop="{{headerHeight}}" actNum="{{actNum}}" senceData="{{senceData}}" apiData="{{apiData}}" bindsharehandle="sharehandle" />
<product stickyTop="{{headerHeight}}" actNum="{{actNum}}" senceData="{{senceData}}" origin="home" apiData="{{apiData}}" bindsharehandle="sharehandle" />
</view>
<!-- 看线索内容 -->
<view class="clue" wx:if="{{tabIndx == 0 }}" hover-class="none" hover-stop-propagation="false">
......
......@@ -3,7 +3,7 @@
box-sizing: border-box;
height: 100%;
color: #323436;
padding: 16rpx 0 60rpx;
padding-top: 16rpx;
background-color: #F2F3F7;
}
......@@ -123,4 +123,5 @@
font-size: 24rpx;
text-align: center;
color: #CCCED1;
padding-bottom: 60rpx;
}
\ No newline at end of file
......@@ -6,7 +6,7 @@ const target = ['ip', 'dev', 'uat', 'prod']
2测试
3生产
*/
const index = 2
const index = 1
const secretKey = {
ip: {},
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!