|
...
|
...
|
@@ -11,6 +11,7 @@ Page({ |
|
|
|
* 页面的初始数据
|
|
|
|
*/
|
|
|
|
data: {
|
|
|
|
show_white:false,
|
|
|
|
options: {
|
|
|
|
tplid: ''
|
|
|
|
},
|
|
...
|
...
|
@@ -65,6 +66,7 @@ Page({ |
|
|
|
paymentId: '', //定金id
|
|
|
|
wxml: null,
|
|
|
|
imgSrc: '', //canvas图片地址
|
|
|
|
colors:'',//导航栏颜色
|
|
|
|
},
|
|
|
|
tablestr: '',
|
|
|
|
urlsValue: [],
|
|
...
|
...
|
@@ -99,6 +101,15 @@ Page({ |
|
|
|
},
|
|
|
|
// 页面滚动事件
|
|
|
|
onPageScroll: function (event) {
|
|
|
|
if(event.scrollTop>150){ //当页面滚动到某个位置时(这里设置为50),将导航栏背景颜色设置为白色
|
|
|
|
this.setData({
|
|
|
|
show_white:true
|
|
|
|
})
|
|
|
|
}else{
|
|
|
|
this.setData({
|
|
|
|
show_white:false
|
|
|
|
})
|
|
|
|
}
|
|
|
|
const scrollTop = event.scrollTop * 1 + this.screenHeight - 80; // 获取滚动的距离
|
|
|
|
if (scrollTop < this.screenHeight) {
|
|
|
|
this.setData({
|
|
...
|
...
|
@@ -536,7 +547,7 @@ Page({ |
|
|
|
let data = res.data
|
|
|
|
console.log('data', data);
|
|
|
|
let couponList = []
|
|
|
|
let settingUrl, inviteImgUrl, themeColor, StyleType, titleType, home, chef, marketing, coupon, reserve, swich_phone, is_comments, signboard, store;
|
|
|
|
let colors, settingUrl, inviteImgUrl, themeColor, StyleType, titleType, home, chef, marketing, coupon, reserve, swich_phone, is_comments, signboard, store;
|
|
|
|
chef = util.determine(data.chef);
|
|
|
|
reserve = util.determine(data.reserve);
|
|
|
|
marketing = util.determine(data.marketing);
|
|
...
|
...
|
@@ -551,6 +562,11 @@ Page({ |
|
|
|
inviteImgUrl = 'https://nosqn.colorcun.com/inviteText1.png';
|
|
|
|
}
|
|
|
|
settingUrl = StyleType == '12' ? 'https://nosqn.colorcun.com/template12.jpg' : 'https://nosqn.colorcun.com/template' + StyleType + '.png';
|
|
|
|
if (StyleType == '9') colors = "#0B0805";
|
|
|
|
if (StyleType == '10' || StyleType == '17') colors = "#750100";
|
|
|
|
if (StyleType == '11' || StyleType == '12') colors = "#0B1A67";
|
|
|
|
if (StyleType == '13' || StyleType == '15') colors = "#0B3133";
|
|
|
|
if (StyleType == '14' || StyleType == '16') colors = "#1B1A23";
|
|
|
|
titleType = data.title_class;
|
|
|
|
swich_phone = reserve && reserve.swich_phone ? reserve.swich_phone : '';
|
|
|
|
if (marketing) {
|
|
...
|
...
|
@@ -588,6 +604,7 @@ Page({ |
|
|
|
themeColor,
|
|
|
|
settingUrl,
|
|
|
|
inviteImgUrl,
|
|
|
|
colors,
|
|
|
|
}
|
|
|
|
console.log('获取数据', {
|
|
|
|
...obj
|
|
...
|
...
|
@@ -615,6 +632,7 @@ Page({ |
|
|
|
themeColor,
|
|
|
|
settingUrl,
|
|
|
|
inviteImgUrl,
|
|
|
|
colors,
|
|
|
|
})
|
|
|
|
// 开启语音播报
|
|
|
|
if (reserve && reserve.swich_voice == '1') {
|
...
|
...
|
|