小程序外卖订单界面的 代码

html页面

.

<view class="container"><view class="store-box"><view class="st-bg"></view><view class=" flex justify-between store-info"><view class=" flex flex-direction justify-start" style="width:530rpx"><view class="name">热门热门热门</view><view class="start-box flex"><image wx:for="{{4}}" class="st-img" src="../../../images/store/start.png"></image><image class="st-img" src="../../../images/store/unstart.png"></image><view class="text">4.2分数</view></view><view class="tiem">营业时间:9:00~22:00营业</view><view class="msg">公告:可随时联系我们,我们提供外卖服务</view></view><image class="store-logo" src="../../../images/store/logo.png" alt="" /></view><view class="flex justify-start align-center tabs-box"><view bindtap="changeCenten" data-id="1" class="tabs-item {{tabs==1?'active':''}}">商品</view><view bindtap="changeCenten" data-id="2" class="tabs-item {{tabs==2?'active':''}}">评价<textclass="num">(241)</text></view><view bindtap="changeCenten" data-id="3" class="tabs-item {{tabs==3?'active':''}}">商家</view></view></view><!-- 商品下单页面 --><view class="index-cont" wx:if="{{tabs==1}}"><!-- 左边类型 --><view class="index-left"><view wx:for="{{foodsList}}" wx:key="index" class="item {{curId === 'item'+index?'on':''}}"data-id="item{{index}}" bindtap="scrollToViewFn">{{item.name}}</view></view><!-- 右边产品 --><scroll-view class="index-right" scroll-y="{{true}}" scroll-into-view="{{initView}}" scroll-with-animation="true"bindscroll="onPageScroll"><view class="boxs"><block wx:for="{{foodsList}}" wx:key="index"><view class="index-title" id="item{{index}}">{{item.name}}</view><view class="item" wx:for="{{item.list}}" wx:key="ind" wx:for-item="itm" wx:for-index="ind"bindtap="showGoodDetail(itm)"><view class="pic"><image src="{{itm.pic}}" mode="aspectFill"></image></view><view class="main"><view class="tit">{{itm.title}}</view><view class="desc">{{itm.info}}</view><view class="money">¥{{itm.price}}</view></view><view class="box"><view wx:if="{{itm.num !== 0}}" class="icon" data-index="{{index}}" data-ind="{{ind}}" data-item="{{itm}}"catchtap="reduceNum"><image src="../../../images/store/reduce-icon.png" alt=""></image></view><input wx:if="{{itm.num !== 0}}" type="text" disabled value="{{itm.num}}" /><view class="icon" data-index="{{index}}" data-ind="{{ind}}" data-item="{{itm}}" catchtap="addNum"><image src="../../../images/store/add-icon.png" alt=""></image></view></view></view></block></view></scroll-view></view><view class="index-cart" wx:if="{{tabs==1}}"><view class="left"><view class="cart-num" wx:if="{{cartList.length === 0}}"><image src="../../../images/store/cart.png"></image></view><view class="cart-num on" wx:else bindtap="showCartMask"><image src="../../../images/store/cart.png"></image><view class="total-box"><text class="mon">{{totalNum}}</text></view></view><view class="cart-money flex flex-direction content"><view class="mon">¥{{totalMoney}}</view><view class="lable">本单合计</view></view></view><view class="order-btn" bindtap="submitOrder">去结算</view></view><!--购物车弹窗--><!-- wx:if="{{isShowCartMask && cartList.length !== 0}}" --><view class="dialog {{isShowCartMask && cartList.length !== 0?'':'hide'}}" bindtap="hiddenCartMak"><view class="boxs" catchtap="stopMaopao()"><view class="title-block"><text>已选商品</text><view class="clear" bindtap="clearCart">X</view></view><scroll-view class="content" scroll-y="{{true}}" scroll-with-animation="true"><block wx:for="{{cartList}}" wx:key="index"><view class="item" id="{{item.view}}"><view class="pic"><image src="{{item.pic}}" mode="aspectFill"></image></view><view class="main"><view class="tit">{{item.name}}</view><view class="desc">{{item.info}}</view><view class="money">¥{{item.price}}</view></view><view class="right"><view class="box"><view class="icon" data-index="{{index}}" data-item="{{item}}" bindtap="reduceCart"><image src="../../../images/store/reduce-icon.png" alt=""></image></view><input type="text" disabled value="{{item.num}}" /><view class="icon" data-index="{{index}}" data-item="{{item}}" bindtap="addCart"><image src="../../../images/store/add-icon.png" alt=""></image></view></view></view></view></block></scroll-view></view></view><!--商品详情弹窗--><view class="dialog1" wx:if="{{isShowDetail}}"><scroll-view class="detbox" scroll-y="{{true}}" scroll-with-animation="true"><image class="img" src="{{goodDetail.pic}}" mode="aspectFit"></image><view class="box"><view class="tit">{{goodDetail.title}}</view><view class="money">¥{{goodDetail.price}}</view><view class="desc">{{goodDetail.info}}</view></view><view class="close" bindtap="hideDetail"><image src="../../../images/store/close_ico.png"></image></view></scroll-view></view><!-- 评价内容 --><view class="comment-box" wx:if="{{tabs==2}}"><view class="flex justify-between com-item"><image class="avatar" src="../../../images/store/logo.png"></image><view class="con-content"><view class="flex justify-between tit-box"><view class="l-box"><view class="tit">学习使我快乐</view><view class="start-box flex"><image wx:for="{{4}}" class="st-img" src="../../../images/store/start.png"></image><image class="st-img" src="../../../images/store/unstart.png"></image></view></view><view class="r-box">2020.11.14</view></view><view class="c-info">不错不错,吃的很快就完成上菜了,而且价格也比我预想的要便宜,味道也不错</view><view class=" store-img-box de-item"><view class="img-scroll-box" style="width: {{10*200}}rpx;"><image class="store-img" wx:for="{{10}}" src="../../../images/store/logo.png"></image></view></view></view></view></view><!-- 商家内容 --><view class="store-detail"  wx:if="{{tabs==3}}"><view class="flex de-item"><image class="a-icon" src="../../../images/store/location.png"></image><view class="text">深圳市宝安区西乡街道预约社区轻铁花园820栋129</view><view class="line">|</view><image class="r-icon" src="../../../images/store/phone.png"></image></view><view class=" store-img-box de-item"><view class="img-scroll-box" style="width: {{10*209}}rpx;"><image class="store-img" wx:for="{{10}}" src="../../../images/store/logo.png"></image></view></view><view class="flex de-item"><image class="l-icon" src="../../../images/store/date.png"></image><view class="text">营业时间:9:00-22:00</view></view><view class="flex de-item"><image class="l-icon" src="../../../images/store/msg.png"></image><view class="text">公告:可随时联系我们,我们提供外卖服务</view></view></view>
</view>

