Commit f4fff9b1c7d0f9ad960e4180f1f0907c82c4250a

Authored by yiren
1 parent 9a0ce286

提前点餐

... ... @@ -102,7 +102,8 @@
"pages/remark",
"pages/index_new",
"pages/cart_new",
"pages/success_new"
"pages/success_new",
"pages/favourableList"
]
},
{
... ...
... ... @@ -105,11 +105,15 @@ page {
.btns button {
width: 50%;
box-sizing: border-box;
color: #fff;
color: #BFC4D4;
height: 100%;
border-radius: 0;
}
.btns button:nth-of-type(1) {
color: #fff;
}
.continue {
background: #4d4e50;
border: 2rpx solid #094ba4;
... ...
// pack-cookbook/pages/favourableList.js
import util from '../../utils/util'
Page({
/**
* 页面的初始数据
*/
data: {
sellerName:'',
sellerid:'',
oid:'',
list:[]
},
/**
* 生命周期函数--监听页面加载
*/
onLoad(options) {
this.setData({
sellerName: options.sellerName,
sellerid: options.sellerid,
oid: options.oid,
})
},
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady() {
this.setData({
list:[
{id:'1',name:'充500赠100',info:'会员充值满500元赠余额100元。',stime:'2022年12月18日',etime:'2023年10月30日'},
{id:'2',name:'充500赠100',info:'会员充值满500元赠余额100元。',stime:'2022年12月18日',etime:'2023年10月30日'},
{id:'3',name:'充500赠100',info:'会员充值满500元赠余额100元。',stime:'2022年12月18日',etime:'2023年10月30日'},
{id:'4',name:'充500赠100',info:'会员充值满500元赠余额100元。',stime:'2022年12月18日',etime:'2023年10月30日'},
]
})
},
gogoSingle(e){
const id= e.currentTarget.dataset['id'];
let url=util.http_build_query({sid:this.data.sellerid,name:this.data.sellerName,types:'1',oid:this.data.oid,id},'/pack-activity/pack/vipRecharge')
wx.navigateTo({
url
})
},
/**
* 生命周期函数--监听页面显示
*/
onShow() {
},
/**
* 生命周期函数--监听页面隐藏
*/
onHide() {
},
/**
* 生命周期函数--监听页面卸载
*/
onUnload() {
},
/**
* 页面相关事件处理函数--监听用户下拉动作
*/
onPullDownRefresh() {
},
/**
* 页面上拉触底事件的处理函数
*/
onReachBottom() {
},
/**
* 用户点击右上角分享
*/
onShareAppMessage() {
}
})
\ No newline at end of file
... ...
{
"backgroundTextStyle": "light",
"navigationBarBackgroundColor": "#fff",
"navigationBarTextStyle": "white",
"usingComponents": {
"nav": "/components/nav/nav"
}
}
\ No newline at end of file
... ...
<!--pack-cookbook/pages/favourableList.wxml-->
<nav></nav>
<view class="box">
<view wx:for="{{list}}" class="single" bindtap="gogoSingle" data-id="{{item.id}}">
<view class="topBox">
<view class="name font32r">
{{item.name}}
</view>
<view class="texts info font24r">
{{item.info}}
{{item.info}}
{{item.info}}
</view>
</view>
<view class="texts time font24r">
有效期限:{{item.etime}}至{{item.stime}}
</view>
</view>
</view>
\ No newline at end of file
... ...
/* pack-cookbook/pages/favourableList.wxss */
page{
background: #F3F3F3;
}
.box{
padding: 32rpx 40rpx;
}
.single{
width: 100%;
height: 240rpx;
border-radius: 16rpx;
background-color: #FFFFFF;
box-shadow: 0rpx 8rpx 8rpx #00000040;
margin-bottom: 32rpx;
}
.topBox{
width: 100%;
display: flex;
flex-direction: column;
justify-content: space-between;
}
.name{
background-color: #0143A3;
height: 37%;
line-height: 60rpx;
padding-left: 40rpx;
color: #ffffff;
font-family: PingFang SC;
font-weight: 500;
border-top-left-radius: 10rpx;
border-top-right-radius: 10rpx;
}
.texts{
padding-left: 40rpx;
color: #999999;
font-family: PingFang SC;
height: 62%;
}
.topBox{
height: 68%;
border-bottom: 2rpx dashed #bfc4d4;
}
.time{
height: 70rpx;
line-height: 70rpx;
}
\ No newline at end of file
... ...
... ... @@ -285,7 +285,9 @@ Page({
}
cook.item_clear_num = item_clear_num;
cook.index = n; //分类下菜品的下标
cook.norms = []; //做法规格
if(cook.norms.length==0){
cook.norms = []; //做法规格
}
// let type;//模拟种类 1为一行显示1个 2为一行显示2个
// if(n=='0' || n=='3'){
// type='1'
... ... @@ -331,12 +333,11 @@ Page({
// 获取所有分类下所有菜品列表
getCookList(orderid) {
let cookbooklist=wx.getStorageSync('cookbooklist');
console.log(cookbooklist,'cookbooklistcookbooklist');
let cookbooklistStorage=cookbooklist?JSON.parse(cookbooklist):'';
console.log('cookbooklist历史数据',cookbooklistStorage);
if(cookbooklistStorage.length>0){
this.setData({
cookbooklist:cookbooklistStorage,
cookbooklist:this.formatCookList(cookbooklistStorage),
isloading: false,
showSkeleton: false,
})
... ...
... ... @@ -39,7 +39,7 @@
</view>
<view class="norms">{{item.first_name}}</view>
</block>
<image src="{{item.image}}" class="dishImg" mode="aspectFill" />
<image wx:if="{{item.image}}" src="{{item.image}}" class="dishImg" mode="aspectFill" />
<view class="greens">
<view class="news">{{item.first_name}}</view>
</view>
... ...
... ... @@ -332,67 +332,6 @@ page {
width: 100rpx;
height: 100rpx;
}
/* .tui-fixed-x{
width: 100%;
position: fixed;
top: 0;
left: 0;
}
.tui-city-scroll{
height: 220rpx;
line-height: 80rpx;
width: 100%;
white-space: nowrap;
}
.tui-city-scroll text{
height: 120rpx;
line-height: 80rpx;
width: 100%;
white-space: nowrap;
}
.tui-nav-li{
font-size: 33rpx;
padding: 0 10rpx;
}
.tui-nav-li:first-child{padding-left: 16rpx;}
.tui-nav-li:last-child{padding-right: 16rpx;}
.tui-nav-active{
color: red;
border-bottom: 3rpx solid red;
}
.tui-fixed-y{
width: 100%;
height: calc(100% - 80rpx);
position: fixed;
bottom: 0;
left: 0;
}
.tui-city-scroll-y{
padding: 0 20rpx;
height: 100%;
box-sizing: border-box;
}
.tui-list-head{
height: 50px;
line-height: 50px;
text-align: center;
font-size: 30rpx;
color: blue;
}
.tui-list-li{
height: 400px;
padding: 10rpx;
color: #fff;
font-size: 50rpx;
background-color: #2EB3FF;
} */
\ No newline at end of file
.determine{
color: #E34D59;
}
... ...
... ... @@ -75,10 +75,21 @@ Page({
},
// 菜品更换
continueOrdering(){
// wx.nextTick(()=>{
// })
// wx.navigateBack()
// console.log(getCurrentPages());
wx.reLaunch({
url: `/pack-cookbook/pages/index_new?rid=${this.data.rid}&sid=${this.data.sellerid}&oid=${this.data.oid}&sellerName=${this.data.sellerName}&identity=1`,
})
},
// 点击了解更多会员优惠政策
gotoFavourableList(){
let url=util.http_build_query({
sellerName:this.data.sellerName,
sellerid:this.data.sellerid,
oid:this.data.oid
},'/pack-cookbook/pages/favourableList')
console.log(url);
wx.navigateTo({
url
})
},
getSellerTemplateConfFun(sid) {
console.log(sid, 'sidsidsidsid');
... ...
... ... @@ -91,9 +91,11 @@
</navigator>
</view>
</view>
<!-- <view wx:if="{{marketing.is_link}}" class="font24r favouredPolicy">
点击了解更多会员优惠政策
</view> -->
<view class="favouredPolicy">
<view class="font24r policy" bindtap="gotoFavourableList">
点击了解更多会员优惠政策
</view>
</view>
</view>
</scroll-view>
<view class="btns flex-cc">
... ...
... ... @@ -212,8 +212,14 @@ page {
color: #E34D59;
}
.favouredPolicy {
width: 60%;
.favouredPolicy{
display: flex;
justify-content: flex-end;
margin-right: 60rpx;
}
.policy{
width: 50%;
color: #999999;
font-family: PingFang SC;
font-weight: 500;
... ...