代客下单修改

1.默认布局更改为图片文字布局
2.增加选择用户时点击用户或者选择都可选择用户
This commit is contained in:
YeMingfei666 2024-08-22 14:20:42 +08:00
parent dba71a0f11
commit a14a9877c2
2 changed files with 31 additions and 9 deletions

View File

@ -37,7 +37,7 @@
</div> --> </div> -->
<div class="head-container"> <div class="head-container">
<el-table :data="tableData.data" v-loading="tableData.loading"> <el-table :data="tableData.data" v-loading="tableData.loading" @cell-click="cellClick">
<el-table-column label="ID" prop="id"></el-table-column> <el-table-column label="ID" prop="id"></el-table-column>
<el-table-column label="用户" prop="headImg" width="200px"> <el-table-column label="用户" prop="headImg" width="200px">
<template v-slot="scope"> <template v-slot="scope">
@ -133,6 +133,11 @@ export default {
this.getShopInfo(); this.getShopInfo();
}, },
methods: { methods: {
cellClick(user){
console.log(user)
this.$emit("chooseUser",user)
this.close()
},
noChooseUser(){ noChooseUser(){
this.$emit("chooseUser",null) this.$emit("chooseUser",null)
this.close() this.close()

View File

@ -69,7 +69,11 @@
> >
<template v-else> <template v-else>
<div class="flex cur-pointer" @click="refChooseUserOpen"> <div class="flex cur-pointer" @click="refChooseUserOpen">
<img class="headimg" :src="vipUser.headImg" alt="" />
<img v-if="vipUser.headImg" class="headimg" :src="vipUser.headImg" alt="" />
<div v-else class="headimg flex flex-x-y-center">
<i-icon class="el-icon-user"></i-icon>
</div>
<div> <div>
<div class="ft-13 color-000">{{ vipUser.nickName }}</div> <div class="ft-13 color-000">{{ vipUser.nickName }}</div>
<div style="margin-top: 2px" class="color-666 ft-12"> <div style="margin-top: 2px" class="color-666 ft-12">
@ -524,7 +528,7 @@
<template v-else> <template v-else>
<div class="cashier_box goods_classify_list"> <div class="cashier_box goods_classify_list">
<div class="cashier_left"> <div class="cashier_left">
<div class="title">选择优惠</div> <!-- <div class="title">选择优惠</div> -->
<div class="detail_box"> <div class="detail_box">
<div class="usercard"> <div class="usercard">
<span <span
@ -565,12 +569,17 @@
</el-form> </el-form>
</div> --> </div> -->
</div> </div>
<div class="btn_group"> <!-- <div class="btn_group">
<el-button size="medium"> 整单打折/减免 </el-button> <el-button size="medium"> 整单打折/减免 </el-button>
<el-button size="medium "> 免单 </el-button> <el-button size="medium "> 免单 </el-button>
</div> </div> -->
<pay-type ref="refPayType" v-model="order.payType"> </pay-type> <pay-type ref="refPayType" v-model="order.payType"> </pay-type>
<div style="margin-top: 20px">
<el-button type="success" size="medium" @click="payOrder">
<span>立即支付</span>
</el-button>
</div>
<!-- <div class="flex row-right"> <!-- <div class="flex row-right">
<el-button size="medium" type="success" @click="payOrder" <el-button size="medium" type="success" @click="payOrder"
>确认支付</el-button >确认支付</el-button
@ -1073,7 +1082,7 @@ export default {
{ label: "图文显示", value: "img-and-text" }, { label: "图文显示", value: "img-and-text" },
{ label: "文字显示", value: "text" }, { label: "文字显示", value: "text" },
], ],
sel: "default", sel: "img-and-text",
}, },
// //
vipUser: { vipUser: {
@ -2247,7 +2256,7 @@ input[type="number"]::-webkit-outer-spin-button {
-webkit-appearance: none; -webkit-appearance: none;
margin: 0; margin: 0;
} }
::v-deep .el-button--success { ::v-deep .el-button--success:not(.is-disabled) {
background: #22bf64; background: #22bf64;
color: #fff; color: #fff;
} }
@ -2360,6 +2369,12 @@ input[type="number"]::-webkit-outer-spin-button {
.col-baseline { .col-baseline {
align-items: baseline; align-items: baseline;
} }
.flex-x-y-center{
display: flex;
justify-content: center;
align-items: center;
background-color: #efefef;
}
.absolute { .absolute {
position: absolute; position: absolute;
@ -2963,8 +2978,7 @@ input[type="number"]::-webkit-outer-spin-button {
min-width: 98px; min-width: 98px;
max-width: 100px; max-width: 100px;
height: 100px; height: 100px;
flex: 1; // flex: 1;
opacity: 1;
margin: 0 7px 14px; margin: 0 7px 14px;
border-radius: 4px; border-radius: 4px;
.timeSale { .timeSale {
@ -3057,7 +3071,10 @@ input[type="number"]::-webkit-outer-spin-button {
display: flex; display: flex;
flex-direction: column; flex-direction: column;
box-shadow: 0 4px 12px 0 rgba(0, 0, 0, 0.07); box-shadow: 0 4px 12px 0 rgba(0, 0, 0, 0.07);
.img-box{
width: 136px;
}
img { img {
width: 136px; width: 136px;
height: 125px; height: 125px;