JS

 const goods = require("goods.js");Page({data: {foodsList: [], // 商品数据cartList: [], // 购物车数据isShowCartMask: false,totalNum: 0,totalMoney: 0,initView: 'item0', // 根据此变量的变化,控制左侧选中状态、右侧滑动curId: 'item0',isShowDetail: false,goodDetail: {},screenWidth: 0, // 手机屏幕宽度heightArray: [0], // 右侧每一个类型的高度区间数组tabs:2,},onLoad() {console.log("goods:", goods)this.setData({foodsList:goods.goods})this.getGoodsData()},// 方法async getGoodsData() {const that = this//  const res = await getGoodsInfo({})let res=[]//  this.foodsList = reswx.getSystemInfo({success: (ress) => {that.screenWidth = ress.windowWidth}})this.getHeightSection()},// 设置高度区间 所有单位转化为rpxgetHeightSection() {const that = thislet hg = 0for (let index = 0; index < that.data.foodsList.length - 1; index++) {hg += 70 + that.data.foodsList[index].list.length * 212that.data.heightArray.push(hg)}},// 获取高度区间的下标getHeightIndex(arr, hg) {const that = thisarr.forEach((item, index) => {if (hg >= item) {that.setData({curId: 'item' + index})}})},// 左边菜单控制右边scrollToViewFn(e) {this.setData({initView: e.target.dataset.id,curId: e.target.dataset.id})},// 右边滚动控制左边onPageScroll(e) {const that = thislet scrollTop = e.detail.scrollTop * 750 / that.screenWidththis.getHeightIndex(that.data.heightArray, scrollTop)},// 商品列表的减号点击reduceNum(e) {const that = thislet {ind,index,item} =e.currentTarget.datasetvar cartList = that.data.cartListlet val = 'foodsList[' + index + '].list[' + ind + '].num'this.setData({[val]: item.num - 1})// 如果商品为0,就把当前商品在购物车清除// 如果不为0, 就将当前商品数量减1if (that.data.foodsList[index].list[ind].num === 0) {that.removeAarry(that.data.cartList, item.id)} else {cartList.forEach((itm, i) => {if (itm.id === item.id) {//  let value = 'cartList[' + i + '].num'//  that.setData({//    [value]: itm.num - 1//  })cartList[i].num=itm.num - 1that.setData({cartList: cartList})}})}this.computed()},// 商品列表的加号点击addNum(e) {let {ind,index,item} =e.currentTarget.datasetconst that = thislet cartList=that.data.cartListlet val = 'foodsList[' + index + '].list[' + ind + '].num'console.log("val",val)this.setData({[val]: item.num + 1})// 如果商品为1,就把当前商品加入购物车// 否则, 就将当前商品数量加1if (that.data.foodsList[index].list[ind].num === 1) {let val = {id: item.id,name: item.title,price: item.price,num: 1,index: index,ind: ind,pic: item.pic}cartList.push(val)console.log("cartList",cartList)that.setData({cartList:cartList})} else { cartList.forEach((itm, i) => {if (itm.id === item.id) {//  let value = 'cartList[' + i + '].num'//  that.setData({//    [value]: itm.num + 1//  })let value = cartList[i].num=itm.num + 1}})}that.setData({'cartList': cartList})//  that.setData({//   cartList: that.data.cartList// })this.computed()},// 购物车的减号点击reduceCart(e) {let {index,item} =e.currentTarget.datasetconst that = thislet val = 'foodsList[' + item.index + '].list[' + item.ind + '].num'let val1 = 'cartList[' + index + '].num'this.setData({[val]: item.num - 1,[val1]: item.num - 1})// 如果商品为0,就把当前商品在购物车清除// 如果不为0, 就将当前商品数量减1if (that.data.cartList[index].num === 0) {that.removeAarry(that.data.cartList, item.id)}this.computed()},// 购物车的加号点击addCart(e) {let {index,item} =e.currentTarget.datasetconsole.log("ee",e.currentTarget.dataset)const that = thislet val = 'cartList[' + index + '].num'that.setData({[val]: item.num + 1})this.computed()},// 清空购物车clearCart() {const that = thiswx.showModal({title: '提示',content: '清空购物车?',success: function (res) {if (res.confirm) {that.setData({cartList: []})that.data.foodsList.forEach((item, i) => {item.data.list.forEach((itm, j) => {let value = 'foodsList[' + i + '].list[' + j + '].num'that.setData({[value]: 0})})})that.computed()}}})},// 计算选择商品总价格和总数量computed() {const that = thislet num = 0let money = 0console.log("computed:",that.data.cartList)that.data.cartList.forEach(item => {num += item.nummoney += parseFloat(item.price) * item.num})that.setData({totalNum: num,totalMoney: money.toFixed(2)})},// 将数量为0的时候,对应商品在购物车中删除removeAarry(arr, id) {arr.forEach((item, index) => {if (item.id === id) {arr.splice(index, 1)}})this.setData({"cartList":arr})//  return arr},showCartMask() {//  this.isShowCartMask = !this.isShowCartMaskthis.setData({"cartList":this.data.cartList,'isShowCartMask':!this.data.isShowCartMask})},hiddenCartMak() {this.setData({'isShowCartMask':false})//  this.isShowCartMask = false},stopMaopao() {},showGoodDetail(item) {this.goodDetail = itemthis.isShowDetail = true},hideDetail() {this.setData({'isShowDetail':false})},// 订单提交submitOrder() {},changeCenten(e){console.log(e)let tabs=e.currentTarget.dataset.idthis.setData({tabs:tabs})}})

CSS

page {height: 100%;
}.container {height: 100vh;background-color: #fff;box-sizing: border-box;overflow: hidden;
}
.container .dialog1 {width: 100%;height: 100vh;position: fixed;top: 0;left: 0;background-color: rgba(0, 0, 0, 0.5);z-index: 4;
}
.container .dialog1 .detbox {position: fixed;bottom: 0;left: 0;right: 0;background-color: #fff;width: 100%;max-height: 700rpx;overflow-y: auto;color: #333;border-radius: 40rpx 40rpx 0 0;
}
.container .dialog1 .detbox .img {width: 100%;height: 375rpx;background: rgba(0, 0, 0, 0.6);
}
.container .dialog1 .detbox .box {padding: 20rpx 30rpx 40rpx;box-sizing: border-box;
}
.container .dialog1 .detbox .box .tit {font-size: 28rpx;color: #333;font-weight: bold;
}
.container .dialog1 .detbox .box .money {font-size: 26rpx;color: #f00;margin: 10rpx 0;
}
.container .dialog1 .detbox .box .desc {font-size: 22rpx;color: #666;line-height: 32rpx;
}
.container .dialog1 .detbox .close {width: 50rpx;height: 50rpx;position: absolute;right: 20rpx;top: 20rpx;display: flex;align-items: center;justify-content: center;
}
.container .dialog1 .detbox .close image {width: 40rpx;height: 40rpx;
}
.container .dialog {width: 100%;height: 100vh;position: fixed;top: 0;left: 0;background-color: rgba(0, 0, 0, 0.5);z-index: 2;
}
.container .dialog .boxs {position: fixed;bottom: 100rpx;left: 0;right: 0;z-index: 6;background-color: #fff;width: 100%;max-height: 600rpx;color: #333;border-radius: 20px 20px 0px 0px;
}
.container .dialog .boxs .title-block {margin: 30rpx 30rpx 10rpx;box-sizing: border-box;display: flex;align-items: center;justify-content: space-between;height: 45rpx;font-size: 32Rpx; font-weight: 400;color: #333333;
}
.container .dialog .boxs .title-block text {font-size: 26rpx;color: #666;
}
.container .dialog .boxs .title-block .clear {font-size: 22rpx;color: rgba(112, 112, 112, 1);display: flex;align-items: center;
}
.container .dialog .boxs .title-block .clear image {width: 24rpx;height: 24rpx;margin-right: 10rpx;
}
.container .dialog .boxs .content {width: 100%;max-height: 530rpx;overflow-y: auto;padding-bottom: 30rpx;box-sizing: border-box;
}
/* .container .dialog .boxs .content .item {width: 690rpx;height: 80rpx;line-height: 80rpx;margin: 0 auto;position: relative;display: flex;align-items: center;justify-content: space-between;
} */
.container .dialog .boxs .content .item{margin: 20rpx 30rpx;width: 690rpx;box-sizing: border-box;display: flex;justify-content: space-between;position: relative;height: 120rpx;
}.container .dialog .boxs .content .item .tit {width: 400rpx;overflow: hidden;text-overflow: ellipsis;white-space: nowrap;font-size: 28rpx;color: #333;
}
.container .dialog .boxs .content  .item .main {width: 565rpx;padding-left: 30rpx;box-sizing: border-box;
}
.container .dialog .boxs .content .item .right {display: flex;justify-content: flex-start;align-items: center;height: 80rpx;
}
.container .dialog .boxs .content .item .right text {font-size: 26rpx;color: #f00;
}
.container .dialog .boxs .content .item .right .box {display: flex;justify-content: flex-start;align-items: center;flex-wrap: nowrap;margin-left: 20rpx;height: 80rpx;
}
.container .dialog .boxs .content .item .right .box .icon {width: 34rpx;height: 34rpx;display: flex;align-items: center;justify-content: center;
}
.container .dialog .boxs .content .item .right .box .icon image {width: 34rpx;height: 34rpx;
}
.container .dialog .boxs .content .item .right .box input {width: 60rpx;height: 34rpx;border: none;color: #333;text-align: center;font-size: 26rpx;
}
.store-box{position: relative;width: 750;overflow: hidden;height: 342rpx;
}
.st-bg{width: 100%;height: 116rpx;background: rgba(53, 212, 171, 1);
}
.container .index-cont {height: calc(100vh - 442rpx);display: flex;justify-content: space-between;
}
.container .index-cont .index-left {width: 150rpx;height: 100%;background: rgba(246, 248, 251, 1);
}
.container .index-cont .index-left .item {font-size: 26rpx;color: rgba(153, 153, 153, 1);/* border-bottom: 1rpx dashed #666; */height: 72rpx;line-height: 72rpx;padding: 0 20rpx;box-sizing: border-box;
}
.container .index-cont .index-left .item.on {background: #fff;color: rgba(51, 51, 51, 1);
}
.container .index-cont .index-right {width: 600rpx;height: 100%;
}
.container .index-cont .index-right .boxs {margin: 0 30rpx;box-sizing: border-box;width: 100%;
}
.container .index-cont .index-right .index-title {margin: 30rpx 0;height: 40rpx;line-height: 40rpx;/* background: #f7f7f7; */font-size: 28rpx;font-weight: 800;color: #333333;box-sizing:content-box;
}.item {margin: 20rpx 0;width: 540rpx;box-sizing: border-box;display: flex;justify-content: space-between;position: relative;height: 120rpx;
}.item::after {position: absolute;top: 0rpx;left: 0;/* background: #ccc;width: 100%;height: 1rpx;content: ""; */
}.item .pic {width: 120rpx;height: 120rpx;
}.item .pic image {width: 100%;height: 100%;
}.item .main {width: 380rpx;padding-left: 30rpx;box-sizing: border-box;
}.item .main .tit {font-size: 26rpx;color: #333;font-weight: bold;
}.item .main .desc {color: #999;min-height: 28rpx;line-height: 28rpx;margin: 4rpx 0 3rpx;font-size: 20px;font-weight: 500;color: #999999;
}.item .main .money {font-size: 28rpx;color: #f00;
}.item .box {display: flex;justify-content: flex-start;align-items: center;flex-wrap: nowrap;margin-left: 10rpx;height: 34rpx;position: absolute;right: 0;bottom: 30rpx;
}.item .box .icon {width: 34rpx;height: 34rpx;display: flex;align-items: center;justify-content: center;
}.item .box .icon image {width: 34rpx;height: 34rpx;
}.item .box input {width: 60rpx;height: 34rpx;border: none;color: #333;text-align: center;font-size: 26rpx;
}
.container .index-cart {width: 100%;height: 100rpx;display: flex;align-items: center;justify-content: flex-start;position: relative;z-index: 3;
}
.container .index-cart .left {width: 470rpx;height: 100%;color: rgba(51, 51, 51, 1);display: flex;align-items: center;justify-content: flex-start;background: #fff;border-top: 1rpx solid rgba(230, 230, 230, 1);
}
.container .index-cart .left .cart-num {width: 100rpx;height: 100rpx;position: relative;padding-top: 15rpx;box-sizing: border-box;border-radius: 100%;left: 30rpx;text-align: center;
}
.container .index-cart .left .cart-num.on {/* background: #ffa800; */
}
.container .index-cart .left .cart-num image {width: 69rpx;height: 69rpx;
}
.container .index-cart .left .cart-num text {font-size: 20rpx;color: #fff;display: inline-block;padding: 0 8rpx;box-sizing: border-box;position: absolute;right: 13rpx;top: 11rpx;height: 30rpx;line-height: 30rpx;border-radius: 30rpx;background: #f00;
}
.container .index-cart .left .cart-money {color: rgba(51, 51, 51, 1);font-size: 30rpx;margin-left: 30rpx;
}
.cart-money .mon{height: 50rpx;font-size: 36rpx;line-height: 50rpx;color: #333333;
}
.cart-money .lable{height: 28rpx;line-height: 28rpx;font-size: 28rpx;color: #333333;
}
.container .index-cart .order-btn {width: 282rpx;height: 100%;background: rgba(53, 212, 172, 1);font-size: 32rpx;color: #fff;display: flex;align-items: center;justify-content: center;
}
.hide{display: none;
}/* 店铺信息 */
.store-info{position: absolute;top: 26rpx;left: 30rpx;padding: 20rpx;width: 690rpx;height: 227rpx;border-radius: 16rpx;background: #fff;overflow: hidden;box-shadow: 0px 2rpx 16rpx rgba(0, 0, 0, 0.08);}
.store-info .start-box{margin: 10rpx 0 20rpx;
}
.store-info .name{ height: 50rpx;font-size: 36rpx; font-weight: bold;line-height: 50rpx;color: #333333;
}
.store-info  .tiem{ height: 30rpx;font-size: 22rpx; font-weight: 500;line-height: 30rpx;color: #333333;
}
.store-info .msg{  margin-top: 16rpx;
font-size: 22rpx; 
font-weight: 500;
line-height: 30rpx;
color: #999999; 
}.store-info .name .hot-tag{margin-right: 16rpx;display: inline-block;min-width: 60rpx;height: 32rpx;background: #FE4B26; border-radius: 6px; font-size: 20rpx;text-align: center;font-weight: 500;line-height: 32rpx;color: #FFFFFF;  
}.start-box{margin: 22rpx 0;height: 33rpx;line-height: 33rpx;font-size: 24rpx; font-weight: 500; color: #999999; 
}
.start-box .st-img{margin-right: 5rpx;width: 25rpx;height: 25rpx;
}.store-logo{width: 140rpx;height: 140rpx;
}
.tabs-box{position: absolute;bottom: 0;padding: 0 30rpx;width: 100%;height: 80rpx;border-bottom: 1px solid #E6E6E6;
}
.tabs-box .tabs-item{padding: 0 40rpx;height: 40rpx;font-size: 28rpx;font-weight: bold;line-height: 26px;line-height: 40rpx;color: rgba(153, 153, 153, 1);opacity: 1;
}
.tabs-box .active{color: #333;
}
.active::after{position: relative;bottom: -9rpx;margin: 0 auto;content: '';display: block;width: 40rpx;height: 8rpx;background: #49C0A2;border-radius: 200rpx;
}
.tabs-item .num{font-size: 20rpx;
}
.tabs-item:nth-child(1){padding: 0 40rpx 0 0;
}/* 评论页面 */
.comment-box{margin: 0 auto;width: 690rpx;
}
.comment-box .com-item{margin-top: 30rpx;
}
.con-content .start-box{margin: 10rpx 0 0;
}
.l-box .tit{height: 45rpx;font-size: 32rpx;font-weight: bold;line-height: 45rpx;color: #333333;
}
.con-content .r-box{
height: 33rpx;
font-size: 24rpx;
font-weight: 400;
line-height: 33rpx;
color: #999999;
}
.com-item .con-content{width: 580rpx;
}
.com-item .avatar{width: 80rpx;height: 80rpx;border-radius: 50%;
}
.com-item  .c-info{padding: 20rpx 0; font-size: 24rpx; font-weight: 500;line-height: 30rpx;color: #333333; 
}
.com-item .store-img-box{margin: 0rpx;padding: 0;width: 580rpx;height: 200rpx;overflow-y: hidden;overflow-x: scroll;
}
.com-item .img-scroll-box{height: 180rpx;
}
.com-item .store-img-box .store-img{width: 180rpx;height: 180rpx;
}
/* 商家详情页 */
.de-item{margin: 0 30rpx;padding: 30rpx 0;border-bottom: 1px solid #E6E6E6;
}
.de-item .l-icon,.de-item .r-icon{width: 40rpx;height: 40rpx; 
}
.de-item .a-icon{width: 48rpx!important;height: 48rpx!important; 
}
.de-item .text{ flex: 1;padding: 0 30rpx;font-size: 28rpx; font-weight: 500;line-height: 40rpx;color: #333333;
}
.de-item .line{margin: 0 40rpx;color: rgba(153, 153, 153, 1);
}
.store-img-box{width: 690rpx;height: 204rpx;
}
.img-scroll-box{width: auto;overflow-x: scroll;height: 144rpx;
}
.de-item .store-img{display: inline-block;margin-right: 20rpx;width: 188rpx;height: 144rpx;
}

goods.js 产品假数据

var goods=[{id: '111',  name: '商品类1', // 商品类型list: [ // 当前商品类型对应的所有商品{id: '010',title: '商品类型title11',pic: 'http://n.sinaimg.cn/translate/200/w1080h720/20180724/-_fe-hftenhz3076352.jpg',price: '1.55',detail: 'detail',num: 0 // num是为了我方便对商品加减操作,让后端加的},{id: '011',title: '商品类型title12',pic: 'http://n.sinaimg.cn/translate/200/w1080h720/20180724/-_fe-hftenhz3076352.jpg',price: '1.55',detail: 'detail',num: 0 // num是为了我方便对商品加减操作,让后端加的},{id: '012',title: '商品类型title13',pic: 'http://n.sinaimg.cn/translate/200/w1080h720/20180724/-_fe-hftenhz3076352.jpg',price: '1.55',detail: 'detail',num: 0 // num是为了我方便对商品加减操作,让后端加的}]},{id: '221',  name: '商类22', // 商品类型list: [ // 当前商品类型对应的所有商品{id: '021',title: '商品类型title22',pic: 'http://n.sinaimg.cn/translate/200/w1080h720/20180724/-_fe-hftenhz3076352.jpg',price: '1.55',detail: 'detail',num: 0 // num是为了我方便对商品加减操作,让后端加的},{id: '022',title: '商品类型title23',pic: 'http://n.sinaimg.cn/translate/200/w1080h720/20180724/-_fe-hftenhz3076352.jpg',price: '1.55',detail: 'detail',num: 0 // num是为了我方便对商品加减操作,让后端加的},{id: '023',title: '商品类型title24',pic: 'http://n.sinaimg.cn/translate/200/w1080h720/20180724/-_fe-hftenhz3076352.jpg',price: '1.55',detail: 'detail',num: 0 // num是为了我方便对商品加减操作,让后端加的}]},{id: '331',  name: '商品33', // 商品类型list: [ // 当前商品类型对应的所有商品{id: '031',title: '商品类型title31',pic: 'http://n.sinaimg.cn/translate/200/w1080h720/20180724/-_fe-hftenhz3076352.jpg',price: '1.55',detail: 'detail',num: 0 // num是为了我方便对商品加减操作,让后端加的},{id: '032',title: '商品类型title32',pic: 'http://n.sinaimg.cn/translate/200/w1080h720/20180724/-_fe-hftenhz3076352.jpg',price: '1.55',detail: 'detail',num: 0 // num是为了我方便对商品加减操作,让后端加的},{id: '033',title: '商品类型title33',pic: 'http://n.sinaimg.cn/translate/200/w1080h720/20180724/-_fe-hftenhz3076352.jpg',price: '1.55',detail: 'detail',num: 0 // num是为了我方便对商品加减操作,让后端加的}]},
]
exports.goods = goods;

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.rhkb.cn/news/34140.html

如若内容造成侵权/违法违规/事实不符,请联系长河编程网进行投诉反馈email:809451989@qq.com,一经查实,立即删除!

相关文章

网上订餐管理系统

网上订餐系统的主要功能是在线点餐&#xff0c;除此之外还有比如充值&#xff0c;菜谱管理&#xff0c;退餐&#xff0c;查看历史订单等等众多相关服务。在撰写论文的过程中&#xff0c;将结合理论实际&#xff0c;理清相关理论知识&#xff0c;同时与系统配合以解释实际应用和…

在线订餐管理系统

1、项目介绍 在线订餐管理系统拥有两种角色 管理员&#xff1a;菜品管理、类别管理、用户管理、订单管理、评价用户、留言管理等 用户&#xff1a;登录注册、点餐、购物车、历史订餐、留言 2、项目技术 后端框架&#xff1a; Servlet、mvc模式 前端技术&#xff1a;jsp、…

ChatGPT爆火?团餐行业如何实现智慧升级

最近&#xff0c;《流浪地球2》热映&#xff0c;影片科技感爆棚&#xff0c;画面感震撼&#xff0c;电影中的一些高科技智能设备也令人赞叹&#xff0c;空间站的云霄电梯可以直通空间站&#xff0c;酷炫的“外骨骼机器人能够辅助工程&#xff0c;智能电子狗“笨笨”能干又可爱&…

瑞吉外卖 - 后台系统退出功能(4)

某马瑞吉外卖单体架构项目完整开发文档&#xff0c;基于 Spring Boot 2.7.11 JDK 11。预计 5 月 20 日前更新完成&#xff0c;有需要的胖友记得一键三连&#xff0c;关注主页 “瑞吉外卖” 专栏获取最新文章。 相关资料&#xff1a;https://pan.baidu.com/s/1rO1Vytcp67mcw-PD…

外卖订餐——吃货联盟订餐系统

通过一段时间的学习&#xff0c;也到了检验成果的时候了&#xff0c;下面通过实战提升对技能点的运用能力、积累项目经验。 “吃货联盟定餐系统”需求说明 现今已进入网络时代&#xff0c;网上购物、看新闻、交友等人们的日常生活已离不开网络。“只 要点点手指&#xff0c;就…

基于android 订餐外卖APP,前台后台服务都齐全

基于android开发的订餐外卖APP 一 项目介绍 该项目是基于android开发的订餐外卖app&#xff0c;前台和后台管理都有&#xff0c;内容很多&#xff0c;非常值得学习&#xff0c;二次开发&#xff0c;设计指导性项目。 二 软件技术说明 软件架构说明 项目技术&#xff1a; …

瑞吉外卖-后台系统功能

目录 前言后台系统登录功能需求分析代码实现实体类Mapper层Service层Controller层 总结 后台系统退出功能需求分析代码实现总结 后台登录优化需求分析代码实现方法一&#xff1a;过滤器方法二&#xff1a;拦截器 总结 前言 所有的命名要符合开发规范&#xff0c;本项目中不再解…

【瑞吉外卖】day09:用户地址簿功能、菜品展示、购物车、下单

目录 1. 用户地址簿功能 1.1 需求分析 1.2 数据模型 1.3 导入功能代码 1.4 功能测试 2. 菜品展示 2.1 需求分析 2.2 前端页面分析 2.3 代码开发 2.4 功能测试 3. 购物车 3.1 需求分析 3.2 数据模型 3.3 前端页面分析 3.4 准备工作 3.5 代码开发 3.6 功能测试 …

外卖管理系统(一)

内容 软件开发整体介绍 瑞吉外卖项目介绍 开发环境搭建 后台登录功能开发 后台退出功能开发 1. 软件开发整体介绍 作为一名软件开发工程师,我们需要了解在软件开发过程中的开发流程&#xff0c; 以及软件开发过程中涉及到的岗位角色&#xff0c;角色的分工、职责&#x…

外卖订餐管理系统

需求分析 项目概述 外卖订餐系统分成前台订餐管理子系统、店家信息管理子系统和后台管理子系统这三个子系统。用户通过此平台可以浏览菜品、查询菜品、查询店家&#xff0c;注册登录后可以提交订单、查询订单、管理个人信息等&#xff1b;商家通过此平台注册登录后可以接单、…

基于android的外卖在线订餐系统app

本外卖订餐系统是一个Android 客户端JSP Servlet服务端应用程序&#xff0c;启动Android上的应用程序后可以登录、查看菜品等,再者学校学生人数的增加&#xff0c;学生对餐饮服务的要求更加高&#xff1b;许多学生不满足于学校食堂的餐饮或嫌学校食堂就餐排队时间长&#xff0c…

瑞吉外卖订单后台和用户端功能

项目场景&#xff1a; 在编写瑞吉外卖的订单功能的时候&#xff0c;还是按照惯例&#xff0c;订单的一些功能是我们自己做&#xff0c;毕竟都看了一百多集视频了&#xff0c;自己应该能写一点东西了。 遇到的坑&#xff1a; 后台的订单列表功能&#xff0c;有一个输入订单号查询…

瑞吉外卖 —— 2、后台登录和登出

目录 1、后台登录功能 1.1、接口分析 1.1.2、登录校验逻辑 1.2、代码 1.2.1、统一的返回结果实体类 1.2.2、controller 方法 1.3、测试 2、后台退出功能 2.1、分析 2.2、代码 3、未登录访问首页跳转到登录页面 3.1、分析 3.2、代码 1、后台登录功能 1.1、接口分析…

外卖点餐APP-02(后台--员工管理)

&#xff08;一&#xff09;登录 实现思路&#xff1a; 接收到用户登录输入的用户名和密码&#xff0c;封装到了emp对象中对密码进行MD5加密创建条件构造器添加sql查询判断条件&#xff0c;emp对象中的Username等于Employee数据表中的Username调用MyBatis-Plus的方法查询数据库…

瑞吉外卖-移动端菜品展示功能,购物车添加菜品及修改等功能,用户下单功能及历史订单派送功能

整理记录下学习整个瑞吉外卖项目&#xff0c;详细代码可在我的Gitee仓库瑞吉外卖实战克隆下载学习使用&#xff01; 12.菜品展示 12.1 需求分析 12.2 更改前台页面使其正常显示 由于购物车功能还未进行开发&#xff0c;所以修改main.js中的cartListJson函数中访问固定数据&a…

外卖点餐APP-04(后台--菜品管理)

&#xff08;一&#xff09;新增 controller层思路&#xff1a; 调用service处理响应处理结果 PostMapping public R<String> save(RequestBody DishDto dishDto){dishService.saveWithFlavors(dishDto);return R.success("新增成功&#xff01;"); } servi…

瑞吉外卖:后台系统登录和退出功能

文章目录 需求分析代码开发创建实体类导入返回结果类Rcontroller、service与mapperlogin.html防止非法访问 需求分析 点击登录按钮后&#xff0c;浏览器以POST方式向employee/login提交username和password&#xff0c;服务器经过处理后向浏览器返回某种格式的数据&#xff0c;…

服装销售数据分析

目录&#xff1a; 一、项目背景介绍 二、数据源 三、分析流程 四、分析框架 五、知识点总结 一、项目背景介绍&#xff1a; 某服装经销商经营多个女装品牌&#xff0c;每个品牌设有线下店铺。该公司老板及销售总监需在每日营业结束后查看当日销售数据。以往主要由业务员手动整…

创建报价单或销售凭证,提示无定价确定过程能被确定,消息号V1212

创建报价单&#xff0c;提示无定价确定过程能被确定&#xff0c;消息号V1212。 解决方案&#xff1a; spro 》销售和分销——》基本功能——》定价——》定价控制——》定价并分配定价过程 1&#xff09;将凭证定价程序分配给订单类型 2&#xff09;设置定价程序确定&#xff0…

ChatGPT工作提效之layedit上传多附件的解决方案(layedit赋值、layui.js底层修改、追加模式多附件上传)

ChatGPT工作提效系列文章目录 ChatGPT工作提效之初探路径独孤九剑遇强则强ChatGPT工作提效之在程序开发中的巧劲和指令(创建MySQL语句、PHP语句、Javascript用法、python的交互)ChatGPT工作提效之生成开发需求和报价单并转为Excel格式ChatGPT工作提效之小鹅通二次开发批量API对…