Commit 16e8b28d by 严立

LL - UI 问题修复

parent c5299ab4
Showing with 2298 additions and 618 deletions
...@@ -78,7 +78,6 @@ Component({ ...@@ -78,7 +78,6 @@ Component({
// 属性监听 // 属性监听
observers: { observers: {
'scrollStyle': function (funcValue) { 'scrollStyle': function (funcValue) {
console.log(this.data.scrollStyle)
if (JSON.stringify(this.data.scrollStyle) === '{}') return if (JSON.stringify(this.data.scrollStyle) === '{}') return
this.setNavigationStyle() this.setNavigationStyle()
}, },
......
...@@ -113,15 +113,15 @@ ...@@ -113,15 +113,15 @@
<text>准备一份精心的礼物</text> <text>准备一份精心的礼物</text>
</view> </view>
<swiper indicator-dots="true"> <swiper indicator-dots="true">
<!-- 海错图文创店 --> <!-- 儿童营地文创店 -->
<swiper-item> <swiper-item>
<view class="shop-banner row con-c"> <view class="shop-banner row con-c">
<image src="{{resourcesBase + 'commodity/home/shop-3.png'}}"></image> <image src="{{resourcesBase + 'commodity/home/shop-4.png'}}"></image>
<button class="row con-c align-c" data-id="{{1}}" bindtap="onBuyOriginality"></button> <button class="row con-c align-c" data-id="{{3}}" bindtap="onBuyOriginality"></button>
</view> </view>
<view class="shop-menu"> <view class="shop-menu">
<block wx:for="{{shopRecommendC}}" wx:for-index="index" wx:for-item="item" wx:key="index"> <block wx:for="{{shopRecommendD}}" wx:for-index="index" wx:for-item="item" wx:key="index">
<view class="shop-menu-item col con-c align-c" data-id="{{1}}" data-item="{{item}}" bindtap="onBuyRecommendOriginality"> <view class="shop-menu-item col con-c align-c" data-id="{{3}}" data-item="{{item}}" bindtap="onBuyRecommendOriginality">
<image src="{{item.cover}}"></image> <image src="{{item.cover}}"></image>
<text>{{item.name}}</text> <text>{{item.name}}</text>
</view> </view>
...@@ -129,15 +129,18 @@ ...@@ -129,15 +129,18 @@
</view> </view>
</swiper-item> </swiper-item>
<!-- 儿童营地文创店 --> <!-- 海错图文创店 -->
<swiper-item> <swiper-item>
<view class="shop-banner row con-c"> <view class="shop-banner row con-c">
<image src="{{resourcesBase + 'commodity/home/shop-4.png'}}"></image> <image src="{{resourcesBase + 'commodity/home/shop-3.png'}}"></image>
<button class="row con-c align-c" data-id="{{3}}" bindtap="onBuyOriginality"></button> <!-- 临时屏蔽购买 -->
<!-- <button class="row con-c align-c" data-id="{{1}}" bindtap="onBuyOriginality"></button> -->
</view> </view>
<view class="shop-menu"> <view class="shop-menu">
<block wx:for="{{shopRecommendD}}" wx:for-index="index" wx:for-item="item" wx:key="index"> <block wx:for="{{shopRecommendC}}" wx:for-index="index" wx:for-item="item" wx:key="index">
<view class="shop-menu-item col con-c align-c" data-id="{{3}}" data-item="{{item}}" bindtap="onBuyRecommendOriginality"> <!-- 临时屏蔽购买 -->
<view class="shop-menu-item col con-c align-c">
<!-- <view class="shop-menu-item col con-c align-c" data-id="{{1}}" data-item="{{item}}" bindtap="onBuyRecommendOriginality"> -->
<image src="{{item.cover}}"></image> <image src="{{item.cover}}"></image>
<text>{{item.name}}</text> <text>{{item.name}}</text>
</view> </view>
......
...@@ -60,7 +60,7 @@ Page({ ...@@ -60,7 +60,7 @@ Page({
navbarTitle: '儿童营地入园购票', navbarTitle: '儿童营地入园购票',
banner: 'service/detail-banner-3.png', banner: 'service/detail-banner-3.png',
bgColor: '#F6DADA', bgColor: '#F6DADA',
buyText: '购买门票', buyText: '暂未开售',
unitText: '/人', unitText: '/人',
commodityList: [] commodityList: []
}) })
...@@ -150,7 +150,7 @@ Page({ ...@@ -150,7 +150,7 @@ Page({
'typeId': funcResponse[i].genre, // 商品分类标识 'typeId': funcResponse[i].genre, // 商品分类标识
'inventoriesId': funcResponse[i].inventoriesId, // 仓库标识 'inventoriesId': funcResponse[i].inventoriesId, // 仓库标识
'dateValid': App.modular.miment().format('YYYY.MM.DD'), // 有效时间 'dateValid': App.modular.miment().format('YYYY.MM.DD'), // 有效时间
'dateInvalid': App.modular.miment().format('YYYY.MM.DD'), // 失效时间 'dateInvalid': funcResponse[i].cardNam, // 失效时间
'name': funcResponse[i].name, 'name': funcResponse[i].name,
'cover': funcResponse[i].ticketsImg ? funcResponse[i].ticketsImg : this.data.resourcesBase + 'service/service.png', 'cover': funcResponse[i].ticketsImg ? funcResponse[i].ticketsImg : this.data.resourcesBase + 'service/service.png',
'price': funcResponse[i].sightseerPrice, // 普通价 'price': funcResponse[i].sightseerPrice, // 普通价
...@@ -334,6 +334,8 @@ Page({ ...@@ -334,6 +334,8 @@ Page({
* @returns * @returns
*/ */
onBuy: function (event) { onBuy: function (event) {
if (this.data.shopInfo.appId === 3) return
if (this.data.shopInfo.appId === 7) { if (this.data.shopInfo.appId === 7) {
this.onCommodityDetail(event) this.onCommodityDetail(event)
return return
......
...@@ -157,7 +157,7 @@ Page({ ...@@ -157,7 +157,7 @@ Page({
'typeId': funcResponse[i].genre, // 商品分类标识 'typeId': funcResponse[i].genre, // 商品分类标识
'inventoriesId': funcResponse[i].inventoriesId, // 仓库标识 'inventoriesId': funcResponse[i].inventoriesId, // 仓库标识
'dateValid': App.modular.miment().format('YYYY.MM.DD'), // 有效时间 'dateValid': App.modular.miment().format('YYYY.MM.DD'), // 有效时间
'dateInvalid': App.modular.miment().format('YYYY.MM.DD'), // 失效时间 'dateInvalid': funcResponse[i].cardNam, // 失效时间
'name': funcResponse[i].name, 'name': funcResponse[i].name,
'cover': funcResponse[i].coverImg, // 商品封面 'cover': funcResponse[i].coverImg, // 商品封面
'price': funcResponse[i].sightseerPrice, // 普通价 'price': funcResponse[i].sightseerPrice, // 普通价
......
...@@ -176,7 +176,9 @@ ...@@ -176,7 +176,9 @@
</view> </view>
<view class="commodity-list"> <view class="commodity-list">
<block wx:for="{{shopCommodityData[2]}}" wx:for-index="index" wx:for-item="item" wx:key="index"> <block wx:for="{{shopCommodityData[2]}}" wx:for-index="index" wx:for-item="item" wx:key="index">
<view class="commodity-item row" data-index="{{2}}" data-itemindex="{{index}}" bindtap="onBuy"> <view class="commodity-item row" data-index="{{2}}" data-itemindex="{{index}}">
<!-- 暂时屏蔽 -->
<!-- <view class="commodity-item row" data-index="{{2}}" data-itemindex="{{index}}" bindtap="onBuy"> -->
<view class="commodity-cover"> <view class="commodity-cover">
<image src="{{item.cover}}"></image> <image src="{{item.cover}}"></image>
</view> </view>
...@@ -226,14 +228,16 @@ ...@@ -226,14 +228,16 @@
</block> </block>
<view class="commodity-price-operation row con-e align-c"> <view class="commodity-price-operation row con-e align-c">
<button class="row con-c align-c">购买门票</button> <button class="row con-c align-c">暂未开售</button>
</view> </view>
</view> </view>
</view> </view>
</block> </block>
<block wx:for="{{shopCommodityData[3]}}" wx:for-index="index" wx:for-item="item" wx:key="index"> <block wx:for="{{shopCommodityData[3]}}" wx:for-index="index" wx:for-item="item" wx:key="index">
<view class="commodity-item row" data-index="{{3}}" data-itemindex="{{index}}" bindtap="onBuy"> <view class="commodity-item row" data-index="{{3}}" data-itemindex="{{index}}">
<!-- 暂时屏蔽按钮 -->
<!-- <view class="commodity-item row" data-index="{{3}}" data-itemindex="{{index}}" bindtap="onBuy"> -->
<view class="commodity-cover"> <view class="commodity-cover">
<image src="{{item.cover}}"></image> <image src="{{item.cover}}"></image>
</view> </view>
...@@ -283,7 +287,7 @@ ...@@ -283,7 +287,7 @@
</block> </block>
<view class="commodity-price-operation row con-e align-c"> <view class="commodity-price-operation row con-e align-c">
<button class="row con-c align-c">购买门票</button> <button class="row con-c align-c">暂未开售</button>
</view> </view>
</view> </view>
</view> </view>
......
...@@ -210,12 +210,12 @@ Page({ ...@@ -210,12 +210,12 @@ Page({
}, },
success: (response) => { success: (response) => {
console.log(response) console.log(response)
let funcResponse = response.data let funcResponse = response
if (funcResponse.code === 500) { if (response.data.code === 500) {
wx.lin.hideToast() wx.lin.hideToast()
wx.lin.showToast({ wx.lin.showToast({
image: '/image/error.png', image: '/image/error.png',
title: funcResponse.msg, title: response.data.msg,
}) })
return return
} }
......
...@@ -110,6 +110,7 @@ page { ...@@ -110,6 +110,7 @@ page {
.accumulate { .accumulate {
width: 606rpx; width: 606rpx;
height: 120rpx; height: 120rpx;
min-height: 120rpx;
padding: 20rpx 0 18rpx; padding: 20rpx 0 18rpx;
border-bottom: 1px solid #E2E7EF; border-bottom: 1px solid #E2E7EF;
} }
...@@ -131,11 +132,11 @@ page { ...@@ -131,11 +132,11 @@ page {
.accumulate-right { .accumulate-right {
font-size: 30rpx; font-size: 30rpx;
color: #E66060;
} }
.accumulate-right text { .accumulate-right text {
margin-left: 6rpx; margin-left: 6rpx;
color: #E66060;
} }
.accumulate-type-color { .accumulate-type-color {
......
let App = getApp()
Page({ Page({
data: { data: {
winToastText: '操作成功',
winToast: false,
isDoing: false,
showNotice: false,
swiperCurrent: 0,
showCodePopup: false,
imageBase: App.globalData.appImageBase,
resourcesBase: App.globalData.appResourcesBase,
shopInfo: {},
orderType: 1, // 1 - 年卡/月卡,2 - 次票, 3 - SPA, 4 - 文创, 5 - 餐品, 6 - 活动, 7 - 观影
orderInfo: {},
fromPage: '',
codeInfo: {},
isFromUse: false,
winCode: false,
residuePayTime: "", //剩余支付时间
codeList: [],
sealSrc: '',
shopConfig: App.globalData.shopId,
shopAppId: "",
activityId: '',
}, },
onLoad: function (options) { onLoad: function (options) {
let funcOrderInfo = this.data.orderInfo
funcOrderInfo.id = options.id
this.setData({
activityId: options.activityId,
shopInfo: wx.getStorageSync('shopInfoBuffer'),
orderInfo: funcOrderInfo,
shopAppId: options.shopAppId,
fromPage: options.fromPage === 'order' ? 'order' : '',
isFromUse: options.showCode === 'true' ? true : false,
})
this.queryOrderDetail()
},
// 再次下单
onOrderAgain: function (event) {
console.log(this.data.orderInfo)
let funcItem = this.data.orderInfo
funcItem.shopAppId = wx.getStorageSync('shopInfoBuffer').appId
let funcUrl = ''
App.setShopInfo(funcItem.shopAppId, funcItem.commodityType)
switch (funcItem.shopAppId) {
// 海错图
case 1:
if (funcItem.commodityType === -1) funcUrl = '/pages/play/activity/activity'
if (funcItem.commodityType === 1) funcUrl = '/pages/commodity/project-detail/project-detail'
if (funcItem.commodityType === 3) funcUrl = '/pages/commodity/project-detail/project-detail'
break
// 星空影院
case 2:
if (funcItem.commodityType === -2) funcUrl = '/pages/play/movie/movie'
break
// 儿童营地
case 3:
if (funcItem.commodityType === 1) funcUrl = '/pages/commodity/project-detail/project-detail'
if (funcItem.commodityType === 2) funcUrl = '/pages/commodity/menu-food/menu-food'
if (funcItem.commodityType === 3) funcUrl = '/pages/commodity/project-detail/project-detail'
break
// 原野MOJITO
case 4:
if (funcItem.commodityType === 5) funcUrl = '/pages/commodity/menu-food/menu-food'
break
// 拾光花坊
case 5:
if (funcItem.commodityType === -1) funcUrl = '/pages/play/activity/activity'
if (funcItem.commodityType === 5) funcUrl = '/pages/commodity/menu-food/menu-food'
break
// 原味舒食
case 6:
if (funcItem.commodityType === 5) funcUrl = '/pages/commodity/menu-food/menu-food'
break
// 元养水韵SPA
case 7:
if (funcItem.commodityType === 2) funcUrl = '/pages/commodity/project-detail/project-detail'
break
}
wx.navigateTo({
url: funcUrl,
})
},
// 去支付
onOrderPay: function (event) {
// 数据校验不通过
let wxRequest = this.data.orderInfo.wxRequest
// 待支付返回的wx支付参数
if (wxRequest) {
wx.requestPayment({
timeStamp: wxRequest.timeStamp,
nonceStr: wxRequest.nonceStr,
package: wxRequest.package,
signType: wxRequest.signType,
paySign: wxRequest.paySign,
success(res) {
this.queryOrderDetail()
},
fail(res) { }
})
}
},
// 去评价
onOrderEvaluate: function (event) {
let item = JSON.stringify(this.data.orderInfo)
wx.navigateTo({
url: `/pages/pay/order-comment/order-comment?orderItem=${item}&pageFrom=orderDetail`,
})
},
// 删除订单&取消订单
// type :1删除0取消
onDelOrCancelOrder: function (event) {
let funcItem = this.data.orderInfo
console.log(funcItem)
let type = event.currentTarget.dataset.type
let that = this
let tip = type == 1 ? '删除订单' : '取消订单'
wx.lin.showDialog({
type: 'confirm',
title: '',
content: "是否确认" + tip,
success: (res) => {
if (res.confirm) {
console.log('用户点击确定')
wx.showLoading({
title: '处理中',
mask: true
})
this.setData({
isDoing: true,
})
App.wxRequest({
url: '/api/v1/activity/doCancel',
data: {
'enrollId': this.data.activityId,
'type': type,
},
success: (response) => {
wx.hideLoading()
let winToastText = type == 1 ? '订单删除成功' : '订单取消成功'
that.setData({
isDoing: false,
winToast: true,
winToastText: winToastText
})
setTimeout(function () {
if (type == 1) {
// 删除操作
wx.navigateBack({
delta: 1
})
} else {
// 取消操作
let state = `orderInfo.state`
that.setData({
isDoing: false,
[state]: -1
})
}
}, 2000)
}
})
} else if (res.cancel) {
console.log('用户点击取消')
}
}
})
},
// 使用须知
handleNotice() {
let showNotice = true
this.setData({
showNotice
})
},
// 一键扫码
onFastScan: function (event) {
wx.showLoading({
title: '加载中',
})
App.wxRequest({
url: '/api/v1/order/getVolumesByOrderId',
data: {
'orderId': this.data.orderInfo.id
},
success: (response) => {
wx.hideLoading()
let list = response.data
this.setData({
showCodePopup: true,
codeList: list
})
}
})
},
swiperChange(e) {
let swiperCurrent = e.detail.current
this.setData({
swiperCurrent
})
},
closeQRcode() {
let showCodePopup = false
this.setData({
showCodePopup,
// swiperCurrent:0
})
},
/**
* 订单详情
* @function
* @param
* @returns
*/
queryOrderDetail: function () {
let that = this
App.wxRequest({
url: '/api/v1/order/getOrderDetail',
data: {
'orderId': this.data.orderInfo.id
},
success: (response) => {
let funcResponse = response.data
let funcOrderInfo = {
'id': this.data.orderInfo.id,
'score': funcResponse.integral, // 积分
'state': Number(funcResponse.status), // 订单状态
'amount': funcResponse.totalMoney, // 实付金额
'contactName': funcResponse.name, // 联系人名称
'contactPhone': funcResponse.mobilePhone, // 联系人电话
'commodityType': Number(funcResponse.goodType), // 商品类型
'commodity': [],
'tipOrderNo': funcResponse.orderSerialNumber, // 订单编号
'tipTimeSubmit': funcResponse.createDate,
'tipTimePay': funcResponse.paymentTime ? App.modular.miment(funcResponse.paymentTime).format('YYYY-MM-DD hh:mm:ss') : '',
'tipIntegral': funcResponse.integral,
'officeName': funcResponse.officeName,
'wxRequest': funcResponse.wxRequest,
'businessTime': funcResponse.businessTime, //营业时间
'expireTime': funcResponse.expireTime, //订单有效期
'particulars': funcResponse.particulars
}
// 设置印章
let shopName = funcResponse.officeName;
let shopFilter = this.data.shopConfig.filter(
item => {
return item.name.toLowerCase() == shopName.toLowerCase() || shopName.toLowerCase().indexOf(item.name.toLowerCase()) != -1
}
)
funcOrderInfo.shopInfo = shopFilter[0]
// 添加订单商品列表
let funcCommodity = funcResponse.smOrderDetails
for (let i = 0, l = funcCommodity.length; i < l; i++) {
let funcCommodityItem = {
'cover': funcCommodity[i].imgUrl,
'name': funcCommodity[i].name, // 名称
'quantity': funcCommodity[i].number, // 数量
'amount': funcCommodity[i].unitPrice, // 总价
'state': Number(funcCommodity[i].status), // 状态
'codeId': funcCommodity[i].volumeId, // 券码
}
funcOrderInfo.commodity.push(funcCommodityItem)
}
// 倒计时
if (funcOrderInfo.state == 0) {
// 待付款状态
let doTime = 15 * 60 * 1000
let timeInter = setInterval(() => {
let creatdTime = new Date(funcOrderInfo.tipTimeSubmit.replace(/-/g, '/')).getTime()
let endTime = creatdTime + doTime
let now = new Date().getTime()
let residueStamp = endTime - now
let residuePayTime = App.modular.miment(residueStamp).format('mm:ss')
if (residueStamp > 0) {
that.setData({
residuePayTime: residuePayTime
})
} else {
console.log(residueStamp, 'residueStamp----------------');
clearInterval(timeInter)
// that.queryOrderDetail()
let state = `orderInfo.state`
that.setData({
[state]: -1
})
}
}, 1000)
}
this.setData({
orderInfo: funcOrderInfo
})
// 判断是否自动展示二维码
// 订单列表 去使用 按钮
if (this.data.isFromUse) {
}
}
})
},
// 弹出单张二维码
onCouponCode: function (event) {
let funcOrderInfo = event.currentTarget.dataset.item
wx.showLoading({
title: '加载中',
})
App.wxRequest({
url: '/api/v1/volume/getVolume',
data: {
'volumeId': funcOrderInfo.codeId
},
success: (response) => {
wx.hideLoading({
success: (res) => { },
})
let funcResponse = response.data
let funcCodeInfo = {
'codeNo': funcResponse.serialNumber,
'codeName': funcResponse.name,
'codeBase64': funcResponse.qrcode,
}
this.setData({
codeInfo: funcCodeInfo,
winCode: true,
})
}
})
},
// 多二维码 复制券码
setClipboard(e) {
const code = e.currentTarget.dataset.code
wx.setClipboardData({
data: code,
success(res) {
wx.showToast({
title: '复制成功',
})
// wx.getClipboardData({
// success(res) {
// console.log(res.data) // data
// }
// })
}
})
},
// 单个二维码 复制券码
onCodeCopy: function () {
wx.setClipboardData({
data: this.data.codeInfo.codeNo,
})
},
onCodeClose: function () {
this.setData({
winCode: false,
})
},
navBack: function () {
if (this.data.fromPage) {
wx.switchTab({
url: '/pages/mine/home/home',
})
}
}, },
}) })
\ No newline at end of file
<!--pages/home/home/home.wxml--> <navigation class="navigation" titleText="订单详情" color="#000000" background="#FFFFFF" backIcon="/image/back.png" bind:navBack="navBack"></navigation>
<text>pages/home/home/home.wxml</text>
<view class="container padding-bottom-166">
<!-- 订单状态 -->
<view class="state row con-c">
<view class="state-content col con-c" wx:if="{{orderInfo.state === 0}}">
<view class="state-content-title row">
<text>订单待付款</text>
</view>
<view class="state-content-tip row">
<text>请在 {{residuePayTime}} 内付款,否则将自动取消订单</text>
</view>
</view>
<view class="state-content col con-c" wx:if="{{orderInfo.state === 3}}">
<view class="state-content-title row">
<text>订单待评价</text>
</view>
</view>
<view class="state-content state-content-invalid col con-c" wx:if="{{orderInfo.state === 4}}">
<view class="state-content-title row">
<text>订单已过期</text>
</view>
<view class="state-content-tip row">
<text>有效期 {{orderInfo.expireTime}}</text>
</view>
</view>
<view class="state-content state-content-invalid col con-c" wx:if="{{orderInfo.state === -1}}">
<view class="state-content-title row">
<text>订单已取消</text>
</view>
<!-- <view class="state-content-tip row">
<text>下单后15分钟内未付款,自动取消订单</text>
</view> -->
</view>
<view class="state-content state-content-invalid col con-c" wx:if="{{orderInfo.state === 6}}">
<view class="state-content-title row">
<text>订单已评价</text>
</view>
</view>
</view>
<!-- 订单信息 -->
<view class="info">
<!-- 年卡月卡 -->
<block wx:if="{{orderInfo.commodityType === 1}}">
<view class="info-content col con-c">
<view class="info-content-item row">
<text class="info-content-item-label">使用门店</text>
<text class="info-content-item-title">{{orderInfo.officeName}}</text>
</view>
<view class="info-content-item row">
<text class="info-content-item-label"></text>
<text class="info-content-item-describe">{{orderInfo.businessTime}}</text>
</view>
<image class="seal-shot" src="{{resourcesBase+orderInfo.shopInfo.print}}"></image>
</view>
</block>
<!-- 普通商品 -->
<block wx:if="{{orderInfo.commodityType === 2}}">
<view class="info-content col con-c">
<view class="info-content-item row">
<text class="info-content-item-label">使用门店</text>
<text class="info-content-item-title">{{orderInfo.officeName}}</text>
</view>
<view class="info-content-item row">
<text class="info-content-item-label"></text>
<text class="info-content-item-describe">{{orderInfo.businessTime}}</text>
</view>
<view class="info-content-item row">
<text class="info-content-item-label">订单信息</text>
<text class="info-content-item-tip">{{orderInfo.contactName}}</text>
</view>
<view class="info-content-item row">
<text class="info-content-item-label"></text>
<text class="info-content-item-tip">{{orderInfo.contactPhone}}</text>
</view>
<image wx:if="{{orderInfo.state!==2}}" class="seal-shot" src="{{resourcesBase+orderInfo.shopInfo.print}}">
</image>
</view>
<block wx:if="{{orderInfo.state===2}}">
<view class="info-line row con-b align-c">
<view class="info-line-point-left"></view>
<view class="info-line-line"></view>
<view class="info-line-point-right"></view>
<image class="seal-long" src="{{resourcesBase+orderInfo.shopInfo.printUse}}"></image>
</view>
<view class="info-code col con-c align-c">
<text>{{orderInfo.commodity.length}}件商品可用</text>
<button bindtap="onFastScan" class="row con-c align-c">一键扫码</button>
<text>{{orderInfo.expireTime}}</text>
</view>
</block>
</block>
<!-- 餐品 文创 门票-->
<block wx:if="{{orderInfo.commodityType === 5||orderInfo.commodityType === 4||orderInfo.commodityType === 3}}">
<view class="info-content col con-c {{ orderInfo.state!==2?'p-relative':'' }}">
<view class="info-content-item row">
<text class="info-content-item-label">使用门店</text>
<text class="info-content-item-title">{{orderInfo.officeName}}</text>
</view>
<view class="info-content-item row">
<text class="info-content-item-label"></text>
<text class="info-content-item-describe">{{orderInfo.businessTime}}</text>
</view>
<view class="info-content-item row">
<text class="info-content-item-label">订单信息</text>
<text class="info-content-item-tip">{{orderInfo.contactName}}</text>
</view>
<view class="info-content-item row">
<text class="info-content-item-label"></text>
<text class="info-content-item-tip">{{orderInfo.contactPhone}}</text>
</view>
<image wx:if="{{orderInfo.state!==2}}" class="seal-shot" src="{{resourcesBase+orderInfo.shopInfo.print}}">
</image>
</view>
<block wx:if="{{orderInfo.state===2}}">
<view class="info-line row con-b align-c">
<view class="info-line-point-left"></view>
<view class="info-line-line"></view>
<view class="info-line-point-right"></view>
<image class="seal-long" src="{{resourcesBase+orderInfo.shopInfo.printUse}}"></image>
</view>
<view class="info-code col con-c align-c">
<text wx:if="{{orderInfo.commodityType === 5}}">{{'1件餐品可用'}}</text>
<text wx:if="{{orderInfo.commodityType === 4}}">{{'1件商品可用'}}</text>
<text wx:if="{{orderInfo.commodityType === 3}}">{{orderInfo.commodity.length}}张门票可用</text>
<button bindtap="onFastScan" class="row con-c align-c">一键扫码</button>
<text>{{orderInfo.expireTime}}</text>
</view>
</block>
</block>
<!-- 活动 -->
<block wx:if="{{orderInfo.commodityType === -1}}">
<view class="info-content col con-c">
<view class="info-content-item row">
<text class="info-content-item-label">报名活动</text>
<text class="info-content-item-title">{{orderInfo.commodity[0].name}}</text>
</view>
<view class="info-content-item row">
<text class="info-content-item-label">活动时间</text>
<text class="info-content-item-describe">{{orderInfo.businessTime}}</text>
</view>
<view class="info-content-item row">
<text class="info-content-item-label">活动地点</text>
<text class="info-content-item-describe">{{orderInfo.officeName}}</text>
</view>
<view class="info-content-item row">
<text class="info-content-item-label">订单信息</text>
<text class="info-content-item-tip">{{orderInfo.contactName}}</text>
</view>
<view class="info-content-item row">
<text class="info-content-item-label"></text>
<text class="info-content-item-tip">{{orderInfo.contactPhone}}</text>
</view>
<image wx:if="{{orderInfo.state!==2}}" class="seal-shot" src="{{resourcesBase+orderInfo.shopInfo.print}}">
</image>
</view>
<block wx:if="{{orderInfo.state===2}}">
<view class="info-line row con-b align-c">
<view class="info-line-point-left"></view>
<view class="info-line-line"></view>
<view class="info-line-point-right"></view>
<image class="seal-long" src="{{resourcesBase+orderInfo.shopInfo.printUse}}"></image>
</view>
<view class="info-code col con-c align-c">
<text>{{orderInfo.commodity.length}}张门票可用</text>
<button bindtap="onFastScan" class="row con-c align-c">一键扫码</button>
<text>{{orderInfo.expireTime}}</text>
</view>
</block>
</block>
<!-- 观影 -->
<block wx:if="{{orderInfo.commodityType === -2}}">
<view class="info-content col con-c">
<view class="info-content-item row">
<text class="info-content-item-label">电影</text>
<text class="info-content-item-title">{{orderInfo.commodity[0].name}}</text>
</view>
<view class="info-content-item row">
<text class="info-content-item-label">场次</text>
<text class="info-content-item-describe">{{orderInfo.businessTime}}</text>
</view>
<view class="info-content-item row">
<text class="info-content-item-label">订单信息</text>
<text class="info-content-item-tip">{{orderInfo.contactName}}</text>
</view>
<view class="info-content-item row">
<text class="info-content-item-label"></text>
<text class="info-content-item-tip">{{orderInfo.contactPhone}}</text>
</view>
<image wx:if="{{orderInfo.state!==2}}" class="seal-shot" src="{{resourcesBase+orderInfo.shopInfo.print}}">
</image>
</view>
<block wx:if="{{orderInfo.state===2}}">
<view class="info-line row con-b align-c">
<view class="info-line-point-left"></view>
<view class="info-line-line"></view>
<view class="info-line-point-right"></view>
<image class="seal-long" src="{{resourcesBase+orderInfo.shopInfo.printUse}}"></image>
</view>
<view class="info-code col con-c align-c">
<text>{{orderInfo.commodity.length}}张电影票可用</text>
<button bindtap="onFastScan" class="row con-c align-c">一键扫码</button>
<text>{{orderInfo.expireTime}}</text>
</view>
</block>
</block>
</view>
<view class="notice-wrapper row con-e" bindtap="handleNotice">
<view class="notice">使用须知</view>
<!-- <view class="notice">活动须知</view>
<view class="notice">观影须知</view> -->
<l-icon name="right" color="#959DAA" size="22" />
</view>
<!-- 商品信息 -->
<view class="commodity col">
<view class="commodity-title">
<text>购买商品</text>
</view>
<view class="commodity-list">
<view class="commodity-shop-info row align-c">
<view class="logo-box">
<image src="{{resourcesBase + orderInfo.shopInfo.logo}}" mode="aspectFit"></image>
</view>
<text>{{orderInfo.officeName}}</text>
</view>
<block wx:for="{{orderInfo.commodity}}" wx:for-index="index" wx:for-item="item" wx:key="index">
<view class="commodity-item row align-c">
<image src="{{item.cover}}"></image>
<view class="commodity-item-info col">
<view>
<text>{{item.name}}</text>
</view>
<view class="row">
<text>¥</text>
<text>{{item.amount}}</text>
</view>
</view>
<view class="commodity-item-operation" wx:if="{{item.codeId}}">
<!-- 状态(0已过期1带使用2已使用) -->
<button wx:if="{{item.state==1}}" class="row con-c align-c" data-item="{{item}}" bindtap="onCouponCode">查看券码</button>
<button wx:if="{{item.state==0}}" disabled class="row con-c align-c btn-disabled">已过期</button>
<button wx:if="{{item.state==2}}" disabled class="row con-c align-c btn-disabled">已使用</button>
</view>
</view>
</block>
</view>
</view>
<!-- 订单提示 -->
<view class="tip">
<view class="tip-pay row con-b align-c">
<view class="tip-pay-title" wx:if="{{orderInfo.amount!==undefined}}">
<text wx:if="{{orderInfo.state === 0||orderInfo.state === -1}}">待付金额</text>
<text wx:else>实付金额</text>
</view>
<view class="tip-pay-amount">
<text>¥</text>
<text>{{orderInfo.amount}}</text>
</view>
</view>
<view class="tip-describe col">
<text>{{'订单编号:' +( orderInfo.tipOrderNo?orderInfo.tipOrderNo:"")}}</text>
<text>{{'下单时间:' + (orderInfo.tipTimeSubmit?orderInfo.tipTimeSubmit:'')}}</text>
<text wx:if="{{orderInfo.state !== 0 && orderInfo.state !== -1}}">{{'付款时间:' + (orderInfo.tipTimePay?orderInfo.tipTimePay:'')}}</text>
<text wx:if="{{orderInfo.state !== 0 && orderInfo.state !== -1&&orderInfo.tipIntegral}}">{{'获得积分:' + (orderInfo.tipIntegral?orderInfo.tipIntegral:'')}}</text>
</view>
</view>
</view>
<!-- 多张 扫码弹窗 -->
<l-popup show="{{showCodePopup}}" l-class="l-popup-bg">
<view class="scan-code-wrapper col align-c">
<view class="code-header" wx:if="{{orderInfo.commodityType === 5}}">{{codeList.length}}件餐品可用</view>
<view class="code-header" wx:if="{{orderInfo.commodityType === 4}}">{{codeList.length}}件商品可用</view>
<view class="code-header" wx:if="{{orderInfo.commodityType === 3}}">{{codeList.length}}张门票可用</view>
<view class="code-tips">请将券码出示给门店核销人员</view>
<swiper class="code-main" next-margin="64rpx" bindchange="swiperChange">
<swiper-item wx:for="{{codeList}}" wx:for-index="index" wx:for-item="item" wx:key="index">
<view class="code-item col con-c align-c {{index === swiperCurrent ? 'item-center' : ''}}">
<view class="code-item-title cord-title">{{item.name}}</view>
<view class="code-img">
<image mode="widthFix" src="{{'data:image/jpg;base64,'+item.qrcode}}"></image>
</view>
<view class="code-num-wrapper row align-c con-a">
<view class="code-num-title {{item.status==2 ? 'code-used' : ''}}">券码{{index+1}}:</view>
<view class="code-num {{item.status==2 ? 'code-used' : ''}}">{{item.serialNumber}}</view>
<view class="num-copy" wx:if="{{item.status!=2}}" bindtap="setClipboard" data-code="{{item.serialNumber}}" data-index="{{index}}">复制</view>
</view>
<view class="code-used-seal" wx:if="{{item.status==2}}">
<image mode="widthFix" src="{{resourcesBase+'mine/server/codeUsed.png'}}"></image>
</view>
</view>
</swiper-item>
</swiper>
<view class="img-num row align-c">
<text class="current-img-num">{{swiperCurrent+1}}</text>
<text class="symbol-img-num"> / </text>
<text class="total-img-num">{{codeList.length}}</text>
</view>
<view class="code-close-btn row con-c align-c" bindtap="closeQRcode">
<image mode="widthFix" src="/image/icon_close.png"></image>
</view>
</view>
</l-popup>
<!--单个 二维码弹窗 -->
<view class="code-mask row con-c align-c" wx:if="{{winCode}}">
<view class="code col con-c align-c">
<view class="code-tip row con-c align-c">
<text>{{'请将券码出示给门店核销人员'}}</text>
</view>
<view class="code-info col con-c align-c">
<view class="code-info-title">
<text>{{codeInfo.codeName}}</text>
</view>
<view class="code-info-qrcode">
<image src="{{'data:image/png;base64,' + codeInfo.codeBase64}}"></image>
</view>
<view class="code-info-copy row con-b align-c">
<text>券码</text>
<text>{{codeInfo.codeNo}}</text>
<text bindtap="onCodeCopy">复制</text>
</view>
</view>
<view class="code-close row con-c align-c" bindtap="onCodeClose">
<image src="{{imageBase + 'icon/close-1.png'}}"></image>
</view>
</view>
</view>
<!-- 底部按钮 -->
<view class="footer-btn row con-e" wx:if="{{orderInfo.state !== 2}}">
<!-- 状态(-1已取消,0未付款,1未发货,2待使用,3已使用,4已过期,5已发货,6已关闭/已评价) -->
<view class="delete-btn" bindtap="onDelOrCancelOrder" data-type='0' wx:if="{{orderInfo.state===0}}">取消订单</view>
<view class="order-btn" bindtap="onOrderPay" wx:if="{{orderInfo.state===0}}">去支付</view>
<view class="order-btn" bindtap="onOrderEvaluate" wx:if="{{orderInfo.state===3}}">去评价</view>
<view class="delete-btn" bindtap="onDelOrCancelOrder" data-type='1' wx:if="{{orderInfo.state===4||orderInfo.state===-1||orderInfo.state===6}}">删除订单</view>
<view class="order-btn" bindtap="onOrderAgain" wx:if="{{orderInfo.state===-1}}">再次下单</view>
</view>
<!-- 使用须知 -->
<l-popup show="{{showNotice}}" content-align="bottom">
<view class="notice-popup-wrapper">
<view class="notice-popup-title">使用须知</view>
<scroll-view scroll-y class="notice-popup-content">
<view>
<rich-text nodes="{{orderInfo.particulars}}"></rich-text>
</view>
</scroll-view>
</view>
</l-popup>
<!-- 成功提示 -->
<l-toast l-image-class="toast-image" l-class="toast-bg" show="{{winToast}}" image="/image/success.png" title="{{winToastText}}" duration="2000"></l-toast>
<!-- 确认框 -->
<l-dialog />
\ No newline at end of file
/* pages/home/home/home.wxss */ /* 订单状态 */
\ No newline at end of file
.state {
width: 750rpx;
}
.container {
margin-top: 160rpx;
}
.state-content {
width: 670rpx;
height: 240rpx;
padding: 0 32rpx;
border-radius: 4rpx;
background: #f3e1e1;
}
.state-content-invalid {
background: #ecf4f8;
}
.state-content-title text {
height: 76rpx;
font-size: 54rpx;
font-weight: 500;
line-height: 76rpx;
color: #15191f;
}
.state-content-tip {
margin-top: 24rpx;
}
.state-content-tip text {
height: 36rpx;
font-size: 26rpx;
font-weight: 400;
line-height: 36rpx;
color: #15191f;
}
/* 订单信息 */
.info {
margin-top: 50rpx;
}
.info-content {
position: relative;
width: 670rpx;
min-height: 206rpx;
padding: 48rpx 32rpx;
background: #F5F6F8;
border-radius: 4rpx;
overflow: hidden;
}
.info-content-item {
position: relative;
margin-top: 16rpx;
}
.info-content-item-label {
width: 104rpx;
height: 36rpx;
margin-right: 48rpx;
font-size: 26rpx;
font-weight: 400;
line-height: 36rpx;
color: #959da9;
}
.info-content-item-title {
position: relative;
top: -8rpx;
width: 454rpx;
min-height: 52rpx;
word-wrap: break-word;
font-size: 38rpx;
font-weight: 500;
line-height: 52rpx;
color: #15191f;
}
.info-content-item-describe {
height: 42rpx;
font-size: 30rpx;
font-weight: 500;
line-height: 42rpx;
color: #15191f;
}
.info-content-item-tip {
height: 36rpx;
font-size: 26rpx;
font-weight: 500;
line-height: 36rpx;
color: #15191f;
}
.info-line {
position: relative;
background: #F5F6F8;
}
.info-line-line {
width: 670rpx;
height: 1px;
border: 1px #e2e7ef dashed;
}
.info-line-point-left {
position: absolute;
left: -18rpx;
width: 36rpx;
height: 36rpx;
border-radius: 50%;
background: #FFFFFF;
}
.info-line-point-right {
position: absolute;
right: -18rpx;
width: 36rpx;
height: 36rpx;
border-radius: 50%;
background: #FFFFFF;
}
.info-code {
width: 670rpx;
min-height: 330rpx;
background: #F5F6F8;
}
.info-code text:nth-child(1) {
height: 48rpx;
font-size: 34rpx;
font-weight: 500;
line-height: 48rpx;
color: #15191f;
}
.info-code button {
width: 606rpx;
height: 96rpx;
margin-top: 40rpx;
border-radius: 4rpx;
background: #86c5e1;
font-size: 30rpx;
font-weight: 500;
line-height: 42rpx;
color: #FFFFFF;
}
.info-code text:nth-child(3) {
height: 36rpx;
margin-top: 40rpx;
font-size: 26rpx;
font-weight: 400;
line-height: 36rpx;
color: #959daa;
}
/* 商品信息 */
.commodity {
margin: 64rpx 40rpx 0 40rpx;
}
.commodity-title {
height: 48rpx;
font-size: 34rpx;
font-weight: 500;
line-height: 48rpx;
color: #15191f;
}
.commodity-list {
width: 670rpx;
margin-top: 40rpx;
padding: 40rpx 32rpx 0 32rpx;
border-radius: 4rpx;
background: #F5F6F8;
}
.commodity-shop-info>image {
max-width: 62rpx;
max-height: 62rpx;
margin-right: 16rpx;
}
.commodity-item {
width: 606rpx;
height: 184rpx;
border-bottom: 1px #e2e7ef solid;
}
.commodity-item>image {
width: 140rpx;
height: 136rpx;
margin-right: 24rpx;
}
.commodity-item-info {
width: 290rpx;
margin-right: 32rpx;
}
.commodity-item-operation>button {
width: 120rpx;
height: 56rpx;
border-radius: 4rpx;
background: #86c5e1;
font-size: 22rpx;
font-weight: 500;
line-height: 32rpx;
color: #FFFFFF;
}
.commodity-item-operation>button.btn-disabled {
background: #c8e1ec;
color: #FFFFFF;
}
.commodity-list .commodity-item:last-child {
border: none;
}
/* 订单提示 */
.tip {
margin: 74rpx 40rpx 70rpx 40rpx;
}
.tip-pay {
width: 670rpx;
}
.tip-pay-title text {
height: 48rpx;
font-size: 34rpx;
font-weight: 800;
line-height: 48rpx;
color: #15191f;
}
.tip-pay-amount text:nth-child(1) {
height: 58rpx;
font-size: 34rpx;
font-weight: 500;
line-height: 48rpx;
color: #5db5dd;
}
.tip-pay-amount text:nth-child(2) {
height: 58rpx;
font-size: 42rpx;
font-weight: 500;
line-height: 48rpx;
color: #5db5dd;
}
.tip-describe {
width: 670rpx;
height: 168rpx;
margin-top: 32rpx;
font-size: 22rpx;
font-weight: 400;
line-height: 42rpx;
color: #959da9;
}
/* 券码 */
.code-mask {
position: fixed;
top: 0;
left: 0;
width: 100%;
height: 100%;
background: rgba(0, 0, 0, 0.6);
}
.code {
padding: 56rpx 40rpx 64rpx 40rpx;
}
.code-tip text:nth-child(1) {
height: 36rpx;
font-size: 26rpx;
font-weight: 500;
line-height: 36rpx;
color: #FFFFFF;
}
.code-tip text:nth-child(2) {
height: 42rpx;
margin-top: 28rpx;
font-size: 30rpx;
font-weight: 400;
line-height: 42rpx;
color: #FFFFFF;
}
.code-info-qrcode {
margin-top: 56rpx;
}
.code-info-qrcode>image {
display: block;
width: 296rpx;
height: 296rpx;
}
.code-info {
width: 526rpx;
height: 666rpx;
margin-top: 56rpx;
border-radius: 4rpx;
background: #FFFFFF;
}
.code-info-copy {
width: 446rpx;
height: 96rpx;
margin-top: 56rpx;
padding: 0 24rpx;
border-radius: 4rpx;
background: #f2f3f5;
}
.code-info-copy text:nth-child(1) {
height: 36rpx;
font-size: 26rpx;
font-weight: 500;
line-height: 36rpx;
color: #959da9;
}
.code-info-copy text:nth-child(2) {
height: 36rpx;
font-size: 26rpx;
font-weight: 500;
line-height: 36rpx;
color: #15191f;
}
.code-info-copy text:nth-child(3) {
height: 36rpx;
font-size: 26rpx;
font-weight: 500;
line-height: 36rpx;
color: #5db5dd;
}
.code-close {
width: 80rpx;
height: 80rpx;
margin-top: 48rpx;
border-radius: 50%;
background: #a9a8a7;
}
.code-close>image {
width: 48rpx;
height: 48rpx;
}
/* 印章图 */
.seal-shot {
width: 166rpx;
height: 166rpx;
position: absolute;
right: -30rpx;
bottom: -30rpx;
}
.seal-long {
width: 166rpx;
height: 200rpx;
position: absolute;
right: 0;
bottom: -30rpx;
}
.p-relative {
position: relative;
}
/* 扫码弹窗 */
.order-status {
width: 670rpx;
height: 240rpx;
margin: 64rpx auto 0;
padding-left: 32rpx;
color: #15191f;
background: #ecf4f8;
}
.status-text {
font-size: 54rpx;
font-weight: 600;
}
.status-tips {
margin-top: 24rpx;
}
.bgPink {
background: #f3e1e1;
}
.ticket-wrapper {
width: 670rpx;
margin: 64rpx auto 0;
}
.ticket-main {
position: relative;
width: 100%;
padding: 48rpx 32rpx 46rpx;
background: #F5F6F8;
border-bottom: 1px dashed #e2e7ef;
}
.ticket-left {
width: 152rpx;
display: table-cell;
vertical-align: bottom;
font-size: 26rpx;
color: #959da9;
}
.ticket-right {
flex: 1;
font-size: 26rpx;
}
.ticket-store {
font-size: 38rpx;
color: #15191f;
font-weight: 600;
}
.ticket-row-time, .ticket-row-phone {
margin-top: 16rpx;
}
.ticket-time, .ticket-address, .ticket-date {
font-size: 30rpx;
line-height: 42rpx;
}
.ticket-info {
margin-top: 48rpx;
}
.seal-wrapper {
position: absolute;
right: 0;
bottom: -32rpx;
width: 166rpx;
height: 200rpx;
}
.seal {
width: 100%;
height: 100%;
}
.circle {
position: absolute;
left: -18rpx;
bottom: -18rpx;
width: 36rpx;
height: 36rpx;
border-radius: 50%;
background: #FFFFFF;
}
.ticket-footer {
padding: 50rpx 32rpx 24rpx;
background: #F5F6F8;
}
.ticket-footer-top {
font-size: 34rpx;
color: #15191f;
}
.ticket-footer-middle {
width: 606rpx;
height: 96rpx;
line-height: 96rpx;
margin: 40rpx 0;
color: #FFFFFF;
text-align: center;
background: #86c5e1;
border-radius: 4rpx;
}
.ticket-footer-bottom {
font-size: 26rpx;
color: #959daa;
}
.code-header {
height: 70rpx;
color: #FFFFFF;
font-size: 30rpx;
text-align: center;
}
.code-tips {
height: 92rpx;
color: #FFFFFF;
font-size: 26rpx;
text-align: center;
}
.code-main {
width: 750rpx;
height: 666rpx;
}
.code-item {
position: relative;
width: 526rpx;
height: 666rpx;
background: #FFFFFF;
border-radius: 4rpx;
}
.item-center {
margin-left: 112rpx;
}
.notice-popup-content {
max-height: 896rpx;
}
.code-item-title {
color: #15191f;
font-size: 30rpx;
font-weight: 600;
}
.cord-title {
padding: 0 20rpx;
}
.code-img {
width: 296rpx;
height: 296rpx;
margin: 56rpx 0;
}
.code-num-wrapper {
width: 446rpx;
height: 96rpx;
padding: 0 24rpx;
background: #f2f3f5;
border-radius: 4rpx;
line-height: 96rpx;
}
.code-num-title {
color: #959da9;
text-decoration: none !important;
font-size: 26rpx;
}
.code-num {
color: #15191f;
font-size: 30rpx;
}
.code-used {
color: #c2c7cf;
text-decoration: line-through;
}
.num-copy {
color: #5db5dd;
font-size: 26rpx;
}
.code-used-seal {
position: absolute;
right: -68rpx;
transform: translateY(56rpx);
width: 254rpx;
height: 254rpx;
}
.img-num {
margin-top: 54rpx;
}
.current-img-num {
color: #FFFFFF;
font-size: 34rpx;
}
.symbol-img-num, .total-img-num {
color: #979797;
font-size: 26rpx;
}
.code-close-btn {
width: 80rpx;
height: 80rpx;
margin-top: 35rpx;
background: rgba(254, 252, 249, 0.5);
border-radius: 50%;
}
.code-close-btn image {
width: 60%;
}
.l-popup-bg {
background: rgba(0, 0, 0, 0.4);
}
.tips-wrapper {
margin: 40rpx 40rpx 0;
}
.notice-wrapper {
width: 100%;
height: 100rpx;
padding: 0 40rpx;
line-height: 100rpx;
}
.notice {
margin-right: 8rpx;
color: #15191f;
font-size: 26rpx;
}
.notice-popup-wrapper {
padding: 56rpx 40rpx 68rpx;
background: #FFFFFF;
border-radius: 24rpx 24rpx 0 0;
}
.notice-popup-title {
width: 100%;
height: 90rpx;
}
.notice-content {
max-height: 896rpx;
}
.goods-wrapper {
padding: 32rpx 40rpx 0;
}
.goods-title {
color: #15191f;
font-size: 34rpx;
font-weight: 600;
}
.goods-list {
margin-top: 40rpx;
padding: 0 32rpx 14rpx;
background: #f5f6f8;
}
.goods-list-title-wrapper {
width: 100%;
height: 132rpx;
}
.goods-list-title-img {
min-width: 40rpx;
min-height: 54rpx;
max-width: 74rpx;
max-height: 74rpx;
}
.goods-list-title {
margin-left: 16rpx;
color: #15191f;
font-size: 26rpx;
font-weight: 600;
}
.goods-item {
margin-bottom: 22rpx;
padding-bottom: 22rpx;
border-bottom: 1px solid #e2e7ef;
}
.goods-item:last-child {
margin-bottom: 0rpx;
border-bottom: none;
}
.goods-item-img {
width: 140rpx;
height: 136rpx;
}
.goods-item-info {
flex: 1;
padding-left: 24rpx;
}
.goods-item-info-text {
color: #15191f;
font-size: 26rpx;
font-weight: 600;
display: -webkit-box;
overflow: hidden;
-webkit-box-orient: vertical;
-webkit-line-clamp: 2;
}
.goods-item-info-price {
color: #15191f;
font-weight: 600;
}
.price-symbol {
font-size: 22rpx;
}
.price {
font-size: 26rpx;
}
.goods-item-btn {
width: 120rpx;
height: 56rpx;
margin-top: 40rpx;
margin-left: 32rpx;
color: #FFFFFF;
font-size: 22rpx;
text-align: center;
line-height: 56rpx;
background: #86c5e1;
border-radius: 4rpx;
}
.disabled {
background: #c8e1ec;
}
.order-info-wrapper {
position: relative;
width: 670rpx;
margin: 64rpx 40rpx 64rpx;
}
.order-price {
position: absolute;
top: 0;
right: 0;
width: 134rpx;
height: 58rpx;
color: #5db5dd;
font-size: 34rpx;
font-weight: 600;
}
.order-price-symbol {
font-size: 30rpx;
}
.order-title {
width: 100%;
line-height: 68rpx;
font-size: 34rpx;
font-weight: 600;
}
.order-info {
margin-top: 22rpx;
}
.order-item {
width: 100%;
color: #959da9;
font-size: 22rpx;
line-height: 42rpx;
}
.padding-bottom-166 {
padding-bottom: 166rpx;
}
.footer-btn {
position: fixed;
bottom: 0;
width: 100%;
background: #FFFFFF;
padding: 32rpx 20rpx;
border-top: 1px solid #e2e7ef;
}
.delete-btn, .order-btn {
width: 200rpx;
line-height: 96rpx;
margin-right: 24rpx;
border-radius: 4rpx;
font-size: 30rpx;
font-weight: 600;
text-align: center;
}
.delete-btn {
color: #656e7b;
background: #FFFFFF;
border: 1px solid #c2c7cf;
}
.order-btn {
color: #FFFFFF;
background: #86c5e1;
}
image {
width: 100%;
height: 100%;
}
.logo-box {
width: 100rpx;
height: 80rpx;
line-height: 80rpx;
text-align: center;
margin-right: 20rpx;
}
.logo-box image {
max-width: 100%;
max-height: 100%;
}
// pages/myAppointment/myAppointment.js
const App = getApp() const App = getApp()
let logicData = { let logicData = {
...@@ -7,10 +6,6 @@ let logicData = { ...@@ -7,10 +6,6 @@ let logicData = {
} }
Page({ Page({
/**
* 页面的初始数据
*/
data: { data: {
isLoading: false, isLoading: false,
isFinished: false, isFinished: false,
...@@ -50,29 +45,11 @@ Page({ ...@@ -50,29 +45,11 @@ Page({
// 订单状态(-1已取消, 0未付款, 2待使用, 3已使用, 4已过期 6已关闭) // 订单状态(-1已取消, 0未付款, 2待使用, 3已使用, 4已过期 6已关闭)
// 活动状态(0 未开始 1进行中 2 已结束) // 活动状态(0 未开始 1进行中 2 已结束)
activityList: [], activityList: [],
data: [ // 假数据数组,type=0入园预约,type=1 看房预约 data: [],
// {
// title: '夜间入园预约',
// type: '0',
// time: '6月30日 20:00-24:00',
// num: 3,
// url: 'http://upload.miaomiao-bao.com/36acd202008141719598303.jpg'
// },
// {
// title: '看房预约',
// type: '1',
// time: '6月30日',
// num: 3,
// url: ' http://upload.miaomiao-bao.com/4c644202008141702599692.jpg'
// },
],
active: 0, active: 0,
height: 0, height: 0,
}, },
/**
* 生命周期函数--监听页面加载
*/
onLoad: function (options) { onLoad: function (options) {
let type = options.tab ? 1 * options.tab : 0 let type = options.tab ? 1 * options.tab : 0
this.setData({ this.setData({
...@@ -85,12 +62,29 @@ Page({ ...@@ -85,12 +62,29 @@ Page({
} else { } else {
this.getList(type) this.getList(type)
} }
},
onShow: function () {
this.setData({
pageNo: 1,
pageSize: 10,
data: [],
activityList: [],
})
let type = this.data.option.tab ? 1 * this.data.option.tab : 0
if (type === 0) {
this.getActivity()
} else {
this.getList(type)
}
}, },
// 去使用 // 去使用
onOrderUse: function (event) { onOrderUse: function (event) {
this.onOrderDetail(event) this.onOrderDetail(event)
}, },
/** /**
* 订单评价 * 订单评价
* @function * @function
...@@ -103,17 +97,17 @@ Page({ ...@@ -103,17 +97,17 @@ Page({
url: `/pages/pay/order-comment/order-comment?orderItem=${item}&pageFrom=activityList`, url: `/pages/pay/order-comment/order-comment?orderItem=${item}&pageFrom=activityList`,
}) })
}, },
// 跳转详情页面 // 跳转详情页面
onOrderDetail: function (event) { onOrderDetail: function (event) {
let funcItem = event.currentTarget.dataset.item let funcItem = event.currentTarget.dataset.item
wx.navigateTo({ wx.navigateTo({
url: '/pages/pay/order-detail/order-detail?id=' + funcItem.orderId, url: '/pages/mine/appointment-detail/appointment-detail?id=' + funcItem.orderId + '&activityId=' + funcItem.enrollId,
}) })
}, },
// 点击导航切换,默认是全部的 // 点击导航切换,默认是全部的
chageNav(e) { chageNav(e) {
let index = e.currentTarget.dataset.index let index = e.currentTarget.dataset.index
console.log(index, 'nav----------');
if (index === 0) { if (index === 0) {
this.setData({ this.setData({
pageNo: 1, pageNo: 1,
...@@ -128,26 +122,18 @@ Page({ ...@@ -128,26 +122,18 @@ Page({
active: index active: index
}) })
}, },
/** /**
* 订单支付 * 订单支付
* @function * @function
* @param * @param
* @returns * @returns
*/ */
onOrderPay: function (event) { onOrderPay: function (event) {
// 数据校验不通过 // 数据校验不通过
let that = this
console.log();
let funcItem = event.currentTarget.dataset.item let funcItem = event.currentTarget.dataset.item
console.log(funcItem, 'jjjj');
let wxRequest = funcItem.wxRequest let wxRequest = funcItem.wxRequest
// 待支付返回的wx支付参数 // 待支付返回的wx支付参数
if (wxRequest) { if (wxRequest) {
wx.requestPayment({ wx.requestPayment({
...@@ -157,20 +143,19 @@ Page({ ...@@ -157,20 +143,19 @@ Page({
signType: wxRequest.signType, signType: wxRequest.signType,
paySign: wxRequest.paySign, paySign: wxRequest.paySign,
success(res) { success(res) {
that.setData({ this.setData({
'orderList': [], 'orderList': [],
'orderPages': 1, 'orderPages': 1,
}) })
that.queryOrder() this.queryOrder()
}, },
fail(res) {} fail(res) {}
}) })
} }
}, },
//预约凭证 //预约凭证
gohotelAccommodation(e) { gohotelAccommodation(e) {
wx.navigateTo({ wx.navigateTo({
url: '/pages/mine/appointment-ticket/appointment-ticket?detail=' + JSON.stringify(e.currentTarget.dataset.item), url: '/pages/mine/appointment-ticket/appointment-ticket?detail=' + JSON.stringify(e.currentTarget.dataset.item),
}) })
...@@ -269,12 +254,10 @@ Page({ ...@@ -269,12 +254,10 @@ Page({
} }
} }
}) })
}, },
// 我的活动 // 我的活动
getActivity: function () { getActivity: function () {
if (this.data.isFinished) return if (this.data.isFinished) return
let that = this
wx.showLoading({ wx.showLoading({
title: '加载中', title: '加载中',
mask: true mask: true
...@@ -285,43 +268,43 @@ Page({ ...@@ -285,43 +268,43 @@ Page({
App.wxRequest({ App.wxRequest({
url: '/api/v1/activity/getMyActivityList', url: '/api/v1/activity/getMyActivityList',
data: { data: {
activeState: '', //""全部 0 未开始 1进行中 2已结束 'activeState': '', //""全部 0 未开始 1进行中 2已结束
pageSize: this.data.pageSize, 'pageSize': this.data.pageSize,
pageNo: this.data.pageNo, 'pageNo': this.data.pageNo,
type: '1' 'type': '1'
}, },
success: function (res) { success: (res) => {
that.setData({ this.setData({
isLoading: false isLoading: false
}) })
wx.hideLoading({ wx.hideLoading({
success: (res) => {}, success: (res) => {},
}) })
let funcData = res.data.list let funcData = res.data.list
if (funcData.length < that.data.pageSize) { if (funcData.length < this.data.pageSize) {
that.setData({ this.setData({
isFinished: true isFinished: true
}) })
} }
let tmpArr = [] let tmpArr = []
funcData.forEach(item => { funcData.forEach(item => {
let obj = { let obj = {
orderId: item.orderId, 'orderId': item.orderId,
enrollId: item.enrollId, 'enrollId': item.enrollId,
name: item.name, 'name': item.name,
status: item.status, // 订单状态(-1已取消, 0未付款, 2待使用, 3已使用, 4已过期 6已关闭) 'status': item.status, // 订单状态(-1已取消, 0未付款, 2待使用, 3已使用, 4已过期 6已关闭)
activeState: item.activeState, // 活动状态(0 未开始 1进行中 2 已结束) 'activeState': item.activeState, // 活动状态(0 未开始 1进行中 2 已结束)
cover: item.cover, 'cover': item.cover,
date: item.activeTime, 'date': item.activeTime,
address: item.address, 'address': item.address,
num: item.number, 'num': item.number,
amount: item.totalMoney.toFixed(2), 'amount': item.totalMoney.toFixed(2),
wxRequest: item.wxRequest 'wxRequest': item.wxRequest
} }
tmpArr.push(obj) tmpArr.push(obj)
}) })
that.setData({ this.setData({
activityList: that.data.activityList.concat(tmpArr), activityList: this.data.activityList.concat(tmpArr),
isLoading: false isLoading: false
}) })
} }
...@@ -353,8 +336,7 @@ Page({ ...@@ -353,8 +336,7 @@ Page({
state: 1, //未过期 1,其他 空字符"" state: 1, //未过期 1,其他 空字符""
type: type //0 入园预约 1 看房预约 全部 空字符 type: type //0 入园预约 1 看房预约 全部 空字符
}, },
success: function (res) { success: (res) => {
wx.hideLoading({ wx.hideLoading({
success: (res) => {}, success: (res) => {},
}) })
......
<!--pages/myAppointment/myAppointment.wxml--> <!--pages/myAppointment/myAppointment.wxml-->
<navigation class="navigation" titleText="我的预约" backIcon="/image/back.png" scrollStyle="{{navigationStyle}}" <navigation class="navigation" titleText="我的预约" backIcon="/image/back.png" scrollStyle="{{navigationStyle}}" scrollHeight="{{navigationScroll}}" bind:navBack="onNavBack"></navigation>
scrollHeight="{{navigationScroll}}" bind:navBack="onNavBack"></navigation>
<view class="container all"> <view class="container all">
<view class="myActivity-container" style="min-height:{{height}}px;"> <view class="myActivity-container" style="min-height:{{height}}px;">
<view class="myAppointment-nav"> <view class="myAppointment-nav">
<!-- 遍历头部导航 --> <!-- 遍历头部导航 -->
<view bindtap="chageNav" data-index="{{index}}" wx:for="{{navItem}}" wx:key="index" <view bindtap="chageNav" data-index="{{index}}" wx:for="{{navItem}}" wx:key="index" class="navItem {{index == active? 'active':''}}">{{item.content}}</view>
class="navItem {{index == active? 'active':''}}">{{item.content}}</view>
</view> </view>
<!-- 主题活动 --> <!-- 主题活动 -->
<view class="myAppointment-body" wx:if="{{activityList.length > 0 && active === 0}}"> <view class="myAppointment-body" wx:if="{{activityList.length > 0 && active === 0}}">
<block wx:for="{{activityList}}" wx:for-item="activity" wx:for-index="indexActivity" wx:key="orderId"> <block wx:for="{{activityList}}" wx:for-item="activity" wx:for-index="indexActivity" wx:key="index">
<!-- 待付款 --> <!-- 待付款 -->
<view class="appointment-wrapper" wx:if="{{activity.status === '0'}}" bindtap="onOrderDetail" <view class="appointment-wrapper" wx:if="{{activity.status === '0'}}" bindtap="onOrderDetail" data-item="{{activity}}">
data-item="{{activity}}">
<view class="appointment-time">{{activity.date}}</view> <view class="appointment-time">{{activity.date}}</view>
<view class="appintment-activity-status-pay"> <view class="appintment-activity-status-pay">
<text>待付款</text> <text>待付款</text>
...@@ -47,8 +44,7 @@ ...@@ -47,8 +44,7 @@
</view> </view>
</view> </view>
<!-- 未开始 --> <!-- 未开始 -->
<view class="appointment-wrapper" wx:if="{{activity.status === '2' && activity.activeState === '0'}}" <view class="appointment-wrapper" wx:if="{{activity.status === '2' && activity.activeState === '0'}}" bindtap="onOrderDetail" data-item="{{activity}}">
bindtap="onOrderDetail" data-item="{{activity}}">
<view class="appointment-time">{{activity.date}}</view> <view class="appointment-time">{{activity.date}}</view>
<view class="appintment-activity-status"> <view class="appintment-activity-status">
<text>未开始</text> <text>未开始</text>
...@@ -80,8 +76,7 @@ ...@@ -80,8 +76,7 @@
</view> </view>
</view> </view>
<!-- 进行中 --> <!-- 进行中 -->
<view class="appointment-wrapper" wx:if="{{activity.status === '2' && activity.activeState === '1'}}" <view class="appointment-wrapper" wx:if="{{activity.status === '2' && activity.activeState === '1'}}" bindtap="onOrderDetail" data-item="{{activity}}">
bindtap="onOrderDetail" data-item="{{activity}}">
<view class="appointment-time">{{activity.date}}</view> <view class="appointment-time">{{activity.date}}</view>
<view class="appintment-activity-status"> <view class="appintment-activity-status">
<text>进行中</text> <text>进行中</text>
...@@ -113,8 +108,7 @@ ...@@ -113,8 +108,7 @@
</view> </view>
</view> </view>
<!-- 待评价 --> <!-- 待评价 -->
<view class="appointment-wrapper" wx:if="{{activity.status === '3' && activity.activeState === '2'}}" <view class="appointment-wrapper" wx:if="{{activity.status === '3' && activity.activeState !== '0'}}" bindtap="onOrderDetail" data-item="{{activity}}">
bindtap="onOrderDetail" data-item="{{activity}}">
<view class="appointment-time">{{activity.date}}</view> <view class="appointment-time">{{activity.date}}</view>
<view class="appintment-activity-status"> <view class="appintment-activity-status">
<text>待评价</text> <text>待评价</text>
...@@ -146,8 +140,8 @@ ...@@ -146,8 +140,8 @@
</view> </view>
</view> </view>
<!-- 已过期 --> <!-- 已过期 -->
<view class="appointment-wrapper" wx:if="{{activity.status === '4'||activity.status === '6'}}"> <view class="appointment-wrapper" wx:if="{{activity.status === '4'||activity.status === '6'}}" bindtap="onOrderDetail" data-item="{{activity}}">
<view wx:if="{{activity.status === '4'}}" class="mask-cancel" bindtap="onOrderDetail" data-item="{{activity}}"></view> <view wx:if="{{activity.status === '4'}}" class="mask-cancel"></view>
<view class="appointment-time mask-cancel-time">{{activity.date}}</view> <view class="appointment-time mask-cancel-time">{{activity.date}}</view>
<view class="appintment-activity-status-cancel"> <view class="appintment-activity-status-cancel">
<text wx:if="{{activity.status === '4'}}">已过期</text> <text wx:if="{{activity.status === '4'}}">已过期</text>
...@@ -218,8 +212,7 @@ ...@@ -218,8 +212,7 @@
</view> </view>
<!-- 夜间入园预约、看房预约 --> <!-- 夜间入园预约、看房预约 -->
<view class="myAppointment-body" wx:if="{{data.length > 0 && active !== 0}}"> <view class="myAppointment-body" wx:if="{{data.length > 0 && active !== 0}}">
<view class="myAppointment-item" wx:for="{{data}}" wx:key="index" data-item="{{item}}" <view class="myAppointment-item" wx:for="{{data}}" wx:key="index" data-item="{{item}}" bindtap="gohotelAccommodation">
bindtap="gohotelAccommodation">
<image src="{{item.url}}" class="item-img"></image> <image src="{{item.url}}" class="item-img"></image>
<view class="item-content"> <view class="item-content">
<view class="item-title {{item.type == 0 ?'item-num-1' : ''}}">{{item.title}}</view> <view class="item-title {{item.type == 0 ?'item-num-1' : ''}}">{{item.title}}</view>
...@@ -251,7 +244,7 @@ ...@@ -251,7 +244,7 @@
<l-toast l-image-class="toast-image"></l-toast> <l-toast l-image-class="toast-image"></l-toast>
<wxs module="m1"> <wxs module="m1">
var getDate = function (date, type) { var getDate = function(date, type) {
return date.substring(5, 11).replace('-', '月').replace(' ', '日') + ((type == 0) ? ' 20:00-24:00' : ''); return date.substring(5, 11).replace('-', '月').replace(' ', '日') + ((type == 0) ? ' 20:00-24:00' : '');
} }
module.exports.getDate = getDate; module.exports.getDate = getDate;
......
...@@ -77,9 +77,14 @@ ...@@ -77,9 +77,14 @@
.mine-info view:nth-child(1) text { .mine-info view:nth-child(1) text {
z-index: 11; z-index: 11;
max-width: 260rpx;
margin-right: 20rpx; margin-right: 20rpx;
font-size: 42rpx; font-size: 42rpx;
font-weight: bolder; font-weight: 500;
overflow: hidden;
white-space: nowrap;
text-overflow: ellipsis;
} }
.padding-l-18 { .padding-l-18 {
...@@ -218,7 +223,7 @@ ...@@ -218,7 +223,7 @@
width: 750rpx; width: 750rpx;
/* margin-top: 16rpx; */ /* margin-top: 16rpx; */
margin-bottom: 30rpx; margin-bottom: 30rpx;
padding: 0 48rpx; padding: 0 40rpx;
overflow-x: hidden; overflow-x: hidden;
} }
...@@ -744,4 +749,4 @@ image { ...@@ -744,4 +749,4 @@ image {
.logo-box image { .logo-box image {
max-width: 100% !important; max-width: 100% !important;
max-height: 100% !important; max-height: 100% !important;
} }
\ No newline at end of file
...@@ -52,7 +52,7 @@ Page({ ...@@ -52,7 +52,7 @@ Page({
let funcType = event.target.dataset.type let funcType = event.target.dataset.type
let funcValue = event.detail.value let funcValue = event.detail.value
let funcUserInfo = wx.getStorageSync('userInfo') let funcUserInfo = this.data.userInfo
switch (funcType) { switch (funcType) {
case 'name': case 'name':
funcUserInfo.name = funcValue funcUserInfo.name = funcValue
...@@ -125,11 +125,10 @@ Page({ ...@@ -125,11 +125,10 @@ Page({
address: this.data.userInfo.address, address: this.data.userInfo.address,
birthday: this.data.userInfo.birthday, birthday: this.data.userInfo.birthday,
} }
console.log(param)
App.wxRequest({ App.wxRequest({
url: '/api/v1/smUser/doUpdateInfo', url: '/api/v1/smUser/doUpdateInfo',
data: param, data: param,
success: function (res) { success: (res) => {
let funcUserInfo = wx.getStorageSync('userInfo') let funcUserInfo = wx.getStorageSync('userInfo')
Object.assign(funcUserInfo, param) Object.assign(funcUserInfo, param)
wx.setStorageSync('userInfo', funcUserInfo) wx.setStorageSync('userInfo', funcUserInfo)
......
{ {
"usingComponents": {} "usingComponents": {}
} }
\ No newline at end of file
/* pages/myInfo/myInfo.wxss */ .myInfo {
.myInfo{ width: 750rpx;
width: 750rpx; margin-top: 170rpx;
margin-top: 60rpx;
padding: 0 48rpx; padding: 0 48rpx;
padding-top: 90rpx;
} }
.phone{
color: rgb(177, 176, 182); .phone {
color: rgb(177, 176, 182);
} }
.input-picker{
width: 400rpx; .input-picker {
height: 44rpx; width: 400rpx;
height: 44rpx;
} }
.picker{
text-align: right; .picker {
line-height: 44rpx; text-align: right;
line-height: 44rpx;
} }
\ No newline at end of file
...@@ -43,6 +43,10 @@ Page({ ...@@ -43,6 +43,10 @@ Page({
}) })
}, },
onShow: function () { onShow: function () {
this.setData({
orderPages: 1,
orderList: [],
})
this.setOrderType() this.setOrderType()
}, },
refresh: function () { refresh: function () {
...@@ -170,7 +174,6 @@ Page({ ...@@ -170,7 +174,6 @@ Page({
'type': 'order_good_type', 'type': 'order_good_type',
}, },
success: (response) => { success: (response) => {
let funcResponse = response.data let funcResponse = response.data
let funcList = [{ let funcList = [{
'value': '', 'value': '',
...@@ -201,10 +204,6 @@ Page({ ...@@ -201,10 +204,6 @@ Page({
funcItem.name = "文创" funcItem.name = "文创"
funcList.push(funcItem) funcList.push(funcItem)
} }
} }
let typeTitle = '全部分类' // let typeTitle = '全部分类' //
let orderTypeActive = 0 // let orderTypeActive = 0 //
...@@ -214,7 +213,6 @@ Page({ ...@@ -214,7 +213,6 @@ Page({
typeTitle = item.name typeTitle = item.name
orderTypeActive = index orderTypeActive = index
} }
}) })
// if (filter.length > 0) { // if (filter.length > 0) {
...@@ -224,9 +222,8 @@ Page({ ...@@ -224,9 +222,8 @@ Page({
this.setData({ this.setData({
'orderType': funcList, 'orderType': funcList,
orderTypeTitle: typeTitle, 'orderTypeTitle': typeTitle,
orderTypeActive orderTypeActive
}) })
this.queryOrder() this.queryOrder()
} }
...@@ -560,11 +557,12 @@ Page({ ...@@ -560,11 +557,12 @@ Page({
case 1: case 1:
if (funcItem.commodityType === 1) funcUrl = '/pages/commodity/project-detail/project-detail' if (funcItem.commodityType === 1) funcUrl = '/pages/commodity/project-detail/project-detail'
if (funcItem.commodityType === 3) funcUrl = '/pages/commodity/project-detail/project-detail' if (funcItem.commodityType === 3) funcUrl = '/pages/commodity/project-detail/project-detail'
if (funcItem.commodityType === 4) funcUrl = '/pages/commodity/menu-food/menu-food'
break break
// 星空影院 // 星空影院
case 2: case 2:
if (funcItem.commodityType === -2) funcUrl = '/pages/play/movie/movie'
break break
// 儿童营地 // 儿童营地
...@@ -572,6 +570,7 @@ Page({ ...@@ -572,6 +570,7 @@ Page({
if (funcItem.commodityType === 1) funcUrl = '/pages/commodity/project-detail/project-detail' if (funcItem.commodityType === 1) funcUrl = '/pages/commodity/project-detail/project-detail'
if (funcItem.commodityType === 2) funcUrl = '/pages/commodity/menu-food/menu-food' if (funcItem.commodityType === 2) funcUrl = '/pages/commodity/menu-food/menu-food'
if (funcItem.commodityType === 3) funcUrl = '/pages/commodity/project-detail/project-detail' if (funcItem.commodityType === 3) funcUrl = '/pages/commodity/project-detail/project-detail'
if (funcItem.commodityType === 4) funcUrl = '/pages/commodity/menu-food/menu-food'
break break
// 原野MOJITO // 原野MOJITO
......
<navigation class="navigation" titleText="订单评价" background="#ffffff" backIcon="/image/back.png"></navigation> <navigation class="navigation" titleText="订单评价" background="#ffffff" backIcon="/image/back.png"></navigation>
<view class="container con-s"> <view class="container con-s">
<view class="order-wrapper"> <view class="order-wrapper">
<view class="order-title"> <view class="order-title">
<text>购买商品</text> <text>购买商品</text>
</view> </view>
<view class="row align-c"> <view class="row align-c">
<block wx:for="{{orderInfo.commodity}}" wx:key="id"> <block wx:for="{{orderInfo.commodity}}" wx:key="id">
<view class="order-cover"> <view class="order-cover">
<image src="{{item.cover}}"></image> <image src="{{item.cover}}"></image>
</view> </view>
</block> </block>
<view class="order-name" wx:if="{{orderInfo.commodity.length === 1}}"> <view class="order-name" wx:if="{{orderInfo.commodity.length === 1}}">
<text>{{orderInfo.commodity[0].name}}</text> <text>{{orderInfo.commodity[0].name}}</text>
</view> </view>
<view class="order-price-wrapper col align-e"> <view class="order-price-wrapper col align-e">
<view class="order-price"> <view class="order-price">
<text class="price-symbol">¥</text> <text class="price-symbol">¥</text>
<text>{{orderInfo.amount}}</text> <text>{{orderInfo.amount}}</text>
</view> </view>
<view class="order-quantity"> <view class="order-quantity">
<text>{{'共' + orderInfo.commodity.length + '件'}}</text> <text>{{'共' + orderInfo.commodity.length + '件'}}</text>
</view> </view>
</view> </view>
</view> </view>
</view> </view>
<view class="order-comment-wrapper"> <view class="order-comment-wrapper">
<view class="order-comment-title"> <view class="order-comment-title">
<text>订单评价</text> <text>订单评价</text>
</view> </view>
<view class="score-wrapper row align-c"> <view class="score-wrapper row align-c">
<view class="score-left"> <view class="score-left">
<text>服务评价</text> <text>服务评价</text>
</view> </view>
<view class="score-star row"> <view class="score-star row">
<block wx:for="{{5}}" wx:key="index"> <block wx:for="{{5}}" wx:key="index">
<view class="star" bindtap="onChangeScore" data-index="{{index}}" data-type="{{1}}"> <view class="star" bindtap="onChangeScore" data-index="{{index}}" data-type="{{1}}">
<image wx:if="{{scoreServe >= index + 1}}" src="{{imageBase + 'star-yellow.png'}}"></image> <image wx:if="{{scoreServe >= index + 1}}" src="{{imageBase + 'star-yellow.png'}}"></image>
<image wx:elif="{{scoreServe < index + 1}}" src="{{imageBase + 'star-gray.png'}}"></image> <image wx:elif="{{scoreServe < index + 1}}" src="{{imageBase + 'star-gray.png'}}"></image>
</view> </view>
</block> </block>
</view> </view>
<view class="score"> <view class="score">
<text>{{scoreServeText + '星'}}</text> <text>{{scoreServeText + '星'}}</text>
</view> </view>
</view> </view>
<view class="score-wrapper row align-c"> <view class="score-wrapper row align-c">
<view class="score-left"> <view class="score-left">
<text>产品评价</text> <text>产品评价</text>
</view> </view>
<view class="score-star row"> <view class="score-star row">
<block wx:for="{{5}}" wx:key="index"> <block wx:for="{{5}}" wx:key="index">
<view class="star" bindtap="onChangeScore" data-index="{{index}}" data-type="{{2}}"> <view class="star" bindtap="onChangeScore" data-index="{{index}}" data-type="{{2}}">
<image wx:if="{{scoreProduct >= index + 1}}" src="{{imageBase + 'star-yellow.png'}}"></image> <image wx:if="{{scoreProduct >= index + 1}}" src="{{imageBase + 'star-yellow.png'}}"></image>
<image wx:elif="{{scoreProduct < index + 1}}" src="{{imageBase + 'star-gray.png'}}"></image> <image wx:elif="{{scoreProduct < index + 1}}" src="{{imageBase + 'star-gray.png'}}"></image>
</view> </view>
</block> </block>
</view> </view>
<view class="score"> <view class="score">
<text>{{scoreProductText + '星'}}</text> <text>{{scoreProductText + '星'}}</text>
</view> </view>
</view> </view>
<view class="score-wrapper row align-c"> <view class="score-wrapper row align-c">
<view class="score-left"> <view class="score-left">
<text>环境评价</text> <text>环境评价</text>
</view> </view>
<view class="score-star row"> <view class="score-star row">
<block wx:for="{{5}}" wx:key="index"> <block wx:for="{{5}}" wx:key="index">
<view class="star" bindtap="onChangeScore" data-index="{{index}}" data-type="{{3}}"> <view class="star" bindtap="onChangeScore" data-index="{{index}}" data-type="{{3}}">
<image wx:if="{{scoreEnvironment >= (index + 1)}}" src="{{imageBase + 'star-yellow.png'}}"></image> <image wx:if="{{scoreEnvironment >= (index + 1)}}" src="{{imageBase + 'star-yellow.png'}}"></image>
<image wx:elif="{{scoreEnvironment < (index + 1)}}" src="{{imageBase + 'star-gray.png'}}"></image> <image wx:elif="{{scoreEnvironment < (index + 1)}}" src="{{imageBase + 'star-gray.png'}}"></image>
</view> </view>
</block> </block>
</view> </view>
<view class="score"> <view class="score">
<text>{{scoreEnvironmentText + '星'}}</text> <text>{{scoreEnvironmentText + '星'}}</text>
</view> </view>
</view> </view>
<view class="order-comment"> <view class="order-comment">
<!-- <l-textarea cursor-spacing="100" placeholder="您的评价与建议,会让园区做的更好" placeholder-style="color: #C2C7CF" maxlength="200" <!-- <l-textarea cursor-spacing="100" placeholder="您的评价与建议,会让园区做的更好" placeholder-style="color: #C2C7CF" maxlength="200"
l-class="l-textarea" border="{{false}}" bind:linconfirm="eventInputDone" /> --> l-class="l-textarea" border="{{false}}" bind:linconfirm="eventInputDone" /> -->
<textarea style="padding:24rpx;font-size:26rpx;color:#15191F;line-height:40rpx" cols="30" rows="10" maxlength='200' placeholder="您的评价与建议,会让园区做的更好" placeholder-style="color: #C2C7CF;font-size:26rpx" <textarea style="padding:24rpx;font-size:26rpx;color:#15191F;line-height:40rpx" cols="30" rows="10" maxlength='200' placeholder="您的评价与建议,会让园区做的更好" placeholder-style="color: #C2C7CF;font-size:26rpx" bindinput="doInputContent"></textarea>
bindinput="doInputContent"></textarea> <view class="text-length-box " style="padding:16rpx 24rpx;text-align:right;font-size:24rpx;color:#C2C7CF;">{{content.length}}/200</view>
<view class="text-length-box " style="padding:16rpx 24rpx;text-align:right;font-size:24rpx;color:#C2C7CF;">
{{content.length}}/200</view>
<view class="order-picker"> <view class="order-picker">
<l-image-picker size-type="compressed" preview="{{true}}" l-item-class="l-image-item" l-class="l-picker" <l-image-picker mode="aspectFill" size-type="compressed" preview="{{true}}" l-item-class="l-image-item" l-class="l-picker" count="9" size="3" size-type="compressed" custom="{{true}}" bind:linchange="eventImageAdd" bind:linremove="eventImageRemove" bind:linpreview="eventImagePreview">
count="9" size="3" size-type="compressed" custom="{{true}}" bind:linchange="eventImageAdd" <view class="col con-c align-c">
bind:linremove="eventImageRemove" bind:linpreview="eventImagePreview"> <image class="icon-img" src="{{resourcesBase+'mine/server/camera_icon.png'}}"></image>
<view class="col con-c align-c"> <text>添加图片</text>
<image class="icon-img" src="{{resourcesBase+'mine/server/camera_icon.png'}}"></image> </view>
<text>添加图片</text> </l-image-picker>
</view> </view>
</l-image-picker> </view>
</view> </view>
</view> <view class="footer-wrapper">
</view> <view class="comment-btn" bindtap="onSubmitCommennt">
<view class="footer-wrapper"> <text>提交评价</text>
<view class="comment-btn" bindtap="onSubmitCommennt"> </view>
<text>提交评价</text> </view>
</view>
</view>
</view> </view>
<l-toast l-image-class="toast-image"></l-toast> <l-toast l-image-class="toast-image"></l-toast>
\ No newline at end of file
.container { .container {
padding-top: 232rpx; padding-top: 232rpx;
padding-bottom: 260rpx; padding-bottom: 260rpx;
background: linear-gradient(180deg, #FFFFFF 0%, #F3F4F6 100%); background: linear-gradient(180deg, #fff 0%, #f3f4f6 100%);
} }
.order-wrapper { .order-wrapper {
width: 670rpx; width: 670rpx;
height: 288rpx; height: 288rpx;
padding: 40rpx 32rpx; padding: 40rpx 32rpx;
background-color: #FFFFFF; background-color: #fff;
border-radius: 4rpx; border-radius: 4rpx;
} }
.order-title { .order-title {
height: 88rpx; height: 88rpx;
color: #15191F; color: #15191f;
font-size: 34rpx; font-size: 34rpx;
font-weight: 600; font-weight: 600;
} }
.order-cover { .order-cover {
width: 124rpx; width: 124rpx;
height: 120rpx; height: 120rpx;
margin-right: 16rpx; margin-right: 16rpx;
background-color: #ccc; background-color: #ccc;
} }
.order-name { .order-name {
width: 274rpx; width: 274rpx;
margin-left: 16rpx; margin-left: 16rpx;
color: #15191F; color: #15191f;
font-size: 30rpx; font-size: 30rpx;
font-weight: 600; font-weight: 600;
line-height: 40rpx; line-height: 40rpx;
...@@ -34,21 +38,25 @@ ...@@ -34,21 +38,25 @@
-webkit-box-orient: vertical; -webkit-box-orient: vertical;
-webkit-line-clamp: 2; -webkit-line-clamp: 2;
} }
.order-price-wrapper { .order-price-wrapper {
flex: 1; flex: 1;
height: 86rpx; height: 86rpx;
} }
.order-price { .order-price {
color: #15191F; color: #15191f;
font-size: 30rpx; font-size: 30rpx;
font-weight: 600; font-weight: 600;
line-height: 42rpx; line-height: 42rpx;
} }
.price-symbol { .price-symbol {
font-size: 22rpx; font-size: 22rpx;
} }
.order-quantity { .order-quantity {
color: #959DA9; color: #959da9;
font-size: 26rpx; font-size: 26rpx;
line-height: 36rpx; line-height: 36rpx;
letter-spacing: 2rpx; letter-spacing: 2rpx;
...@@ -61,18 +69,21 @@ ...@@ -61,18 +69,21 @@
background-color: #fff; background-color: #fff;
border-radius: 4rpx; border-radius: 4rpx;
} }
.order-comment-title { .order-comment-title {
height: 77rpx; height: 77rpx;
color: #15191F; color: #15191f;
font-size: 34rpx; font-size: 34rpx;
font-weight: 600; font-weight: 600;
} }
.score-wrapper { .score-wrapper {
height: 68rpx; height: 68rpx;
} }
.score-left { .score-left {
width: 120rpx; width: 120rpx;
color: #15191F; color: #15191f;
font-size: 30rpx; font-size: 30rpx;
font-weight: 600; font-weight: 600;
} }
...@@ -87,52 +98,63 @@ ...@@ -87,52 +98,63 @@
height: 40rpx; height: 40rpx;
margin-right: 10rpx; margin-right: 10rpx;
} }
.score { .score {
color: #959DA9; color: #959da9;
font-size: 26rpx; font-size: 26rpx;
letter-spacing: 2rpx; letter-spacing: 2rpx;
} }
.order-comment { .order-comment {
margin-top: 27rpx; margin-top: 27rpx;
background-color: #F5F6F8; background-color: #f5f6f8;
border-radius: 4rpx; border-radius: 4rpx;
} }
.l-textarea { .l-textarea {
height: 320rpx; height: 320rpx;
} }
.l-textarea > view { .l-textarea > view {
color: #C2C7CF !important; color: #c2c7cf !important;
} }
.order-picker { .order-picker {
padding: 19rpx 12rpx 8rpx; padding: 19rpx 12rpx 8rpx;
} }
.l-picker { .l-picker {
width: 504rpx !important; width: 504rpx !important;
} }
.l-image-item { .l-image-item {
width: 144rpx !important; width: 144rpx !important;
height: 144rpx !important; height: 144rpx !important;
border: 1px dashed #959DA9 !important; border: 1px dashed #959da9 !important;
margin-bottom: 24rpx !important; margin-bottom: 24rpx !important;
} }
.l-image-item > view { .l-image-item > view {
right: -20rpx; right: -20rpx;
top: -20rpx; top: -20rpx;
} }
.l-image-item > image { .l-image-item > image {
width: 144rpx !important; max-width: 144rpx !important;
height: 144rpx !important; height: 144rpx !important;
border: none !important; border: none !important;
} }
.l-image-item text{
color: #959DA9; .l-image-item text {
color: #959da9;
font-size: 22rpx; font-size: 22rpx;
} }
.icon-img { .icon-img {
width: 48rpx; width: 48rpx;
height: 48rpx; height: 48rpx;
/* background-color: #ccc; */
} }
.footer-wrapper { .footer-wrapper {
position: fixed; position: fixed;
left: 0; left: 0;
...@@ -141,9 +163,10 @@ ...@@ -141,9 +163,10 @@
height: 194rpx; height: 194rpx;
padding: 30rpx 40rpx 0; padding: 30rpx 40rpx 0;
background-color: #fff; background-color: #fff;
border-top: 1px solid #E2E7EF; border-top: 1px solid #e2e7ef;
z-index: 100; z-index: 100;
} }
.comment-btn { .comment-btn {
width: 670rpx; width: 670rpx;
height: 96rpx; height: 96rpx;
...@@ -151,11 +174,11 @@ ...@@ -151,11 +174,11 @@
font-size: 30rpx; font-size: 30rpx;
line-height: 96rpx; line-height: 96rpx;
text-align: center; text-align: center;
background-color: #86C5E1; background-color: #86c5e1;
border-radius: 4rpx; border-radius: 4rpx;
} }
image { image {
width: 100%; width: 100%;
height: 100%; height: 100%;
} }
\ No newline at end of file
...@@ -31,7 +31,6 @@ Page({ ...@@ -31,7 +31,6 @@ Page({
}, },
onLoad: function (options) { onLoad: function (options) {
let funcOrderInfo = this.data.orderInfo let funcOrderInfo = this.data.orderInfo
funcOrderInfo.id = options.id funcOrderInfo.id = options.id
this.setData({ this.setData({
...@@ -45,10 +44,58 @@ Page({ ...@@ -45,10 +44,58 @@ Page({
}, },
// 再次下单 // 再次下单
onOrderAgain: function (event) { onOrderAgain: function (event) {
let commodityType = this.data.orderInfo.commodityType console.log(this.data.orderInfo)
let shopAppId = this.data.shopAppId //wx.getStorageSync('shopInfoBuffer') ? wx.getStorageSync('shopInfoBuffer').appId : "" let funcItem = this.data.orderInfo
funcItem.shopAppId = wx.getStorageSync('shopInfoBuffer').appId
let funcUrl = ''
App.setShopInfo(funcItem.shopAppId, funcItem.commodityType)
switch (funcItem.shopAppId) {
// 海错图
case 1:
if (funcItem.commodityType === -1) funcUrl = '/pages/play/activity/activity'
if (funcItem.commodityType === 1) funcUrl = '/pages/commodity/project-detail/project-detail'
if (funcItem.commodityType === 3) funcUrl = '/pages/commodity/project-detail/project-detail'
if (funcItem.commodityType === 4) funcUrl = '/pages/commodity/menu-food/menu-food'
break
// 星空影院
case 2:
if (funcItem.commodityType === -2) funcUrl = '/pages/play/movie/movie'
break
// 儿童营地
case 3:
if (funcItem.commodityType === 1) funcUrl = '/pages/commodity/project-detail/project-detail'
if (funcItem.commodityType === 2) funcUrl = '/pages/commodity/menu-food/menu-food'
if (funcItem.commodityType === 3) funcUrl = '/pages/commodity/project-detail/project-detail'
if (funcItem.commodityType === 4) funcUrl = '/pages/commodity/menu-food/menu-food'
break
// 原野MOJITO
case 4:
if (funcItem.commodityType === 5) funcUrl = '/pages/commodity/menu-food/menu-food'
break
// 拾光花坊
case 5:
if (funcItem.commodityType === -1) funcUrl = '/pages/play/activity/activity'
if (funcItem.commodityType === 5) funcUrl = '/pages/commodity/menu-food/menu-food'
break
// 原味舒食
case 6:
if (funcItem.commodityType === 5) funcUrl = '/pages/commodity/menu-food/menu-food'
break
// 元养水韵SPA
case 7:
if (funcItem.commodityType === 2) funcUrl = '/pages/commodity/project-detail/project-detail'
break
}
wx.navigateTo({ wx.navigateTo({
url: `/pages/commodity/menu-food/menu-food?formPage=order&shopAppId=${shopAppId}&commodityType=${commodityType}`, url: funcUrl,
}) })
}, },
// 去支付 // 去支付
...@@ -65,10 +112,6 @@ Page({ ...@@ -65,10 +112,6 @@ Page({
signType: wxRequest.signType, signType: wxRequest.signType,
paySign: wxRequest.paySign, paySign: wxRequest.paySign,
success(res) { success(res) {
// let state = `orderInfo.state`
// that.setData({
// [state]: 2,
// })
that.queryOrderDetail() that.queryOrderDetail()
}, },
fail(res) {} fail(res) {}
...@@ -120,8 +163,8 @@ Page({ ...@@ -120,8 +163,8 @@ Page({
setTimeout(function () { setTimeout(function () {
if (type == 1) { if (type == 1) {
// 删除操作 // 删除操作
wx.redirectTo({ wx.navigateBack({
url: '/pages/mine/order/order', delta: 1
}) })
} else { } else {
// 取消操作 // 取消操作
...@@ -131,9 +174,7 @@ Page({ ...@@ -131,9 +174,7 @@ Page({
[state]: -1 [state]: -1
}) })
} }
}, 2000) }, 2000)
} }
}) })
......
...@@ -173,7 +173,6 @@ ...@@ -173,7 +173,6 @@
<text>{{orderInfo.expireTime}}</text> <text>{{orderInfo.expireTime}}</text>
</view> </view>
</block> </block>
</block> </block>
<!-- 观影 --> <!-- 观影 -->
......
...@@ -51,7 +51,7 @@ ...@@ -51,7 +51,7 @@
width: 670rpx; width: 670rpx;
min-height: 206rpx; min-height: 206rpx;
padding: 48rpx 32rpx; padding: 48rpx 32rpx;
background: #f3f4f6; background: #F5F6F8;
border-radius: 4rpx; border-radius: 4rpx;
overflow: hidden; overflow: hidden;
} }
...@@ -101,7 +101,7 @@ ...@@ -101,7 +101,7 @@
.info-line { .info-line {
position: relative; position: relative;
background: #f3f4f6; background: #F5F6F8;
} }
.info-line-line { .info-line-line {
...@@ -116,7 +116,7 @@ ...@@ -116,7 +116,7 @@
width: 36rpx; width: 36rpx;
height: 36rpx; height: 36rpx;
border-radius: 50%; border-radius: 50%;
background: #fff; background: #FFFFFF;
} }
.info-line-point-right { .info-line-point-right {
...@@ -125,13 +125,13 @@ ...@@ -125,13 +125,13 @@
width: 36rpx; width: 36rpx;
height: 36rpx; height: 36rpx;
border-radius: 50%; border-radius: 50%;
background: #fff; background: #FFFFFF;
} }
.info-code { .info-code {
width: 670rpx; width: 670rpx;
min-height: 330rpx; min-height: 330rpx;
background: #f3f4f6; background: #F5F6F8;
} }
.info-code text:nth-child(1) { .info-code text:nth-child(1) {
...@@ -151,7 +151,7 @@ ...@@ -151,7 +151,7 @@
font-size: 30rpx; font-size: 30rpx;
font-weight: 500; font-weight: 500;
line-height: 42rpx; line-height: 42rpx;
color: #fff; color: #FFFFFF;
} }
.info-code text:nth-child(3) { .info-code text:nth-child(3) {
...@@ -182,7 +182,7 @@ ...@@ -182,7 +182,7 @@
margin-top: 40rpx; margin-top: 40rpx;
padding: 40rpx 32rpx 0 32rpx; padding: 40rpx 32rpx 0 32rpx;
border-radius: 4rpx; border-radius: 4rpx;
background: #f3f4f6; background: #F5F6F8;
} }
.commodity-shop-info>image { .commodity-shop-info>image {
...@@ -216,12 +216,12 @@ ...@@ -216,12 +216,12 @@
font-size: 22rpx; font-size: 22rpx;
font-weight: 500; font-weight: 500;
line-height: 32rpx; line-height: 32rpx;
color: #fff; color: #FFFFFF;
} }
.commodity-item-operation>button.btn-disabled { .commodity-item-operation>button.btn-disabled {
background: #c8e1ec; background: #c8e1ec;
color: #fff; color: #FFFFFF;
} }
.commodity-list .commodity-item:last-child { .commodity-list .commodity-item:last-child {
...@@ -292,7 +292,7 @@ ...@@ -292,7 +292,7 @@
font-size: 26rpx; font-size: 26rpx;
font-weight: 500; font-weight: 500;
line-height: 36rpx; line-height: 36rpx;
color: #fff; color: #FFFFFF;
} }
.code-tip text:nth-child(2) { .code-tip text:nth-child(2) {
...@@ -301,7 +301,7 @@ ...@@ -301,7 +301,7 @@
font-size: 30rpx; font-size: 30rpx;
font-weight: 400; font-weight: 400;
line-height: 42rpx; line-height: 42rpx;
color: #fff; color: #FFFFFF;
} }
.code-info-qrcode { .code-info-qrcode {
...@@ -319,7 +319,7 @@ ...@@ -319,7 +319,7 @@
height: 666rpx; height: 666rpx;
margin-top: 56rpx; margin-top: 56rpx;
border-radius: 4rpx; border-radius: 4rpx;
background: #fff; background: #FFFFFF;
} }
.code-info-copy { .code-info-copy {
...@@ -398,7 +398,7 @@ ...@@ -398,7 +398,7 @@
margin: 64rpx auto 0; margin: 64rpx auto 0;
padding-left: 32rpx; padding-left: 32rpx;
color: #15191f; color: #15191f;
background-color: #ecf4f8; background: #ecf4f8;
} }
.status-text { .status-text {
...@@ -411,7 +411,7 @@ ...@@ -411,7 +411,7 @@
} }
.bgPink { .bgPink {
background-color: #f3e1e1; background: #f3e1e1;
} }
.ticket-wrapper { .ticket-wrapper {
...@@ -423,7 +423,7 @@ ...@@ -423,7 +423,7 @@
position: relative; position: relative;
width: 100%; width: 100%;
padding: 48rpx 32rpx 46rpx; padding: 48rpx 32rpx 46rpx;
background-color: #f3f4f6; background: #F5F6F8;
border-bottom: 1px dashed #e2e7ef; border-bottom: 1px dashed #e2e7ef;
} }
...@@ -479,12 +479,12 @@ ...@@ -479,12 +479,12 @@
width: 36rpx; width: 36rpx;
height: 36rpx; height: 36rpx;
border-radius: 50%; border-radius: 50%;
background-color: #fff; background: #FFFFFF;
} }
.ticket-footer { .ticket-footer {
padding: 50rpx 32rpx 24rpx; padding: 50rpx 32rpx 24rpx;
background-color: #f3f4f6; background: #F5F6F8;
} }
.ticket-footer-top { .ticket-footer-top {
...@@ -497,9 +497,9 @@ ...@@ -497,9 +497,9 @@
height: 96rpx; height: 96rpx;
line-height: 96rpx; line-height: 96rpx;
margin: 40rpx 0; margin: 40rpx 0;
color: #fff; color: #FFFFFF;
text-align: center; text-align: center;
background-color: #86c5e1; background: #86c5e1;
border-radius: 4rpx; border-radius: 4rpx;
} }
...@@ -510,14 +510,14 @@ ...@@ -510,14 +510,14 @@
.code-header { .code-header {
height: 70rpx; height: 70rpx;
color: #fff; color: #FFFFFF;
font-size: 30rpx; font-size: 30rpx;
text-align: center; text-align: center;
} }
.code-tips { .code-tips {
height: 92rpx; height: 92rpx;
color: #fff; color: #FFFFFF;
font-size: 26rpx; font-size: 26rpx;
text-align: center; text-align: center;
} }
...@@ -531,7 +531,7 @@ ...@@ -531,7 +531,7 @@
position: relative; position: relative;
width: 526rpx; width: 526rpx;
height: 666rpx; height: 666rpx;
background-color: #fff; background: #FFFFFF;
border-radius: 4rpx; border-radius: 4rpx;
} }
...@@ -563,7 +563,7 @@ ...@@ -563,7 +563,7 @@
width: 446rpx; width: 446rpx;
height: 96rpx; height: 96rpx;
padding: 0 24rpx; padding: 0 24rpx;
background-color: #f2f3f5; background: #f2f3f5;
border-radius: 4rpx; border-radius: 4rpx;
line-height: 96rpx; line-height: 96rpx;
} }
...@@ -602,7 +602,7 @@ ...@@ -602,7 +602,7 @@
} }
.current-img-num { .current-img-num {
color: #fff; color: #FFFFFF;
font-size: 34rpx; font-size: 34rpx;
} }
...@@ -646,7 +646,7 @@ ...@@ -646,7 +646,7 @@
.notice-popup-wrapper { .notice-popup-wrapper {
padding: 56rpx 40rpx 68rpx; padding: 56rpx 40rpx 68rpx;
background-color: #fff; background: #FFFFFF;
border-radius: 24rpx 24rpx 0 0; border-radius: 24rpx 24rpx 0 0;
} }
...@@ -672,7 +672,7 @@ ...@@ -672,7 +672,7 @@
.goods-list { .goods-list {
margin-top: 40rpx; margin-top: 40rpx;
padding: 0 32rpx 14rpx; padding: 0 32rpx 14rpx;
background-color: #f5f6f8; background: #f5f6f8;
} }
.goods-list-title-wrapper { .goods-list-title-wrapper {
...@@ -743,16 +743,16 @@ ...@@ -743,16 +743,16 @@
height: 56rpx; height: 56rpx;
margin-top: 40rpx; margin-top: 40rpx;
margin-left: 32rpx; margin-left: 32rpx;
color: #fff; color: #FFFFFF;
font-size: 22rpx; font-size: 22rpx;
text-align: center; text-align: center;
line-height: 56rpx; line-height: 56rpx;
background-color: #86c5e1; background: #86c5e1;
border-radius: 4rpx; border-radius: 4rpx;
} }
.disabled { .disabled {
background-color: #c8e1ec; background: #c8e1ec;
} }
.order-info-wrapper { .order-info-wrapper {
...@@ -802,7 +802,7 @@ ...@@ -802,7 +802,7 @@
position: fixed; position: fixed;
bottom: 0; bottom: 0;
width: 100%; width: 100%;
background: #fff; background: #FFFFFF;
padding: 32rpx 20rpx; padding: 32rpx 20rpx;
border-top: 1px solid #e2e7ef; border-top: 1px solid #e2e7ef;
} }
...@@ -819,13 +819,13 @@ ...@@ -819,13 +819,13 @@
.delete-btn { .delete-btn {
color: #656e7b; color: #656e7b;
background-color: #fff; background: #FFFFFF;
border: 1px solid #c2c7cf; border: 1px solid #c2c7cf;
} }
.order-btn { .order-btn {
color: #fff; color: #FFFFFF;
background-color: #86c5e1; background: #86c5e1;
} }
image { image {
......
...@@ -93,8 +93,6 @@ Page({ ...@@ -93,8 +93,6 @@ Page({
onLoad: function (options) { onLoad: function (options) {
if (options.type) options.type = Number(options.type) if (options.type) options.type = Number(options.type)
console.log(options.type)
logicData.option = options logicData.option = options
this.setShopInfo() this.setShopInfo()
...@@ -470,12 +468,6 @@ Page({ ...@@ -470,12 +468,6 @@ Page({
break break
} }
} }
console.log(funcTimetable)
console.log(funcDate)
console.log(funcTimeBegin)
console.log(funcTimeEnd)
this.setData({ this.setData({
buyContentTime: funcDate + ' ' + funcTimeBegin + ' - ' + funcTimeEnd buyContentTime: funcDate + ' ' + funcTimeBegin + ' - ' + funcTimeEnd
}) })
...@@ -813,6 +805,10 @@ Page({ ...@@ -813,6 +805,10 @@ Page({
// 校验数组用户信息 // 校验数组用户信息
let funcRegisterInfo = this.data.registerInfo let funcRegisterInfo = this.data.registerInfo
console.log(funcRegisterInfo)
for (let i = 0, l = funcRegisterInfo.length; i < l; i++) { for (let i = 0, l = funcRegisterInfo.length; i < l; i++) {
if (funcRegisterInfo[i].name === '' || funcRegisterInfo[i].errorName !== '') { if (funcRegisterInfo[i].name === '' || funcRegisterInfo[i].errorName !== '') {
this.setUserInfo('name', funcRegisterInfo[i].name, i, App.modular.rule.item('name', funcRegisterInfo[i].name)) this.setUserInfo('name', funcRegisterInfo[i].name, i, App.modular.rule.item('name', funcRegisterInfo[i].name))
...@@ -1211,10 +1207,16 @@ Page({ ...@@ -1211,10 +1207,16 @@ Page({
break break
} }
} else { } else {
// 取消支付直接进入订单 if ([1, 2, 3, 4, 5, 7].indexOf(logicData.option.type) >= 0) {
wx.reLaunch({ // 取消支付直接进入订单
url: '/pages/mine/order/order?fromPage=pay' wx.reLaunch({
}) url: '/pages/mine/order/order?fromPage=pay'
})
} else {
wx.reLaunch({
url: '/pages/mine/appointment/appointment?fromPage=pay'
})
}
} }
}, },
......
...@@ -298,7 +298,7 @@ ...@@ -298,7 +298,7 @@
<!-- winButtonAppointment --> <!-- winButtonAppointment -->
<cover-view class="appointment row con-c align-c" wx:if="{{winButtonAppointment && !winNoticeDetail && !winActivityResult}}"> <cover-view class="appointment row con-c align-c" wx:if="{{winButtonAppointment && !winNoticeDetail && !winActivityResult}}">
<cover-view class="appointment-confirm row con-c align-c" bindtap="paySubmitActivity">确认预约</cover-view> <cover-view class="appointment-confirm row con-c align-c" bindtap="onPaySubmit">确认预约</cover-view>
</cover-view> </cover-view>
<!-- 购买须知详情 --> <!-- 购买须知详情 -->
......
...@@ -183,11 +183,25 @@ Page({ ...@@ -183,11 +183,25 @@ Page({
}, },
// 活动报名 // 活动报名
onReport: function (event) { onReport: function (event) {
let index = event.currentTarget.dataset.index console.log(event)
let selectedActivity = this.data.selectedActivity
selectedActivity[index].quantity = 1 let funcItem = event.currentTarget.dataset.item
this.setShopInfo(selectedActivity[index].officeId, 2) let funcShopId = funcItem.officeId
wx.setStorageSync('shoppingCartBuffer', [selectedActivity[index]])
let funcShopInfo = App.globalData.shopId
for (let i = 0, l = funcShopInfo.length; i < l; i++) {
if (funcShopId === funcShopInfo[i].id) {
App.setShopInfo(funcShopInfo[i].appId, 2)
break
}
}
funcItem.quantity = 1
funcItem.quantityMin = 1
funcItem.quantityMax = 1
funcItem.isActive = true
wx.setStorageSync('shoppingCartBuffer', [funcItem])
wx.navigateTo({ wx.navigateTo({
url: '/pages/pay/order-input/order-input?type=6' url: '/pages/pay/order-input/order-input?type=6'
}) })
......
...@@ -50,7 +50,7 @@ ...@@ -50,7 +50,7 @@
<text>{{item.price == '0' ? '免费' : item.priceText}}</text> <text>{{item.price == '0' ? '免费' : item.priceText}}</text>
</view> </view>
<view> <view>
<button class="row con-c align-c" catchtap="onReport" data-index="{{index}}">报名</button> <button class="row con-c align-c" catchtap="onReport" data-item="{{item}}">报名</button>
</view> </view>
</view> </view>
</view> </view>
......
...@@ -8,42 +8,48 @@ ...@@ -8,42 +8,48 @@
min-height: 100vh; min-height: 100vh;
margin-top: 120rpx; margin-top: 120rpx;
padding-bottom: 100rpx; padding-bottom: 100rpx;
background: linear-gradient(#ffffff, #F2F2F2); background: linear-gradient(180deg, #FFFFFF 0%, #F3F4F6 6%, #F3F4F6 100%);
} }
/* 状态筛选菜单 */ /* 状态筛选菜单 */
.status { .status {
width: 750rpx; width: 750rpx;
padding: 0 40rpx; padding: 0 40rpx;
border-bottom: 1px #E2E7EF solid; border-bottom: 1px #e2e7ef solid;
overflow-x: scroll; overflow-x: scroll;
flex-wrap: nowrap; flex-wrap: nowrap;
background-color: #fff; background-color: #fff;
} }
.status-fixed { .status-fixed {
z-index: 999; z-index: 999;
position: fixed; position: fixed;
left: 0; left: 0;
} }
.status-item { .status-item {
height: 94rpx; height: 94rpx;
margin-right: 80rpx; margin-right: 80rpx;
font-size: 26rpx; font-size: 26rpx;
font-weight: 400; font-weight: 400;
color: #959DA9; color: #959da9;
} }
.status-item text { .status-item text {
display: inline-block; display: inline-block;
white-space: nowrap; white-space: nowrap;
} }
.status-item:last-child { .status-item:last-child {
padding-right: 40rpx; padding-right: 40rpx;
} }
.status-item-active { .status-item-active {
height: 94rpx; height: 94rpx;
color: #15191F; color: #15191f;
font-weight: 600; font-weight: 600;
border-bottom: 4rpx #15191F solid; border-bottom: 4rpx #15191f solid;
} }
::-webkit-scrollbar { ::-webkit-scrollbar {
...@@ -65,6 +71,7 @@ ...@@ -65,6 +71,7 @@
} }
/* 活动列表 */ /* 活动列表 */
.list { .list {
padding: 0rpx 40rpx 50rpx 40rpx; padding: 0rpx 40rpx 50rpx 40rpx;
} }
...@@ -75,7 +82,7 @@ ...@@ -75,7 +82,7 @@
margin-top: 64rpx; margin-top: 64rpx;
border-radius: 2px; border-radius: 2px;
overflow: hidden; overflow: hidden;
background: #ffffff; background: #fff;
} }
.item-info { .item-info {
...@@ -90,28 +97,28 @@ ...@@ -90,28 +97,28 @@
.item-title text:nth-child(1) { .item-title text:nth-child(1) {
font-size: 34rpx; font-size: 34rpx;
font-weight: bold; font-weight: bold;
color: #15191F; color: #15191f;
line-height: 44rpx; line-height: 44rpx;
display: -webkit-box; display: -webkit-box;
overflow: hidden; overflow: hidden;
white-space: normal; white-space: normal;
text-overflow: ellipsis; text-overflow: ellipsis;
word-wrap: break-word; word-wrap: break-word;
-webkit-line-clamp:1; -webkit-line-clamp: 1;
-webkit-box-orient: vertical; -webkit-box-orient: vertical;
} }
.item-title text:nth-child(2) { .item-title text:nth-child(2) {
width: 96rpx; width: 96rpx;
height: 32rpx; height: 32rpx;
border-radius: 4rpx; border-radius: 4rpx;
border: 1px solid #86C5E1; border: 1px solid #86c5e1;
background: rgba(134, 197, 225, 0.1); background: rgba(134, 197, 225, 0.1);
text-align: center; text-align: center;
font-size: 18rpx; font-size: 18rpx;
font-weight: 500; font-weight: 500;
line-height: 32rpx; line-height: 32rpx;
color: #86C5E1; color: #86c5e1;
} }
.item-date { .item-date {
...@@ -119,7 +126,7 @@ ...@@ -119,7 +126,7 @@
height: 40rpx; height: 40rpx;
margin-top: 8rpx; margin-top: 8rpx;
font-size: 26rpx; font-size: 26rpx;
color: #656E7B; color: #656e7b;
line-height: 40rpx; line-height: 40rpx;
} }
...@@ -134,20 +141,20 @@ ...@@ -134,20 +141,20 @@
height: 80rpx; height: 80rpx;
margin-top: 16rpx; margin-top: 16rpx;
font-size: 26rpx; font-size: 26rpx;
color: #959DA9; color: #959da9;
line-height: 40rpx; line-height: 40rpx;
display: -webkit-box; display: -webkit-box;
overflow: hidden; overflow: hidden;
white-space: normal; white-space: normal;
text-overflow: ellipsis; text-overflow: ellipsis;
word-wrap: break-word; word-wrap: break-word;
-webkit-line-clamp:2; -webkit-line-clamp: 2;
-webkit-box-orient: vertical; -webkit-box-orient: vertical;
} }
.price-symbol { .price-symbol {
margin-top: 8rpx; margin-top: 8rpx;
color: #15191F; color: #15191f;
font-size: 18rpx; font-size: 18rpx;
font-weight: 600; font-weight: 600;
} }
...@@ -160,14 +167,13 @@ ...@@ -160,14 +167,13 @@
width: 78rpx; width: 78rpx;
height: 32rpx; height: 32rpx;
margin-right: 12rpx; margin-right: 12rpx;
background: linear-gradient(180deg, #3F4357 0%, #252532 100%); background: linear-gradient(180deg, #3f4357 0%, #252532 100%);
border-radius: 4rpx; border-radius: 4rpx;
text-align: center; text-align: center;
font-size: 18rpx; font-size: 18rpx;
font-weight: 500; font-weight: 500;
line-height: 28rpx; line-height: 28rpx;
color: #E8D0AF; color: #e8d0af;
} }
.item-operation text:nth-child(3) { .item-operation text:nth-child(3) {
...@@ -176,7 +182,7 @@ ...@@ -176,7 +182,7 @@
font-size: 30rpx; font-size: 30rpx;
font-weight: 600; font-weight: 600;
line-height: 36rpx; line-height: 36rpx;
color: #15191F; color: #15191f;
} }
.item-operation text:nth-child(4) { .item-operation text:nth-child(4) {
...@@ -184,7 +190,7 @@ ...@@ -184,7 +190,7 @@
font-size: 22rpx; font-size: 22rpx;
font-weight: 400; font-weight: 400;
line-height: 32rpx; line-height: 32rpx;
color: #C2C7CF; color: #c2c7cf;
text-decoration: line-through; text-decoration: line-through;
} }
...@@ -193,8 +199,8 @@ ...@@ -193,8 +199,8 @@
width: 132rpx; width: 132rpx;
height: 56rpx; height: 56rpx;
border-radius: 4rpx; border-radius: 4rpx;
background: #86C5E1; background: #86c5e1;
color: #FFFFFF; color: #fff;
font-size: 26rpx; font-size: 26rpx;
font-weight: 500; font-weight: 500;
line-height: 36rpx; line-height: 36rpx;
...@@ -206,14 +212,14 @@ ...@@ -206,14 +212,14 @@
} }
/* 往期活动 */ /* 往期活动 */
.route-list { .route-list {
width: 750rpx; width: 750rpx;
margin-top: 48rpx; margin-top: 48rpx;
padding: 0 40rpx; padding: 0 40rpx;
} }
.route-list-left, .route-list-left, .route-list-right {
.route-list-right {
width: 320rpx; width: 320rpx;
} }
...@@ -224,7 +230,7 @@ ...@@ -224,7 +230,7 @@
margin-top: 16rpx; margin-top: 16rpx;
border-radius: 4rpx; border-radius: 4rpx;
overflow: hidden; overflow: hidden;
background: #ffffff; background: #fff;
} }
.route-item image { .route-item image {
...@@ -240,8 +246,7 @@ ...@@ -240,8 +246,7 @@
margin: 32rpx 32rpx 8rpx; margin: 32rpx 32rpx 8rpx;
font-size: 26rpx; font-size: 26rpx;
font-weight: bolder; font-weight: bolder;
color: #000000; color: #000;
overflow: hidden; overflow: hidden;
text-overflow: ellipsis; text-overflow: ellipsis;
line-clamp: 2; line-clamp: 2;
...@@ -252,5 +257,5 @@ ...@@ -252,5 +257,5 @@
.route-item-content { .route-item-content {
margin: 0 32rpx 32rpx 32rpx; margin: 0 32rpx 32rpx 32rpx;
font-size: 22rpx; font-size: 22rpx;
color: #959DA9; color: #959da9;
} }
...@@ -8,7 +8,7 @@ ...@@ -8,7 +8,7 @@
<!-- 畅玩分类 --> <!-- 畅玩分类 -->
<block wx:if="{{appStatus}}"> <block wx:if="{{appStatus}}">
<view class="banner"> <view class="banner" style="{{'margin-top: ' + (navigationLogoTop + navigationLogoMarginTop + 40) + 'rpx;'}}">
<image src="{{resourcesBase + 'play/home/type.png'}}"></image> <image src="{{resourcesBase + 'play/home/type.png'}}"></image>
<button class="art-button" bindtap="onToArt"></button> <button class="art-button" bindtap="onToArt"></button>
<button class="health-button" bindtap="onToHealth"></button> <button class="health-button" bindtap="onToHealth"></button>
...@@ -19,7 +19,7 @@ ...@@ -19,7 +19,7 @@
</block> </block>
<block wx:if="{{!appStatus}}"> <block wx:if="{{!appStatus}}">
<view class="banner-occupy"></view> <view class="banner-occupy" style="{{'margin-top: ' + (navigationLogoTop + navigationLogoMarginTop + 40) + 'rpx;'}}"></view>
</block> </block>
<!-- 近期活动 --> <!-- 近期活动 -->
......
...@@ -36,12 +36,10 @@ ...@@ -36,12 +36,10 @@
/* 畅玩分类 */ /* 畅玩分类 */
.banner-occupy { .banner-occupy {
position: relative; position: relative;
margin-top: 200rpx;
} }
.banner { .banner {
position: relative; position: relative;
margin-top: 200rpx;
width: 750rpx; width: 750rpx;
height: 1200rpx; height: 1200rpx;
} }
......
...@@ -60,9 +60,9 @@ Page({ ...@@ -60,9 +60,9 @@ Page({
shopInfo: {}, shopInfo: {},
detailActivity: [], // 活动 detailActivity: [], // 活动
detailCommodity: [], // 商品 detailCommodity: [], // 商品
detailEvaluate: [], // 评论 detailEvaluate: [], // 评论
evaluateAlbum: [], evaluateAlbum: [],
emptyImg: App.globalData.appResourcesBase + 'play/service/nothing.jpg', emptyImg: App.globalData.appResourcesBase + 'play/service/nothing.jpg',
...@@ -75,31 +75,29 @@ Page({ ...@@ -75,31 +75,29 @@ Page({
commodityTitle: '', commodityTitle: '',
officeService: 0, officeService: 0,
officeServiceText: '5.0', // 门店服务评分 officeServiceText: '5.0', // 门店服务评分
officeProduct: 0, officeProduct: 0,
officeProductText: '5.0', // 门店产品评分 officeProductText: '5.0', // 门店产品评分
officeEnvironmental: 0, officeEnvironmental: 0,
officeEnvironmentalText: '5.0', // 门店环境评分 officeEnvironmentalText: '5.0', // 门店环境评分
cssDetail: '', // 详情底部边距 cssDetail: '', // 详情底部边距
winActivity: false, // 近期活动 winActivity: false, // 近期活动
winCommodity: false, // 商品列表 winCommodity: false, // 商品列表
winCommodityMenu: false, winCommodityMenu: false,
winEvaluateAlbum: false, winEvaluateAlbum: false,
winHidden: false, // 海错图临时隐藏内容控制 winHidden: false, // 海错图临时隐藏内容控制
}, },
onLoad: function (options) { onLoad: function(options) {
this.setData({ this.setData({
option: options, option: options,
}) })
this.queryDetail(Number(options.id)) this.queryDetail(Number(options.id))
console.log(Number(options.id))
// 根据商店查询相关订制内容 // 根据商店查询相关订制内容
switch (Number(options.id)) { switch (Number(options.id)) {
case 1: case 1:
...@@ -163,14 +161,12 @@ Page({ ...@@ -163,14 +161,12 @@ Page({
default: default:
this.queryCommodity() this.queryCommodity()
} }
console.log(this.data.cssDetail)
this.getOfficeAppraise()
this.getAppraise()
}, },
onShow: function () { onShow: function() {
this.setData({ appStatus: App.globalData.appStatus }) this.setData({
appStatus: App.globalData.appStatus
})
}, },
/** /**
...@@ -179,166 +175,159 @@ Page({ ...@@ -179,166 +175,159 @@ Page({
* @param {string} - funcToken * @param {string} - funcToken
* @returns * @returns
*/ */
queryDetail: function (funcAppId) { queryDetail: function(funcAppId) {
let funcIndex = 0 let funcIndex = 0
// 预设数据 // 预设数据
let funcDetail = [ let funcDetail = [{
{ appId: 1,
appId: 1, id: App.globalData.pointInfo[0].id,
id: App.globalData.pointInfo[0].id, banner: [
banner: [ App.globalData.appResourcesBase + 'shop/banner/banner-1-1-1.png',
App.globalData.appResourcesBase + 'shop/banner/banner-1-1-1.png', App.globalData.appResourcesBase + 'shop/banner/banner-1-1-2.png',
App.globalData.appResourcesBase + 'shop/banner/banner-1-1-2.png', App.globalData.appResourcesBase + 'shop/banner/banner-1-1-3.png',
App.globalData.appResourcesBase + 'shop/banner/banner-1-1-3.png', ],
], shareImage: App.globalData.appResourcesBase + 'share/share-2.png',
shareImage: App.globalData.appResourcesBase + 'share/share-2.png', name: '海错图展馆',
name: '海错图展馆', title: '海错图',
title: '海错图', date: '周一至周日 10:00 - 20:00',
date: '周一至周日 10:00 - 20:00', activity: [{
activity: [ cover: '',
{ title: '亲子自然教育工作坊',
cover: '', tab: '亲子教育',
title: '亲子自然教育工作坊', time: '7.20-7.25 10:00-11:30',
tab: '亲子教育', price: '150',
time: '7.20-7.25 10:00-11:30', specialPrice: '100',
price: '150', },
specialPrice: '100', {
}, cover: '',
{ title: '装饰干花工作坊',
cover: '', tab: '亲子教育',
title: '装饰干花工作坊', time: '7.20-7.25 10:00-11:30',
tab: '亲子教育', price: '150',
time: '7.20-7.25 10:00-11:30', specialPrice: '100',
price: '150', }
specialPrice: '100', ],
} commodity: [{
], cover: '',
commodity: [ title: '海错图画册',
{ price: '150',
cover: '', specialPrice: '100',
title: '海错图画册',
price: '150',
specialPrice: '100',
}, {
cover: '',
title: '海错图画册',
price: '150',
specialPrice: '100',
}
],
describe: [
App.globalData.appResourcesBase + 'shop/detail/detail-1-1-1.png',
App.globalData.appResourcesBase + 'shop/detail/detail-1-1-2.png',
App.globalData.appResourcesBase + 'shop/detail/detail-1-1-3.png',
App.globalData.appResourcesBase + 'shop/detail/detail-1-1-4.png',
App.globalData.appResourcesBase + 'shop/detail/detail-1-1-5.png',
],
evaluate: [
{
avatar: '',
name: '张笑寒',
status: 1,
date: '2020.02.29',
star: 4,
content: '通过数字化形式,运用视频、动画 游戏、交感互动等多种手段,分层呈现画谱中原本二维的文字与图片信息。乾隆挚爱的故宫典藏图谱、清代画师聂璜所著12312313123',
image: [],
}
],
contact: '13316748039'
}, {
appId: 5,
id: App.globalData.pointInfo[4].id,
banner: [
App.globalData.appResourcesBase + 'shop/banner/banner-1-2-1.png',
App.globalData.appResourcesBase + 'shop/banner/banner-1-2-2.png',
App.globalData.appResourcesBase + 'shop/banner/banner-1-2-3.png',
],
shareImage: App.globalData.appResourcesBase + 'share/share-5.png',
name: '拾光花坊',
title: '拾光花坊',
date: '周一至周日 10:00 - 20:00',
describe: [
App.globalData.appResourcesBase + 'shop/detail/detail-1-2-1.png',
],
contact: '13316748039'
}, {
appId: 7,
id: App.globalData.pointInfo[6].id,
banner: [
App.globalData.appResourcesBase + 'shop/banner/banner-2-1-1.png',
App.globalData.appResourcesBase + 'shop/banner/banner-2-1-2.png',
App.globalData.appResourcesBase + 'shop/banner/banner-2-1-3.png',
],
shareImage: App.globalData.appResourcesBase + 'share/share-11.png',
name: '元养水韵SPA',
title: '元养水韵SPA',
date: '周一至周日 10:00 - 22:00',
describe: [
App.globalData.appResourcesBase + 'shop/detail/detail-2-1-1.png',
App.globalData.appResourcesBase + 'shop/detail/detail-2-1-2.png',
App.globalData.appResourcesBase + 'shop/detail/detail-2-1-3.png',
App.globalData.appResourcesBase + 'shop/detail/detail-2-1-4.png',
],
contact: '13316748039'
}, {
appId: 6,
id: App.globalData.pointInfo[5].id,
banner: [
App.globalData.appResourcesBase + 'shop/banner/banner-3-1-1.png',
App.globalData.appResourcesBase + 'shop/banner/banner-3-1-2.png',
App.globalData.appResourcesBase + 'shop/banner/banner-3-1-3.png',
],
shareImage: App.globalData.appResourcesBase + 'share/share-12.png',
name: '原味舒食',
title: '原味舒食',
date: '周一至周日 10:00 - 21:30',
describe: [
App.globalData.appResourcesBase + 'shop/detail/detail-3-1-1.png',
App.globalData.appResourcesBase + 'shop/detail/detail-3-1-2.png',
App.globalData.appResourcesBase + 'shop/detail/detail-3-1-3.png',
App.globalData.appResourcesBase + 'shop/detail/detail-3-1-4.png',
App.globalData.appResourcesBase + 'shop/detail/detail-3-1-5.png',
App.globalData.appResourcesBase + 'shop/detail/detail-3-1-6.png',
App.globalData.appResourcesBase + 'shop/detail/detail-3-1-7.png',
],
contact: '13316748039'
}, {
appId: 4,
id: App.globalData.pointInfo[3].id,
banner: [
App.globalData.appResourcesBase + 'shop/banner/banner-3-2-1.png',
App.globalData.appResourcesBase + 'shop/banner/banner-3-2-2.png',
App.globalData.appResourcesBase + 'shop/banner/banner-3-2-3.png',
],
shareImage: App.globalData.appResourcesBase + 'share/share-13.png',
name: '原野MOJITO',
title: '原野MOJITO',
date: '周一至周日 10:00 - 凌晨02:00',
describe: [
App.globalData.appResourcesBase + 'shop/detail/detail-3-2-1.png',
],
contact: '13316748039'
}, { }, {
appId: 2, cover: '',
id: App.globalData.pointInfo[1].id, title: '海错图画册',
banner: [ price: '150',
App.globalData.appResourcesBase + 'shop/banner/banner-4-1-1.png', specialPrice: '100',
App.globalData.appResourcesBase + 'shop/banner/banner-4-1-2.png', }],
App.globalData.appResourcesBase + 'shop/banner/banner-4-1-3.png', describe: [
], App.globalData.appResourcesBase + 'shop/detail/detail-1-1-1.png',
shareImage: App.globalData.appResourcesBase + 'share/share-9.png', App.globalData.appResourcesBase + 'shop/detail/detail-1-1-2.png',
name: '星空影院', App.globalData.appResourcesBase + 'shop/detail/detail-1-1-3.png',
title: '星空影院', App.globalData.appResourcesBase + 'shop/detail/detail-1-1-4.png',
date: '周一至周日 10:00 - 20:30', App.globalData.appResourcesBase + 'shop/detail/detail-1-1-5.png',
describe: [ ],
App.globalData.appResourcesBase + 'shop/detail/detail-4-1-1.png', evaluate: [{
App.globalData.appResourcesBase + 'shop/detail/detail-4-1-2.png', avatar: '',
App.globalData.appResourcesBase + 'shop/detail/detail-4-1-3.png', name: '张笑寒',
App.globalData.appResourcesBase + 'shop/detail/detail-4-1-4.png', status: 1,
], date: '2020.02.29',
contact: '13316748039' star: 4,
} content: '通过数字化形式,运用视频、动画 游戏、交感互动等多种手段,分层呈现画谱中原本二维的文字与图片信息。乾隆挚爱的故宫典藏图谱、清代画师聂璜所著12312313123',
] image: [],
}],
contact: '13316748039'
}, {
appId: 5,
id: App.globalData.pointInfo[4].id,
banner: [
App.globalData.appResourcesBase + 'shop/banner/banner-1-2-1.png',
App.globalData.appResourcesBase + 'shop/banner/banner-1-2-2.png',
App.globalData.appResourcesBase + 'shop/banner/banner-1-2-3.png',
],
shareImage: App.globalData.appResourcesBase + 'share/share-5.png',
name: '拾光花坊',
title: '拾光花坊',
date: '周一至周日 10:00 - 20:00',
describe: [
App.globalData.appResourcesBase + 'shop/detail/detail-1-2-1.png',
],
contact: '13316748039'
}, {
appId: 7,
id: App.globalData.pointInfo[6].id,
banner: [
App.globalData.appResourcesBase + 'shop/banner/banner-2-1-1.png',
App.globalData.appResourcesBase + 'shop/banner/banner-2-1-2.png',
App.globalData.appResourcesBase + 'shop/banner/banner-2-1-3.png',
],
shareImage: App.globalData.appResourcesBase + 'share/share-11.png',
name: '元养水韵SPA',
title: '元养水韵SPA',
date: '周一至周日 10:00 - 22:00',
describe: [
App.globalData.appResourcesBase + 'shop/detail/detail-2-1-1.png',
App.globalData.appResourcesBase + 'shop/detail/detail-2-1-2.png',
App.globalData.appResourcesBase + 'shop/detail/detail-2-1-3.png',
App.globalData.appResourcesBase + 'shop/detail/detail-2-1-4.png',
],
contact: '13316748039'
}, {
appId: 6,
id: App.globalData.pointInfo[5].id,
banner: [
App.globalData.appResourcesBase + 'shop/banner/banner-3-1-1.png',
App.globalData.appResourcesBase + 'shop/banner/banner-3-1-2.png',
App.globalData.appResourcesBase + 'shop/banner/banner-3-1-3.png',
],
shareImage: App.globalData.appResourcesBase + 'share/share-12.png',
name: '原味舒食',
title: '原味舒食',
date: '周一至周日 10:00 - 21:30',
describe: [
App.globalData.appResourcesBase + 'shop/detail/detail-3-1-1.png',
App.globalData.appResourcesBase + 'shop/detail/detail-3-1-2.png',
App.globalData.appResourcesBase + 'shop/detail/detail-3-1-3.png',
App.globalData.appResourcesBase + 'shop/detail/detail-3-1-4.png',
App.globalData.appResourcesBase + 'shop/detail/detail-3-1-5.png',
App.globalData.appResourcesBase + 'shop/detail/detail-3-1-6.png',
App.globalData.appResourcesBase + 'shop/detail/detail-3-1-7.png',
],
contact: '13316748039'
}, {
appId: 4,
id: App.globalData.pointInfo[3].id,
banner: [
App.globalData.appResourcesBase + 'shop/banner/banner-3-2-1.png',
App.globalData.appResourcesBase + 'shop/banner/banner-3-2-2.png',
App.globalData.appResourcesBase + 'shop/banner/banner-3-2-3.png',
],
shareImage: App.globalData.appResourcesBase + 'share/share-13.png',
name: '原野MOJITO',
title: '原野MOJITO',
date: '周一至周日 10:00 - 凌晨02:00',
describe: [
App.globalData.appResourcesBase + 'shop/detail/detail-3-2-1.png',
],
contact: '13316748039'
}, {
appId: 2,
id: App.globalData.pointInfo[1].id,
banner: [
App.globalData.appResourcesBase + 'shop/banner/banner-4-1-1.png',
App.globalData.appResourcesBase + 'shop/banner/banner-4-1-2.png',
App.globalData.appResourcesBase + 'shop/banner/banner-4-1-3.png',
],
shareImage: App.globalData.appResourcesBase + 'share/share-9.png',
name: '星空影院',
title: '星空影院',
date: '周一至周日 10:00 - 20:30',
describe: [
App.globalData.appResourcesBase + 'shop/detail/detail-4-1-1.png',
App.globalData.appResourcesBase + 'shop/detail/detail-4-1-2.png',
App.globalData.appResourcesBase + 'shop/detail/detail-4-1-3.png',
App.globalData.appResourcesBase + 'shop/detail/detail-4-1-4.png',
],
contact: '13316748039'
}]
// 查询景点信息 // 查询景点信息
App.wxRequest({ App.wxRequest({
...@@ -405,7 +394,7 @@ Page({ ...@@ -405,7 +394,7 @@ Page({
* @param {string} - funcToken * @param {string} - funcToken
* @returns * @returns
*/ */
queryActivity: function () { queryActivity: function() {
App.wxRequest({ App.wxRequest({
url: '/api/v1/activity/getList', url: '/api/v1/activity/getList',
data: { data: {
...@@ -413,7 +402,7 @@ Page({ ...@@ -413,7 +402,7 @@ Page({
'pageSize': 10, 'pageSize': 10,
'pageNo': '1', 'pageNo': '1',
'tagId': '', 'tagId': '',
'officeId': this.data.shopInfo.id, 'officeId': this.data.shopInfo.id,
}, },
success: (response) => { success: (response) => {
let funcResponse = response.data.list let funcResponse = response.data.list
...@@ -424,13 +413,13 @@ Page({ ...@@ -424,13 +413,13 @@ Page({
'id': funcResponse[i].id, 'id': funcResponse[i].id,
'title': funcResponse[i].name, 'title': funcResponse[i].name,
'officeId': funcResponse[i].officeId, 'officeId': funcResponse[i].officeId,
'price': funcResponse[i].visitorPrice, // 普通价 'price': funcResponse[i].visitorPrice, // 普通价
'priceText': App.modular.utils.formatAmount(funcResponse[i].visitorPrice), // 普通价文本格式 'priceText': App.modular.utils.formatAmount(funcResponse[i].visitorPrice), // 普通价文本格式
'priceSpecial': funcResponse[i].ownerPrice, // 业主价 'priceSpecial': funcResponse[i].ownerPrice, // 业主价
'priceSpecialText': App.modular.utils.formatAmount(funcResponse[i].ownerPrice), // 业主价文本格式 'priceSpecialText': App.modular.utils.formatAmount(funcResponse[i].ownerPrice), // 业主价文本格式
'tagIds': funcResponse[i].tagIds, 'tagIds': funcResponse[i].tagIds,
'tagNames': funcResponse[i].tagNames, 'tagNames': funcResponse[i].tagNames,
'date': funcResponse[i].activeDate + ' ' + funcResponse[i].activeTime, // 活动时间 'date': funcResponse[i].activeDate + ' ' + funcResponse[i].activeTime, // 活动时间
'priceType': 1, 'priceType': 1,
} }
let funcUserType = wx.getStorageSync('userInfo').userType let funcUserType = wx.getStorageSync('userInfo').userType
...@@ -463,7 +452,7 @@ Page({ ...@@ -463,7 +452,7 @@ Page({
* @param * @param
* @returns * @returns
*/ */
queryCommodity: function () { queryCommodity: function() {
App.wxRequest({ App.wxRequest({
url: '/api/v1/commodity/recommend', url: '/api/v1/commodity/recommend',
data: { data: {
...@@ -478,20 +467,20 @@ Page({ ...@@ -478,20 +467,20 @@ Page({
let funcResponse = response.data let funcResponse = response.data
for (let i = 0, l = funcResponse.length; i < l; i++) { for (let i = 0, l = funcResponse.length; i < l; i++) {
let funcItem = { let funcItem = {
'id': funcResponse[i].id, // 商品标识 'id': funcResponse[i].id, // 商品标识
'typeId': funcResponse[i].genre, // 商品类别标识 'typeId': funcResponse[i].genre, // 商品类别标识
'sidebarId': funcResponse[i].classifyId, // 商品分类标识 'sidebarId': funcResponse[i].classifyId, // 商品分类标识
'name': funcResponse[i].name, 'name': funcResponse[i].name,
'cover': funcResponse[i].coverImg ? funcResponse[i].coverImg : this.data.resourcesBase + 'play/shop/commodity-card.png', 'cover': funcResponse[i].coverImg ? funcResponse[i].coverImg : this.data.resourcesBase + 'play/shop/commodity-card.png',
'price': funcResponse[i].sightseerPrice, // 普通价 'price': funcResponse[i].sightseerPrice, // 普通价
'priceText': App.modular.utils.formatAmount(funcResponse[i].sightseerPrice), // 普通价文本格式 'priceText': App.modular.utils.formatAmount(funcResponse[i].sightseerPrice), // 普通价文本格式
'priceSpecial': funcResponse[i].ownerPrice, // 业主价 'priceSpecial': funcResponse[i].ownerPrice, // 业主价
'priceSpecialText': App.modular.utils.formatAmount(funcResponse[i].ownerPrice), // 业主价文本格式 'priceSpecialText': App.modular.utils.formatAmount(funcResponse[i].ownerPrice), // 业主价文本格式
'priceDiscount': funcResponse[i].price, // 活动价 'priceDiscount': funcResponse[i].price, // 活动价
'priceDiscountText': App.modular.utils.formatAmount(funcResponse[i].price), // 活动价文本格式 'priceDiscountText': App.modular.utils.formatAmount(funcResponse[i].price), // 活动价文本格式
'priceType': 1, 'priceType': 1,
'describe': funcResponse[i].synopsis, 'describe': funcResponse[i].synopsis,
'describeDetail': '', // 商品描述详情,在点击详情时获得数据 'describeDetail': '', // 商品描述详情,在点击详情时获得数据
} }
let funcUserType = wx.getStorageSync('userInfo').userType let funcUserType = wx.getStorageSync('userInfo').userType
...@@ -524,7 +513,7 @@ Page({ ...@@ -524,7 +513,7 @@ Page({
* @param * @param
* @returns * @returns
*/ */
queryMovie: function () { queryMovie: function() {
App.wxRequest({ App.wxRequest({
url: '/api/v1/film/getAllFilm', url: '/api/v1/film/getAllFilm',
data: { data: {
...@@ -547,9 +536,9 @@ Page({ ...@@ -547,9 +536,9 @@ Page({
'movieType': funcResponse[i].filmType, 'movieType': funcResponse[i].filmType,
'movieKeyWord': funcResponse[i].keyword, 'movieKeyWord': funcResponse[i].keyword,
'movieLeader': funcResponse[i].filmLead, 'movieLeader': funcResponse[i].filmLead,
'price': funcResponse[i].visitorPrice, // 普通价 'price': funcResponse[i].visitorPrice, // 普通价
'priceText': App.modular.utils.formatAmount(funcResponse[i].visitorPrice), // 普通价文本格式 'priceText': App.modular.utils.formatAmount(funcResponse[i].visitorPrice), // 普通价文本格式
'priceSpecial': funcResponse[i].ownerPrice, // 业主价 'priceSpecial': funcResponse[i].ownerPrice, // 业主价
'priceSpecialText': App.modular.utils.formatAmount(funcResponse[i].ownerPrice), // 业主价文本格式 'priceSpecialText': App.modular.utils.formatAmount(funcResponse[i].ownerPrice), // 业主价文本格式
'priceType': 1, 'priceType': 1,
'tagsId': funcResponse[i].tagIds, 'tagsId': funcResponse[i].tagIds,
...@@ -572,7 +561,7 @@ Page({ ...@@ -572,7 +561,7 @@ Page({
* @param * @param
* @returns * @returns
*/ */
getAppraise: function () { getAppraise: function() {
App.wxRequest({ App.wxRequest({
url: '/api/v1/appraise/getList', url: '/api/v1/appraise/getList',
data: { data: {
...@@ -584,19 +573,20 @@ Page({ ...@@ -584,19 +573,20 @@ Page({
let funcResponse = response.data let funcResponse = response.data
let funcList = [] let funcList = []
for (let i = 0, l = funcResponse.list.length; i< l; i++) { for (let i = 0, l = funcResponse.list.length; i < l; i++) {
let funcItem = { let funcItem = {
'star': 4, 'star': 4,
'scoreService': funcResponse.list[i].serviceEvaluation, // 服务评价 'scoreService': funcResponse.list[i].serviceEvaluation, // 服务评价
'scoreCommodity': funcResponse.list[i].productEvaluation, // 商品评价 'scoreCommodity': funcResponse.list[i].productEvaluation, // 商品评价
'scoreEnvironmental': funcResponse.list[i].environmentalEvaluation, // 环境评价 'scoreEnvironmental': funcResponse.list[i].environmentalEvaluation, // 环境评价
'userName': funcResponse.list[i].nickname, 'userName': funcResponse.list[i].nickname,
'userAvatar': funcResponse.list[i].headImg, 'userAvatar': funcResponse.list[i].headImg,
'userType': funcResponse.list[i].userType, 'userType': funcResponse.list[i].userType,
'userAlbum': funcResponse.list[i].imgUrls, // 评论图册 'userAlbum': funcResponse.list[i].imgUrls, // 评论图册
'date': funcResponse.list[i].createDate, 'date': funcResponse.list[i].createDate,
'content': funcResponse.list[i].content, 'content': funcResponse.list[i].content,
'isMore': false, 'isMore': false,
'isDetail': false,
} }
funcItem.star = Math.floor((funcItem.scoreService + funcItem.scoreCommodity + funcItem.scoreEnvironmental) / 3) funcItem.star = Math.floor((funcItem.scoreService + funcItem.scoreCommodity + funcItem.scoreEnvironmental) / 3)
funcList.push(funcItem) funcList.push(funcItem)
...@@ -609,12 +599,13 @@ Page({ ...@@ -609,12 +599,13 @@ Page({
const funcQuery = wx.createSelectorQuery() const funcQuery = wx.createSelectorQuery()
funcQuery.selectAll('.evaluate-item-content-mark').boundingClientRect() funcQuery.selectAll('.evaluate-item-content-mark').boundingClientRect()
funcQuery.exec((response) => { funcQuery.exec((response) => {
console.log(response)
let funcContentHeight = 88 * wx.getStorageSync('unitProportion') let funcContentHeight = 88 * wx.getStorageSync('unitProportion')
let funcEvaluate = this.data.detailEvaluate let funcEvaluate = this.data.detailEvaluate
let funcTextHeight = response[0] let funcTextHeight = response[0]
for (let i = 0, l = funcTextHeight.length; i < l; i++) { for (let i = 0, l = funcTextHeight.length; i < l; i++) {
if (funcContentHeight > funcTextHeight[i].height) { if (funcContentHeight < funcTextHeight[i].height) {
funcEvaluate[i].isMore = true funcEvaluate[i].isMore = true
} }
} }
...@@ -622,25 +613,28 @@ Page({ ...@@ -622,25 +613,28 @@ Page({
this.setData({ this.setData({
detailEvaluate: funcEvaluate detailEvaluate: funcEvaluate
}) })
console.log('funcEvaluate')
console.log(funcEvaluate)
}) })
} }
}) })
}, },
onBuy: function (event) { onBuy: function(event) {
let id = event.currentTarget.dataset.id let id = event.currentTarget.dataset.id
wx.navigateTo({ wx.navigateTo({
url: '/pages/play/movie-detail/movie-detail?id=' + id, url: '/pages/play/movie-detail/movie-detail?id=' + id,
}) })
}, },
onLocation: function () { onLocation: function() {
wx.navigateTo({ wx.navigateTo({
url: '/pages/home/guide/guide?id=' + Number(this.data.option.id) + '&card=false' url: '/pages/home/guide/guide?id=' + Number(this.data.option.id) + '&card=false'
}) })
}, },
// 缓存商店信息 // 缓存商店信息
setShopInfo: function (funcShopAppId, funcShopType) { setShopInfo: function(funcShopAppId, funcShopType) {
// 获取门店基本信息 // 获取门店基本信息
let funcShopId = App.globalData.shopId let funcShopId = App.globalData.shopId
for (let i = 0, l = funcShopId.length; i < l; i++) { for (let i = 0, l = funcShopId.length; i < l; i++) {
...@@ -660,17 +654,16 @@ Page({ ...@@ -660,17 +654,16 @@ Page({
} }
}, },
// 跳转到活动详情 // 跳转到活动详情
onActivityDetail: function (event) { onActivityDetail: function(event) {
let id = event.currentTarget.dataset.id let id = event.currentTarget.dataset.id
wx.navigateTo({ wx.navigateTo({
url: '/pages/play/activity-detail/activity-detail?id=' + id, url: '/pages/play/activity-detail/activity-detail?id=' + id,
}) })
}, },
onBuyCommodity: function (event) { onBuyCommodity: function(event) {
let id = event.currentTarget.dataset.id let id = event.currentTarget.dataset.id
let classifyId = event.currentTarget.dataset.classid let classifyId = event.currentTarget.dataset.classid
console.log(this.data.option)
switch (Number(this.data.option.id)) { switch (Number(this.data.option.id)) {
case 7: case 7:
let funcCommodityInfo = this.data.detailCommodity.filter(v => v.id === id)[0] let funcCommodityInfo = this.data.detailCommodity.filter(v => v.id === id)[0]
...@@ -678,7 +671,7 @@ Page({ ...@@ -678,7 +671,7 @@ Page({
funcCommodityInfo.quantityMin = 1 funcCommodityInfo.quantityMin = 1
funcCommodityInfo.quantityMax = 1 funcCommodityInfo.quantityMax = 1
funcCommodityInfo.isActive = true funcCommodityInfo.isActive = true
wx.setStorageSync('shoppingCartBuffer', [funcCommodityInfo]) wx.setStorageSync('shoppingCartBuffer', [funcCommodityInfo])
wx.navigateTo({ wx.navigateTo({
url: '/pages/play/service-sell/service-sell' url: '/pages/play/service-sell/service-sell'
...@@ -707,7 +700,7 @@ Page({ ...@@ -707,7 +700,7 @@ Page({
* @param {object} - event * @param {object} - event
* @returns * @returns
*/ */
onSelectionContent: function (event) { onSelectionContent: function(event) {
let funcContentType = event.currentTarget.dataset.type let funcContentType = event.currentTarget.dataset.type
switch (funcContentType) { switch (funcContentType) {
case 'detail': case 'detail':
...@@ -720,24 +713,27 @@ Page({ ...@@ -720,24 +713,27 @@ Page({
this.setData({ this.setData({
contentType: funcContentType contentType: funcContentType
}) })
this.getOfficeAppraise()
this.getAppraise()
break break
} }
}, },
// 跳转到服务详情 // 跳转到服务详情
onContact: function () { onContact: function() {
App.setShopInfo(Number(this.data.option.id), 3) App.setShopInfo(Number(this.data.option.id), 3)
wx.navigateTo({ wx.navigateTo({
url: '/pages/commodity/project-detail/project-detail' url: '/pages/commodity/project-detail/project-detail'
}) })
}, },
// 跳转到餐品购物车 // 跳转到餐品购物车
onBuyFood: function () { onBuyFood: function() {
App.setShopInfo(Number(this.data.option.id), 5) App.setShopInfo(Number(this.data.option.id), 5)
wx.navigateTo({ wx.navigateTo({
url: '/pages/commodity/menu-food/menu-food' url: '/pages/commodity/menu-food/menu-food'
}) })
}, },
onPageScroll: function (funcEvent) { onPageScroll: function(funcEvent) {
// 优化滚动事件触发频率 // 优化滚动事件触发频率
if (logicData.pageScrollLock) return if (logicData.pageScrollLock) return
logicData.pageScrollLock = true logicData.pageScrollLock = true
...@@ -748,7 +744,7 @@ Page({ ...@@ -748,7 +744,7 @@ Page({
this.setSideButton(funcEvent) this.setSideButton(funcEvent)
// 恢复滚动事件 // 恢复滚动事件
logicData.pageScrollTimer = setTimeout(function () { logicData.pageScrollTimer = setTimeout(function() {
logicData.pageScrollLock = false logicData.pageScrollLock = false
clearTimeout(logicData.pageScrollTimer) clearTimeout(logicData.pageScrollTimer)
}, 10) }, 10)
...@@ -760,7 +756,7 @@ Page({ ...@@ -760,7 +756,7 @@ Page({
* @param {object} - funcEvent * @param {object} - funcEvent
* @returns * @returns
*/ */
setSideButton: function (funcEvent) { setSideButton: function(funcEvent) {
if (funcEvent.scrollTop >= this.data.sideHeight) { if (funcEvent.scrollTop >= this.data.sideHeight) {
if (this.data.winSide) { if (this.data.winSide) {
this.setData({ this.setData({
...@@ -782,7 +778,7 @@ Page({ ...@@ -782,7 +778,7 @@ Page({
} }
}, },
onBackTop: function () { onBackTop: function() {
wx.pageScrollTo({ wx.pageScrollTo({
scrollTop: 0 scrollTop: 0
}) })
...@@ -794,7 +790,7 @@ Page({ ...@@ -794,7 +790,7 @@ Page({
* @param {object} - funcEvent * @param {object} - funcEvent
* @returns * @returns
*/ */
eventSwiperChange: function (funcEvent) { eventSwiperChange: function(funcEvent) {
this.setData({ this.setData({
bannerIndex: funcEvent.detail.current bannerIndex: funcEvent.detail.current
}) })
...@@ -811,19 +807,19 @@ Page({ ...@@ -811,19 +807,19 @@ Page({
}) })
}, },
// 点击分享图标 // 点击分享图标
onShare: function () { onShare: function() {
this.setData({ this.setData({
showPopup: true showPopup: true
}) })
}, },
// 点击取消 // 点击取消
onCancel: function () { onCancel: function() {
this.setData({ this.setData({
showPopup: false showPopup: false
}) })
}, },
// 点击下载图片 // 点击下载图片
onDownload: function () { onDownload: function() {
wx.downloadFile({ wx.downloadFile({
url: this.data.shareImage, url: this.data.shareImage,
success: (result) => { success: (result) => {
...@@ -850,9 +846,9 @@ Page({ ...@@ -850,9 +846,9 @@ Page({
}) })
}, },
// 跳转到文创商品商店 // 跳转到文创商品商店
onArtAll: function () { onArtAll: function() {
wx.navigateTo({ wx.navigateTo({
url: '/pages/commodity/menu-art/menu-art', url: '/pages/commodity/menu-art/menu-art',
}) })
}, },
...@@ -862,10 +858,10 @@ Page({ ...@@ -862,10 +858,10 @@ Page({
* @param {object} - funcEvent * @param {object} - funcEvent
* @returns * @returns
*/ */
onActivityAll: function () { onActivityAll: function() {
wx.navigateTo({ wx.navigateTo({
url: '/pages/play/activity/activity?fromPage=serviceDetail', url: '/pages/play/activity/activity?fromPage=serviceDetail',
}) })
}, },
/** /**
...@@ -874,14 +870,14 @@ Page({ ...@@ -874,14 +870,14 @@ Page({
* @param * @param
* @returns * @returns
*/ */
onCommodityAll: function () { onCommodityAll: function() {
switch (Number(this.data.option.id)) { switch (Number(this.data.option.id)) {
case 7: case 7:
wx.navigateTo({ wx.navigateTo({
url: '/pages/commodity/project-detail/project-detail', url: '/pages/commodity/project-detail/project-detail',
}) })
break break
default: default:
wx.navigateTo({ wx.navigateTo({
url: '/pages/commodity/menu-food/menu-food', url: '/pages/commodity/menu-food/menu-food',
...@@ -889,13 +885,13 @@ Page({ ...@@ -889,13 +885,13 @@ Page({
} }
}, },
onMovieAll: function () { onMovieAll: function() {
wx.navigateTo({ wx.navigateTo({
url: '/pages/play/movie/movie', url: '/pages/play/movie/movie',
}) })
}, },
// 查询门店评分 // 查询门店评分
getOfficeAppraise: function () { getOfficeAppraise: function() {
let that = this let that = this
let officeId = wx.getStorageSync('shopInfoBuffer').id let officeId = wx.getStorageSync('shopInfoBuffer').id
App.wxRequest({ App.wxRequest({
...@@ -903,7 +899,7 @@ Page({ ...@@ -903,7 +899,7 @@ Page({
data: { data: {
'officeId': officeId 'officeId': officeId
}, },
success: function (response) { success: function(response) {
let funcData = response.data let funcData = response.data
that.setData({ that.setData({
officeServiceText: funcData.serviceEvaluation.toFixed(1), officeServiceText: funcData.serviceEvaluation.toFixed(1),
...@@ -920,12 +916,12 @@ Page({ ...@@ -920,12 +916,12 @@ Page({
* @param * @param
* @returns * @returns
*/ */
onEvaluateMore: function (event) { onEvaluateMore: function(event) {
let funcItem = event.currentTarget.dataset.item let funcItem = event.currentTarget.dataset.item
let funcIndex = event.currentTarget.dataset.index let funcIndex = event.currentTarget.dataset.index
let funcEvaluate = this.data.detailEvaluate let funcEvaluate = this.data.detailEvaluate
funcEvaluate[funcIndex].isMore = true funcEvaluate[funcIndex].isDetail = true
this.setData({ this.setData({
detailEvaluate: funcEvaluate detailEvaluate: funcEvaluate
...@@ -938,7 +934,7 @@ Page({ ...@@ -938,7 +934,7 @@ Page({
* @param * @param
* @returns * @returns
*/ */
onEvaluateAlbum: function (event) { onEvaluateAlbum: function(event) {
let funcItem = event.currentTarget.dataset.item let funcItem = event.currentTarget.dataset.item
let funcIndex = event.currentTarget.dataset.index let funcIndex = event.currentTarget.dataset.index
...@@ -955,7 +951,7 @@ Page({ ...@@ -955,7 +951,7 @@ Page({
* @param * @param
* @returns * @returns
*/ */
onHiddenEvaluateAlbum: function () { onHiddenEvaluateAlbum: function() {
this.setData({ this.setData({
winEvaluateAlbum: false winEvaluateAlbum: false
}) })
......
...@@ -228,18 +228,17 @@ ...@@ -228,18 +228,17 @@
</view> </view>
<!-- 评论隐藏样式 --> <!-- 评论隐藏样式 -->
<view class="evaluate-item-content" wx:if="{{!item.isMore}}"> <view class="evaluate-item-content" wx:if="{{!item.isDetail}}">
<view class="evaluate-item-content-mark"> <view>
<text>{{item.content}}</text> <text class="evaluate-item-content-mark">{{item.content}}</text>
</view> </view>
<view class="evaluate-item-content-more" data-item="{{item}}" data-index="{{index}}" bindtap="onEvaluateMore"> <view wx:if="{{item.isMore}}" class="evaluate-item-content-more row con-e align-e" data-item="{{item}}" data-index="{{index}}" bindtap="onEvaluateMore">
<text>... </text>
<text>全文</text> <text>全文</text>
</view> </view>
</view> </view>
<!-- 评论展开样式 --> <!-- 评论展开样式 -->
<view class="evaluate-item-content-whole" wx:if="{{item.isMore}}"> <view class="evaluate-item-content-whole" wx:if="{{item.isDetail}}">
<view> <view>
<text>{{item.content}}</text> <text>{{item.content}}</text>
</view> </view>
...@@ -418,37 +417,48 @@ ...@@ -418,37 +417,48 @@
<view class="evaluate-list col"> <view class="evaluate-list col">
<block wx:for="{{detailEvaluate}}" wx:for-index="index" wx:for-item="item" wx:key="index"> <block wx:for="{{detailEvaluate}}" wx:for-index="index" wx:for-item="item" wx:key="index">
<view class="evaluate-item col"> <view class="evaluate-item col" style="border-bottom: 1rpx solid #3A3A40">
<view class="row"> <view class="row">
<image class="evaluate-item-avatar" src="{{item}}" mode="widthFix"></image> <image class="evaluate-item-avatar" src="{{item.userAvatar}}" mode="widthFix"></image>
<view class="evaluate-item-info"> <view class="evaluate-item-info">
<view class="evaluate-item-info-text row align-c"> <view class="evaluate-item-info-text row align-c">
<text>{{item.name}}</text> <text style="color: #FFFFFF">{{item.userName}}</text>
<text>业主</text> <text>业主</text>
<text>{{item.date}}</text> <text style="color: #656E7B">{{item.date}}</text>
</view> </view>
<view class="evaluate-item-info-star row align-c"> <view class="evaluate-item-info-star row align-c">
<block wx:for="{{item.star}}" wx:for-index="indexStar" wx:for-item="itemStar" wx:key="indexStar"> <block wx:for="{{item.star}}" wx:for-index="indexStar" wx:for-item="itemStar" wx:key="indexStar">
<image src="{{imageBase + 'icon/star-1.png'}}"></image> <image src="{{imageBase + 'icon/star-1.png'}}" data-item="{{item}}"></image>
</block> </block>
</view> </view>
</view> </view>
</view> </view>
<view class="evaluate-item-content"> <!-- 评论隐藏样式 -->
<view class="evaluate-item-content" wx:if="{{!item.isDetail}}">
<view> <view>
<text class="color-white">{{item.content}}</text> <text class="evaluate-item-content-mark" style="color: #FFFFFF">{{item.content}}</text>
</view> </view>
<view class="evaluate-item-content-more-movie"> <view wx:if="{{item.isMore}}" class="evaluate-item-content-more row con-e align-e" style="background: #1C1C25;" data-item="{{item}}" data-index="{{index}}" bindtap="onEvaluateMore">
<text class="color-white">... </text>
<text>全文</text> <text>全文</text>
</view> </view>
</view> </view>
<!-- 评论展开样式 -->
<view class="evaluate-item-content-whole" wx:if="{{item.isDetail}}">
<view>
<text style="color: #FFFFFF">{{item.content}}</text>
</view>
</view>
<view class="evaluate-item-album"> <view class="evaluate-item-album">
<block wx:for="{{item.imgUrls}}" wx:for-index="indexAlbum" wx:for-item="itemAlbum" wx:key="indexAlbum"> <block wx:for="{{item.userAlbum}}" wx:for-index="indexAlbum" wx:for-item="itemAlbum" wx:key="indexAlbum">
<image src="{{itemAlbum}}" bindtap="onPreviewImage" data-index="{{index}}" data-url="{{itemAlbum}}"></image> <image wx:if="{{indexAlbum < 4}}" src="{{itemAlbum}}" data-index="{{indexAlbum}}" data-item="{{item}}" bindtap="onEvaluateAlbum"></image>
</block> </block>
<view wx:if="{{item.userAlbum.length > 4}}" class="evaluate-item-album-more row con-c align-c" data-index="{{3}}" data-item="{{item}}" bindtap="onEvaluateAlbum">
<text>{{'+' + (item.userAlbum.length - 4)}}</text>
</view>
</view> </view>
</view> </view>
</block> </block>
......
...@@ -812,7 +812,7 @@ ...@@ -812,7 +812,7 @@
text-align: right; text-align: right;
font-size: 26rpx; font-size: 26rpx;
font-weight: 400; font-weight: 400;
line-height: 44rpx; line-height: 32rpx;
} }
.evaluate-item-content-more-movie { .evaluate-item-content-more-movie {
...@@ -828,15 +828,7 @@ ...@@ -828,15 +828,7 @@
line-height: 44rpx; line-height: 44rpx;
} }
.evaluate-item-content-more text:nth-child(1) { .evaluate-item-content-more text {
color: #15191f;
}
.evaluate-item-content-more text:nth-child(2) {
color: #86c5e1;
}
.evaluate-item-content-more-movie text:nth-child(2) {
color: #86c5e1; color: #86c5e1;
} }
......
...@@ -4,8 +4,13 @@ ...@@ -4,8 +4,13 @@
* win,窗口显隐控制,通常数值为布尔类型。例如 winToast,winDialog。 * win,窗口显隐控制,通常数值为布尔类型。例如 winToast,winDialog。
* func,函数内部变量前缀。 * func,函数内部变量前缀。
* *
* 代码编写规范 - js - 变量命名禁忌
* 避免无意义命名,如 list,data,等等。
*
* 代码编写规范 - js - 常用变量命名 * 代码编写规范 - js - 常用变量命名
* option,页面参数对象 * option,页面参数对象
* userInfo,用户信息对象 * userInfo,用户信息对象
* *
* 代码编写规范 - js - 函数命名
* query
*/ */
\ No newline at end of file
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 sign in to comment