代客下单新增限时折扣角标
This commit is contained in:
@@ -7,14 +7,14 @@ VITE_APP_BASE_API=/dev-api
|
|||||||
# 接口地址
|
# 接口地址
|
||||||
|
|
||||||
# VITE_APP_API_URL=https://tapi.cashier.sxczgkj.cn/ # 测试
|
# VITE_APP_API_URL=https://tapi.cashier.sxczgkj.cn/ # 测试
|
||||||
# VITE_APP_API_URL=https://cashier.sxczgkj.com/ # 正式
|
VITE_APP_API_URL=https://cashier.sxczgkj.com/ # 正式
|
||||||
VITE_APP_API_URL=http://192.168.1.42/ # 本地
|
# VITE_APP_API_URL=http://192.168.1.42/ # 本地
|
||||||
|
|
||||||
|
|
||||||
# WebSocket 端点(不配置则关闭),线上 ws://api.youlai.tech/ws ,本地 ws://localhost:8989/ws
|
# WebSocket 端点(不配置则关闭),线上 ws://api.youlai.tech/ws ,本地 ws://localhost:8989/ws
|
||||||
# VITE_APP_WS_ENDPOINT=wss://sockets.sxczgkj.com/wss
|
# VITE_APP_WS_ENDPOINT=wss://sockets.sxczgkj.com/wss
|
||||||
# VITE_APP_WS_ENDPOINT=wss://czgeatws.sxczgkj.com/wss # 正式
|
VITE_APP_WS_ENDPOINT=wss://czgeatws.sxczgkj.com/wss # 正式
|
||||||
VITE_APP_WS_ENDPOINT=ws://192.168.1.42:2348 # 本地
|
# VITE_APP_WS_ENDPOINT=ws://192.168.1.42:2348 # 本地
|
||||||
|
|
||||||
|
|
||||||
# 启用 Mock 服务
|
# 启用 Mock 服务
|
||||||
|
|||||||
@@ -44,11 +44,11 @@ const Api = {
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
// 获取店铺订单支付URL
|
// 获取店铺订单支付URL
|
||||||
orderPayUrl(params: any) {
|
orderPayUrl(data: any) {
|
||||||
return request<any>({
|
return request<any>({
|
||||||
url: `${baseURL}/shopPayApi/orderPayUrl`,
|
url: `${baseURL}/shopPayApi/orderPayUrl`,
|
||||||
method: "get",
|
method: "post",
|
||||||
params
|
data
|
||||||
});
|
});
|
||||||
},
|
},
|
||||||
//挂账支付
|
//挂账支付
|
||||||
|
|||||||
@@ -80,7 +80,8 @@ export const useCartsStore = defineStore("carts", () => {
|
|||||||
: undefined,
|
: undefined,
|
||||||
skuData,
|
skuData,
|
||||||
is_time_discount: item.isTimeDiscount,
|
is_time_discount: item.isTimeDiscount,
|
||||||
isTimeDiscount: item.isTimeDiscount
|
isTimeDiscount: item.isTimeDiscount,
|
||||||
|
salePrice: item.limitDiscountPrice
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -311,7 +312,7 @@ export const useCartsStore = defineStore("carts", () => {
|
|||||||
userPoints: userPoints.value,
|
userPoints: userPoints.value,
|
||||||
isMember: useVipPrice.value,
|
isMember: useVipPrice.value,
|
||||||
memberDiscountRate: shopUser.userInfo.memberDiscountRate || 1,
|
memberDiscountRate: shopUser.userInfo.memberDiscountRate || 1,
|
||||||
fullReductionActivities: fullReductionActivities.value,
|
fullReductionActivities: [fullReductionActivities.value],
|
||||||
currentDinnerType: dinnerType.value,
|
currentDinnerType: dinnerType.value,
|
||||||
limitTimeDiscount: limitDiscountRes.value,
|
limitTimeDiscount: limitDiscountRes.value,
|
||||||
shopUserInfo: shopUser.userInfo,
|
shopUserInfo: shopUser.userInfo,
|
||||||
@@ -915,7 +916,8 @@ export const useCartsStore = defineStore("carts", () => {
|
|||||||
coupons,
|
coupons,
|
||||||
setCoupons,
|
setCoupons,
|
||||||
payParamsInit,
|
payParamsInit,
|
||||||
limitDiscountRes
|
limitDiscountRes,
|
||||||
|
getAllGoodsList
|
||||||
};
|
};
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
@@ -75,6 +75,7 @@ const accountList = reactive([
|
|||||||
{ username: "19107220837", type: 'danger', label: '快乐时光店铺' },
|
{ username: "19107220837", type: 'danger', label: '快乐时光店铺' },
|
||||||
{ username: "18199991111", type: 'success', label: '草莓加盟主店可直接管理' },
|
{ username: "18199991111", type: 'success', label: '草莓加盟主店可直接管理' },
|
||||||
{ username: "18821670757", type: 'primary', label: '强盛集团' },
|
{ username: "18821670757", type: 'primary', label: '强盛集团' },
|
||||||
|
{ username: "19107220837", type: 'warning', label: '万维时光' },
|
||||||
]);
|
]);
|
||||||
|
|
||||||
// 快捷模拟登录
|
// 快捷模拟登录
|
||||||
|
|||||||
@@ -152,6 +152,7 @@
|
|||||||
<el-form-item label="会员折扣" required>
|
<el-form-item label="会员折扣" required>
|
||||||
<el-input-number v-model="level.discount" :style="inputStyle" :step="1" step-strictly :min="1"
|
<el-input-number v-model="level.discount" :style="inputStyle" :step="1" step-strictly :min="1"
|
||||||
:max="100" type="number" placeholder="请输入会员折扣" />
|
:max="100" type="number" placeholder="请输入会员折扣" />
|
||||||
|
<span style="margin-left: 4px;color: #666;">%</span>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="等级标识">
|
<el-form-item label="等级标识">
|
||||||
<div>
|
<div>
|
||||||
|
|||||||
@@ -2,6 +2,7 @@ import DeptAPI from "@/api/product/specificationsconfig";
|
|||||||
import UserAPI from "@/api/onlineShop/goodsGroupconfig";
|
import UserAPI from "@/api/onlineShop/goodsGroupconfig";
|
||||||
|
|
||||||
import type { ISearchConfig } from "@/components/CURD/types";
|
import type { ISearchConfig } from "@/components/CURD/types";
|
||||||
|
import { getCategoryList } from '@/api/coupon'
|
||||||
|
|
||||||
const searchConfig: ISearchConfig = {
|
const searchConfig: ISearchConfig = {
|
||||||
pageName: "sys:user",
|
pageName: "sys:user",
|
||||||
@@ -31,10 +32,9 @@ const searchConfig: ISearchConfig = {
|
|||||||
},
|
},
|
||||||
options: [],
|
options: [],
|
||||||
async initFn(formItem) {
|
async initFn(formItem) {
|
||||||
formItem.options = await UserAPI.getList();
|
formItem.options = await getCategoryList();
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|
||||||
],
|
],
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@@ -213,7 +213,7 @@
|
|||||||
<el-form-item label="库存开关">
|
<el-form-item label="库存开关">
|
||||||
<div style="display: block;">
|
<div style="display: block;">
|
||||||
<el-switch v-model="ruleForm.isStock" :active-value="1" :inactive-value="0" :disabled="isSyncStatus()" />
|
<el-switch v-model="ruleForm.isStock" :active-value="1" :inactive-value="0" :disabled="isSyncStatus()" />
|
||||||
<div style="color: #999;">注:关闭则不计算出入库数据</div>
|
<div style="color: #999;">注:关闭则不计算出库数据</div>
|
||||||
</div>
|
</div>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="设为推荐" prop="delivery">
|
<el-form-item label="设为推荐" prop="delivery">
|
||||||
|
|||||||
@@ -37,7 +37,7 @@
|
|||||||
<single-image-upload style="width: 80px; height: 80px" v-model="form.shopQrcode"></single-image-upload>
|
<single-image-upload style="width: 80px; height: 80px" v-model="form.shopQrcode"></single-image-upload>
|
||||||
</div>
|
</div>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="店铺小程序码">
|
<!-- <el-form-item label="店铺小程序码">
|
||||||
<div class="img_box">
|
<div class="img_box">
|
||||||
<el-image :src="form.smallQrcode || img_download_error" fit="contain"
|
<el-image :src="form.smallQrcode || img_download_error" fit="contain"
|
||||||
style="width: 80px; height: 80px"></el-image>
|
style="width: 80px; height: 80px"></el-image>
|
||||||
@@ -45,7 +45,7 @@
|
|||||||
下载
|
下载
|
||||||
</el-button>
|
</el-button>
|
||||||
</div>
|
</div>
|
||||||
</el-form-item>
|
</el-form-item> -->
|
||||||
<el-form-item label="经营模式「单选」">
|
<el-form-item label="经营模式「单选」">
|
||||||
<el-radio-group v-model="form.registerType">
|
<el-radio-group v-model="form.registerType">
|
||||||
<el-radio value="before">快餐版(先支付后下单)</el-radio>
|
<el-radio value="before">快餐版(先支付后下单)</el-radio>
|
||||||
|
|||||||
@@ -27,6 +27,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="flex u-col-top">
|
<div class="flex u-col-top">
|
||||||
<div class="img">
|
<div class="img">
|
||||||
|
<div class="xszk" v-if="item.isLimitDiscount || item.is_time_discount">限时折扣</div>
|
||||||
<div class="isSeatFee img u-line-1 u-flex u-col-center u-row-center" v-if="isSeatFee">
|
<div class="isSeatFee img u-line-1 u-flex u-col-center u-row-center" v-if="isSeatFee">
|
||||||
<span>{{ item.name }}</span>
|
<span>{{ item.name }}</span>
|
||||||
</div>
|
</div>
|
||||||
@@ -461,6 +462,17 @@ onMounted(() => {
|
|||||||
position: relative;
|
position: relative;
|
||||||
margin-right: 10px;
|
margin-right: 10px;
|
||||||
|
|
||||||
|
.xszk {
|
||||||
|
padding: 2px 4px 2px 6px;
|
||||||
|
background-color: var(--el-color-danger);
|
||||||
|
position: absolute;
|
||||||
|
top: 0;
|
||||||
|
right: 0;
|
||||||
|
z-index: 10;
|
||||||
|
color: #fff;
|
||||||
|
font-size: 8px;
|
||||||
|
}
|
||||||
|
|
||||||
img {
|
img {
|
||||||
width: 59px;
|
width: 59px;
|
||||||
height: 59px;
|
height: 59px;
|
||||||
|
|||||||
@@ -4,38 +4,22 @@
|
|||||||
<template v-if="carts.list && carts.list.length >= 1">
|
<template v-if="carts.list && carts.list.length >= 1">
|
||||||
<!-- 当前购物车 -->
|
<!-- 当前购物车 -->
|
||||||
<div v-for="(item, index) in carts.list" :key="index">
|
<div v-for="(item, index) in carts.list" :key="index">
|
||||||
<carts-item
|
<carts-item :item="item" :useVipPrice="carts.useVipPrice" @changeNumber="changeNumber"
|
||||||
:item="item"
|
:selCart="carts.selCart" @itemClick="itemClick(item)" @editNote="editNote"></carts-item>
|
||||||
:useVipPrice="carts.useVipPrice"
|
|
||||||
@changeNumber="changeNumber"
|
|
||||||
:selCart="carts.selCart"
|
|
||||||
@itemClick="itemClick(item)"
|
|
||||||
@editNote="editNote"
|
|
||||||
></carts-item>
|
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
<!-- 赠菜 -->
|
<!-- 赠菜 -->
|
||||||
<div class="cart-title" v-if="carts.giftList.length > 0"><span>以下是优惠菜品</span></div>
|
<div class="cart-title" v-if="carts.giftList.length > 0"><span>以下是优惠菜品</span></div>
|
||||||
<div v-for="(item, index) in carts.giftList" :key="index">
|
<div v-for="(item, index) in carts.giftList" :key="index">
|
||||||
<carts-item
|
<carts-item :item="item" @changeNumber="changeNumber" :useVipPrice="carts.useVipPrice" :selCart="carts.selCart"
|
||||||
:item="item"
|
@itemClick="itemClick(item)" @editNote="editNote"></carts-item>
|
||||||
@changeNumber="changeNumber"
|
|
||||||
:useVipPrice="carts.useVipPrice"
|
|
||||||
:selCart="carts.selCart"
|
|
||||||
@itemClick="itemClick(item)"
|
|
||||||
@editNote="editNote"
|
|
||||||
></carts-item>
|
|
||||||
</div>
|
</div>
|
||||||
<el-empty :image-size="60" v-if="carts.isEmpty" description="点餐列表为空" />
|
<el-empty :image-size="60" v-if="carts.isEmpty" description="点餐列表为空" />
|
||||||
<!-- 打包费 -->
|
<!-- 打包费 -->
|
||||||
<template v-if="carts.packNum > 0">
|
<template v-if="carts.packNum > 0">
|
||||||
<div class="cart-title"><span>打包费</span></div>
|
<div class="cart-title"><span>打包费</span></div>
|
||||||
<extra-fee
|
<extra-fee name="打包费" :number="carts.packNum" :price="carts.orderCostSummary.packFee"></extra-fee>
|
||||||
name="打包费"
|
|
||||||
:number="carts.packNum"
|
|
||||||
:price="carts.orderCostSummary.packFee"
|
|
||||||
></extra-fee>
|
|
||||||
</template>
|
</template>
|
||||||
<!-- 餐位费 -->
|
<!-- 餐位费 -->
|
||||||
<template v-if="perpole >= 1 && carts.dinnerType == 'dine-in'">
|
<template v-if="perpole >= 1 && carts.dinnerType == 'dine-in'">
|
||||||
@@ -56,17 +40,9 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div v-for="(detaiItem, index) in item" :key="index">
|
<div v-for="(detaiItem, index) in item" :key="index">
|
||||||
<carts-item
|
<carts-item :useVipPrice="carts.useVipPrice" :canChangeNumber="false" isOld :dinerType="dinerType"
|
||||||
:useVipPrice="carts.useVipPrice"
|
:item="detaiItem" @changeNumber="changeNumber" :selCart="carts.selCart" @itemClick="itemClick(detaiItem)"
|
||||||
:canChangeNumber="false"
|
@editNote="editNote"></carts-item>
|
||||||
isOld
|
|
||||||
:dinerType="dinerType"
|
|
||||||
:item="detaiItem"
|
|
||||||
@changeNumber="changeNumber"
|
|
||||||
:selCart="carts.selCart"
|
|
||||||
@itemClick="itemClick(detaiItem)"
|
|
||||||
@editNote="editNote"
|
|
||||||
></carts-item>
|
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@@ -74,14 +50,9 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="bottom">
|
<div class="bottom">
|
||||||
<div class="u-flex u-row-right">
|
<div class="u-flex u-row-right">
|
||||||
<el-tooltip
|
<el-tooltip placement="top" effect="light" popper-class="youhui-tips" :popper-options="{
|
||||||
placement="top"
|
'background-color': '#fff',
|
||||||
effect="light"
|
}">
|
||||||
popper-class="youhui-tips"
|
|
||||||
:popper-options="{
|
|
||||||
'background-color': '#fff',
|
|
||||||
}"
|
|
||||||
>
|
|
||||||
<template #content>
|
<template #content>
|
||||||
<div class="u-flex color-000 u-font-14 u-row-between">
|
<div class="u-flex color-000 u-font-14 u-row-between">
|
||||||
<span class="font-bold">会员优惠</span>
|
<span class="font-bold">会员优惠</span>
|
||||||
@@ -110,58 +81,39 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="btn-group" v-if="isXianFuKuan">
|
<div class="btn-group" v-if="isXianFuKuan">
|
||||||
<el-button
|
<el-button type="primary" size="large" :disabled="!carts.isLinkFinshed" @click="createOrder('wx-aiplay')">
|
||||||
type="primary"
|
|
||||||
size="large"
|
|
||||||
:disabled="!carts.isLinkFinshed"
|
|
||||||
@click="createOrder('wx-aiplay')"
|
|
||||||
>
|
|
||||||
微信/支付宝
|
微信/支付宝
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button type="primary" size="large" :disabled="!carts.isLinkFinshed" @click="createOrder('cash')">
|
||||||
type="primary"
|
|
||||||
size="large"
|
|
||||||
:disabled="!carts.isLinkFinshed"
|
|
||||||
@click="createOrder('cash')"
|
|
||||||
>
|
|
||||||
现金
|
现金
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button type="primary" size="large" :disabled="disabledMorePay" @click="createOrder('more-pay')">
|
||||||
type="primary"
|
|
||||||
size="large"
|
|
||||||
:disabled="disabledMorePay"
|
|
||||||
@click="createOrder('more-pay')"
|
|
||||||
>
|
|
||||||
更多支付
|
更多支付
|
||||||
</el-button>
|
</el-button>
|
||||||
</div>
|
</div>
|
||||||
<div class="btn-group" v-else>
|
<div class="btn-group" v-else>
|
||||||
<template v-if="!showOrder">
|
<template v-if="!showOrder">
|
||||||
<el-button
|
<!-- <el-button type="primary" size="large" :disabled="!carts.isLinkFinshed || carts.isEmpty"
|
||||||
type="primary"
|
@click="createOrder('only-create')">
|
||||||
size="large"
|
|
||||||
:disabled="!carts.isLinkFinshed || carts.isEmpty"
|
|
||||||
@click="createOrder('only-create')"
|
|
||||||
>
|
|
||||||
仅下单
|
仅下单
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button
|
<el-button type="primary" size="large" :disabled="disabledMorePay" @click="createOrder('to-pay')">
|
||||||
type="primary"
|
去结账
|
||||||
size="large"
|
</el-button> -->
|
||||||
:disabled="disabledMorePay"
|
<el-button type="primary" size="large"
|
||||||
@click="createOrder('to-pay')"
|
:disabled="carts.list.length == 0 || carts.oldOrder.detailMap.length == 0"
|
||||||
>
|
@click="createOrder('only-create')">
|
||||||
|
仅下单
|
||||||
|
</el-button>
|
||||||
|
<el-button type="primary" size="large"
|
||||||
|
:disabled="carts.list.length == 0 && isEmptyObject(carts.oldOrder.detailMap)"
|
||||||
|
@click="createOrder('to-pay')">
|
||||||
去结账
|
去结账
|
||||||
</el-button>
|
</el-button>
|
||||||
</template>
|
</template>
|
||||||
<template v-else>
|
<template v-else>
|
||||||
<el-button type="default" size="large" @click="hideOrder()">加菜/返回</el-button>
|
<el-button type="default" size="large" @click="hideOrder()">加菜/返回</el-button>
|
||||||
<el-button
|
<el-button type="primary" size="large" :disabled="!carts.isLinkFinshed" @click="createOrder('to-pay')">
|
||||||
type="primary"
|
|
||||||
size="large"
|
|
||||||
:disabled="!carts.isLinkFinshed"
|
|
||||||
@click="createOrder('to-pay')"
|
|
||||||
>
|
|
||||||
立即支付
|
立即支付
|
||||||
</el-button>
|
</el-button>
|
||||||
</template>
|
</template>
|
||||||
@@ -177,6 +129,19 @@ import { customTruncateToTwoDecimals } from "@/views/tool/Instead/util";
|
|||||||
import { useCartsStore } from "@/store/modules/carts";
|
import { useCartsStore } from "@/store/modules/carts";
|
||||||
import { useUserStore } from "@/store/modules/user";
|
import { useUserStore } from "@/store/modules/user";
|
||||||
|
|
||||||
|
function isEmptyObject(obj) {
|
||||||
|
// 步骤1:排除null和非对象类型
|
||||||
|
if (obj === null || typeof obj !== 'object') {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
// 步骤2:排除数组(数组也是对象,需单独判断)
|
||||||
|
if (Array.isArray(obj)) {
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
// 步骤3:判断自身可枚举属性是否为空
|
||||||
|
return Object.keys(obj).length === 0;
|
||||||
|
}
|
||||||
|
|
||||||
const shopUser = useUserStore();
|
const shopUser = useUserStore();
|
||||||
const carts = useCartsStore();
|
const carts = useCartsStore();
|
||||||
|
|
||||||
@@ -288,18 +253,22 @@ defineExpose({
|
|||||||
height: 100%;
|
height: 100%;
|
||||||
overflow: hidden;
|
overflow: hidden;
|
||||||
}
|
}
|
||||||
|
|
||||||
.totalNumber {
|
.totalNumber {
|
||||||
color: #666;
|
color: #666;
|
||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.totalPrice {
|
.totalPrice {
|
||||||
font-size: 18px;
|
font-size: 18px;
|
||||||
color: #000;
|
color: #000;
|
||||||
}
|
}
|
||||||
|
|
||||||
.bottom {
|
.bottom {
|
||||||
position: relative;
|
position: relative;
|
||||||
padding-top: 14px;
|
padding-top: 14px;
|
||||||
border-top: 1px solid #ebebeb;
|
border-top: 1px solid #ebebeb;
|
||||||
|
|
||||||
.yiyouhui {
|
.yiyouhui {
|
||||||
text-align: right;
|
text-align: right;
|
||||||
color: #c12a2a;
|
color: #c12a2a;
|
||||||
@@ -308,13 +277,16 @@ defineExpose({
|
|||||||
top: 14px;
|
top: 14px;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
:deep(.btn-group) {
|
:deep(.btn-group) {
|
||||||
display: flex;
|
display: flex;
|
||||||
margin-top: 10px;
|
margin-top: 10px;
|
||||||
|
|
||||||
.el-button {
|
.el-button {
|
||||||
flex: 1;
|
flex: 1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.carts {
|
.carts {
|
||||||
height: calc(100% - 120px);
|
height: calc(100% - 120px);
|
||||||
overflow-y: scroll;
|
overflow-y: scroll;
|
||||||
@@ -324,18 +296,21 @@ defineExpose({
|
|||||||
|
|
||||||
/* 修改垂直滚动条 */
|
/* 修改垂直滚动条 */
|
||||||
.carts::-webkit-scrollbar {
|
.carts::-webkit-scrollbar {
|
||||||
width: 0; /* 修改宽度 */
|
width: 0;
|
||||||
|
/* 修改宽度 */
|
||||||
}
|
}
|
||||||
|
|
||||||
/* 修改滚动条轨道背景色 */
|
/* 修改滚动条轨道背景色 */
|
||||||
.carts::-webkit-scrollbar-track {
|
.carts::-webkit-scrollbar-track {
|
||||||
background-color: #f1f1f1;
|
background-color: #f1f1f1;
|
||||||
}
|
}
|
||||||
|
|
||||||
.cart-title {
|
.cart-title {
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
color: rgba(0, 0, 0, 0.4);
|
color: rgba(0, 0, 0, 0.4);
|
||||||
|
|
||||||
&::after {
|
&::after {
|
||||||
content: "";
|
content: "";
|
||||||
flex: 1;
|
flex: 1;
|
||||||
|
|||||||
@@ -22,10 +22,7 @@
|
|||||||
<el-table-column label="用户" prop="headImg" width="200px">
|
<el-table-column label="用户" prop="headImg" width="200px">
|
||||||
<template v-slot="scope">
|
<template v-slot="scope">
|
||||||
<div class="user_info">
|
<div class="user_info">
|
||||||
<el-image
|
<el-image :src="scope.row.headImg" style="width: 40px; height: 40px; flex-shrink: 0">
|
||||||
:src="scope.row.headImg"
|
|
||||||
style="width: 40px; height: 40px; flex-shrink: 0"
|
|
||||||
>
|
|
||||||
<template #error>
|
<template #error>
|
||||||
<div class="image-slot">
|
<div class="image-slot">
|
||||||
<i class="el-icon-user"></i>
|
<i class="el-icon-user"></i>
|
||||||
@@ -33,6 +30,7 @@
|
|||||||
</template>
|
</template>
|
||||||
</el-image>
|
</el-image>
|
||||||
<span class="name">{{ scope.row.nickName }}</span>
|
<span class="name">{{ scope.row.nickName }}</span>
|
||||||
|
<el-tag disable-transitions type="primary" style="margin-left: 10px;" v-if="scope.row.new">新</el-tag>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
@@ -44,9 +42,16 @@
|
|||||||
<span v-else>否</span>
|
<span v-else>否</span>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="余额" prop="amount"></el-table-column>
|
<el-table-column label="余额" prop="amount">
|
||||||
<el-table-column label="积分" prop="accountPoints"></el-table-column>
|
<template #default="scope">
|
||||||
|
{{ multiplyAndFormat(scope.row.amount || 0) }}
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
|
<el-table-column label="积分" prop="accountPoints">
|
||||||
|
<template #default="scope">
|
||||||
|
{{ scope.row.accountPoints || 0 }}
|
||||||
|
</template>
|
||||||
|
</el-table-column>
|
||||||
<el-table-column label="操作" width="90" fixed="right">
|
<el-table-column label="操作" width="90" fixed="right">
|
||||||
<template v-slot="scope">
|
<template v-slot="scope">
|
||||||
<el-button type="primary" size="small" @click="choose(scope.row)">选择</el-button>
|
<el-button type="primary" size="small" @click="choose(scope.row)">选择</el-button>
|
||||||
@@ -55,14 +60,9 @@
|
|||||||
</el-table>
|
</el-table>
|
||||||
</div>
|
</div>
|
||||||
<div class="head-container">
|
<div class="head-container">
|
||||||
<el-pagination
|
<el-pagination :total="tableData.total" :current-page="tableData.page" :page-size="tableData.size"
|
||||||
:total="tableData.total"
|
@size-change="sizeChange" @current-change="paginationChange"
|
||||||
:current-page="tableData.page"
|
layout="total, sizes, prev, pager, next, jumper"></el-pagination>
|
||||||
:page-size="tableData.size"
|
|
||||||
@size-change="sizeChange"
|
|
||||||
@current-change="paginationChange"
|
|
||||||
layout="total, sizes, prev, pager, next, jumper"
|
|
||||||
></el-pagination>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</el-dialog>
|
</el-dialog>
|
||||||
@@ -71,6 +71,7 @@
|
|||||||
<script setup>
|
<script setup>
|
||||||
import shopUserApi from "@/api/account/shopUser";
|
import shopUserApi from "@/api/account/shopUser";
|
||||||
import dayjs from "dayjs";
|
import dayjs from "dayjs";
|
||||||
|
import { multiplyAndFormat } from '@/utils'
|
||||||
let cacheData = {};
|
let cacheData = {};
|
||||||
|
|
||||||
const state = reactive({
|
const state = reactive({
|
||||||
|
|||||||
@@ -2,21 +2,19 @@
|
|||||||
<div class="controls">
|
<div class="controls">
|
||||||
<div class="input-number" :class="{ disabled: canEdit }">
|
<div class="input-number" :class="{ disabled: canEdit }">
|
||||||
<div class="reduce" @click="changeCartNumber(-1)">
|
<div class="reduce" @click="changeCartNumber(-1)">
|
||||||
<el-icon><Minus /></el-icon>
|
<el-icon>
|
||||||
|
<Minus />
|
||||||
|
</el-icon>
|
||||||
</div>
|
</div>
|
||||||
<span class="text" @click="changeCartNumberShow()">{{ carts.selCart.number || 1 }}</span>
|
<span class="text" @click="changeCartNumberShow()">{{ carts.selCart.number || 1 }}</span>
|
||||||
<div class="add" @click="changeCartNumber(1)">
|
<div class="add" @click="changeCartNumber(1)">
|
||||||
<el-icon><Plus /></el-icon>
|
<el-icon>
|
||||||
|
<Plus />
|
||||||
|
</el-icon>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<el-button v-for="(item, index) in controls" :key="index" size="large" :disabled="btnDisabled(item)"
|
||||||
<el-button
|
@click="controlsClick(item)">
|
||||||
v-for="(item, index) in controls"
|
|
||||||
:key="index"
|
|
||||||
size="large"
|
|
||||||
:disabled="btnDisabled(item)"
|
|
||||||
@click="controlsClick(item)"
|
|
||||||
>
|
|
||||||
{{ returnLabel(item) }}
|
{{ returnLabel(item) }}
|
||||||
</el-button>
|
</el-button>
|
||||||
</div>
|
</div>
|
||||||
@@ -39,7 +37,7 @@ const controls = ref([
|
|||||||
{ label: "整单备注", key: "all-note", disabled: false, per: "all-note" },
|
{ label: "整单备注", key: "all-note", disabled: false, per: "all-note" },
|
||||||
{ label: "退菜", key: "return", disabled: false, per: "return" },
|
{ label: "退菜", key: "return", disabled: false, per: "return" },
|
||||||
{ label: "免厨打", key: "is_print", disabled: false, per: "print" },
|
{ label: "免厨打", key: "is_print", disabled: false, per: "print" },
|
||||||
{ label: "单品改价", key: "changePriceClick", disabled: false, per: "cart" },
|
{ label: "单品改价", key: "changePriceClick", disabled: false, per: "changePriceClick" },
|
||||||
{ label: "等叫", key: "is_wait_call", disabled: false, per: "cart" },
|
{ label: "等叫", key: "is_wait_call", disabled: false, per: "cart" },
|
||||||
// { label: "整单等叫", key: "", disabled: false, per: "all-wating" },
|
// { label: "整单等叫", key: "", disabled: false, per: "all-wating" },
|
||||||
]);
|
]);
|
||||||
@@ -59,6 +57,10 @@ function changeCartNumberShow() {
|
|||||||
emits("changeCartNumberShow");
|
emits("changeCartNumberShow");
|
||||||
}
|
}
|
||||||
function controlsClick(item) {
|
function controlsClick(item) {
|
||||||
|
// console.log(item);
|
||||||
|
// const originGoodsItem = carts.goods.find(val => val.id == carts.selCart.product_id)
|
||||||
|
// console.log('originGoodsItem===', originGoodsItem);
|
||||||
|
|
||||||
switch (item.key) {
|
switch (item.key) {
|
||||||
case "is_gift":
|
case "is_gift":
|
||||||
carts.updateTag("is_gift", carts.selCart.is_gift ? 0 : 1);
|
carts.updateTag("is_gift", carts.selCart.is_gift ? 0 : 1);
|
||||||
@@ -108,12 +110,13 @@ function controlsClick(item) {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
const perList = computed(() => {
|
const perList = computed(() => {
|
||||||
|
const originGoodsItem = carts.goods.find(val => val.id == carts.selCart.product_id)
|
||||||
// if (!carts.oldOrder.id) {
|
// if (!carts.oldOrder.id) {
|
||||||
// return ["all-wating", "all-note", "rottable"];
|
// return ["all-wating", "all-note", "rottable"];
|
||||||
// }
|
// }
|
||||||
let arr = [];
|
let arr = [];
|
||||||
if (!carts.selCart.id) {
|
if (!carts.selCart.id) {
|
||||||
arr = ["all-wating", "all-note"];
|
arr = ["all-wating"];
|
||||||
}
|
}
|
||||||
if (carts.isCanSelectGroup) {
|
if (carts.isCanSelectGroup) {
|
||||||
arr = ["all-wating", "all-note", "del", "pack", "gift", "print", "one-note"];
|
arr = ["all-wating", "all-note", "del", "pack", "gift", "print", "one-note"];
|
||||||
@@ -128,9 +131,16 @@ const perList = computed(() => {
|
|||||||
if (carts.oldOrder.id) {
|
if (carts.oldOrder.id) {
|
||||||
arr.push("rottable");
|
arr.push("rottable");
|
||||||
}
|
}
|
||||||
|
if (originGoodsItem && originGoodsItem.id) {
|
||||||
|
if (originGoodsItem.isAllowTempModifyPrice == 1 || carts.selCart.is_temporary) {
|
||||||
|
arr.push('changePriceClick');
|
||||||
|
}
|
||||||
|
}
|
||||||
// if (!carts.isEmpty) {
|
// if (!carts.isEmpty) {
|
||||||
// arr.push("saveCart");
|
// arr.push("saveCart");
|
||||||
// }
|
// }
|
||||||
|
console.log('carts.selCart===', carts.selCart);
|
||||||
|
console.log('perList=======', arr);
|
||||||
return arr;
|
return arr;
|
||||||
});
|
});
|
||||||
const canEdit = computed(() => {
|
const canEdit = computed(() => {
|
||||||
@@ -139,6 +149,9 @@ const canEdit = computed(() => {
|
|||||||
|
|
||||||
function btnDisabled(item) {
|
function btnDisabled(item) {
|
||||||
const canClick = perList.value.includes(item.per);
|
const canClick = perList.value.includes(item.per);
|
||||||
|
|
||||||
|
console.log('canClick===', canClick);
|
||||||
|
|
||||||
if (item.key == "return") {
|
if (item.key == "return") {
|
||||||
return !canClick || carts.selCart.returnNum >= carts.selCart.number;
|
return !canClick || carts.selCart.returnNum >= carts.selCart.number;
|
||||||
} else {
|
} else {
|
||||||
@@ -169,6 +182,7 @@ function changeCartNumber(step) {
|
|||||||
|
|
||||||
<style scoped lang="scss">
|
<style scoped lang="scss">
|
||||||
$gap: 10px;
|
$gap: 10px;
|
||||||
|
|
||||||
.controls {
|
.controls {
|
||||||
display: flex;
|
display: flex;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
@@ -177,10 +191,12 @@ $gap: 10px;
|
|||||||
padding: 14px 10px;
|
padding: 14px 10px;
|
||||||
background-color: #f7f7fa;
|
background-color: #f7f7fa;
|
||||||
}
|
}
|
||||||
.el-button + .el-button {
|
|
||||||
|
.el-button+.el-button {
|
||||||
margin-top: $gap;
|
margin-top: $gap;
|
||||||
margin-left: 0;
|
margin-left: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.input-number {
|
.input-number {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
@@ -188,6 +204,7 @@ $gap: 10px;
|
|||||||
border: 1px solid #dcdfe6;
|
border: 1px solid #dcdfe6;
|
||||||
margin-bottom: $gap;
|
margin-bottom: $gap;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
|
|
||||||
.reduce,
|
.reduce,
|
||||||
.text,
|
.text,
|
||||||
.add {
|
.add {
|
||||||
@@ -196,17 +213,19 @@ $gap: 10px;
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
height: 38px;
|
height: 38px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.text {
|
.text {
|
||||||
height: 48px;
|
height: 48px;
|
||||||
font-size: 30px;
|
font-size: 30px;
|
||||||
border-top: 1px solid #dcdfe6;
|
border-top: 1px solid #dcdfe6;
|
||||||
border-bottom: 1px solid #dcdfe6;
|
border-bottom: 1px solid #dcdfe6;
|
||||||
}
|
}
|
||||||
.reduce {
|
|
||||||
}
|
.reduce {}
|
||||||
.add {
|
|
||||||
}
|
.add {}
|
||||||
}
|
}
|
||||||
|
|
||||||
.disabled {
|
.disabled {
|
||||||
cursor: not-allowed;
|
cursor: not-allowed;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -3,15 +3,18 @@
|
|||||||
<el-image v-if="item.coverImg" class="goods-image"
|
<el-image v-if="item.coverImg" class="goods-image"
|
||||||
:src="item.coverImg + '?x-oss-process=image/resize,m_lfit,w_100,h_100'" fit="cover"></el-image>
|
:src="item.coverImg + '?x-oss-process=image/resize,m_lfit,w_100,h_100'" fit="cover"></el-image>
|
||||||
<div class="info" @click="itemClick">
|
<div class="info" @click="itemClick">
|
||||||
<div class="name u-flex u-flex-wrap">
|
<div class="dot" v-if="item.isLimitDiscount">限时折扣</div>
|
||||||
<span class="weight" v-if="item.type == 'weight'">称重</span>
|
<div class="btm">
|
||||||
<span class="u-line-3">{{ item.name }}</span>
|
<div class="name u-flex u-flex-wrap">
|
||||||
|
<span class="weight" v-if="item.type == 'weight'">称重</span>
|
||||||
|
<span class="u-line-3">{{ item.name }}</span>
|
||||||
|
</div>
|
||||||
|
<div class="limit_wrap" v-if="item.isLimitDiscount">
|
||||||
|
<span class="o_price">¥{{ item.lowPrice }}</span>
|
||||||
|
<span class="sale_price">¥{{ item.limitDiscountPrice }}</span>
|
||||||
|
</div>
|
||||||
|
<div v-else>¥{{ item.lowPrice }}</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="" v-if="item.isLimitDiscount">
|
|
||||||
<span class="o_price">¥{{ item.lowPrice }}</span>
|
|
||||||
<span>¥{{ item.limitDiscountPrice }}</span>
|
|
||||||
</div>
|
|
||||||
<div v-else>¥{{ item.lowPrice }}</div>
|
|
||||||
</div>
|
</div>
|
||||||
<div class="status" v-if="
|
<div class="status" v-if="
|
||||||
item.isSoldStock ||
|
item.isSoldStock ||
|
||||||
@@ -97,20 +100,42 @@ function isProductAvailable(sellDaysStr, startTimeStr, endTimeStr) {
|
|||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
background-color: rgba(46, 46, 46, 0.38);
|
// background-color: rgba(46, 46, 46, 0.3);
|
||||||
z-index: 1;
|
z-index: 1;
|
||||||
|
|
||||||
|
.btm {
|
||||||
|
width: 100%;
|
||||||
|
padding: 20px 6px 0;
|
||||||
|
position: absolute;
|
||||||
|
bottom: 0;
|
||||||
|
left: 0;
|
||||||
|
z-index: 2;
|
||||||
|
background: linear-gradient(to bottom, rgba(0, 0, 0, 0), rgba(0, 0, 0, 0.6));
|
||||||
|
}
|
||||||
|
|
||||||
|
.dot {
|
||||||
|
padding: 2px 4px 2px 6px;
|
||||||
|
border-radius: 0 0 0 8px;
|
||||||
|
font-size: 10px;
|
||||||
|
background-color: var(--el-color-danger);
|
||||||
|
display: flex;
|
||||||
|
justify-content: center;
|
||||||
|
position: absolute;
|
||||||
|
top: 0;
|
||||||
|
right: -0;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.status {
|
.status {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
box-sizing: border-box;
|
box-sizing: border-box;
|
||||||
padding: 8px;
|
padding: 8px;
|
||||||
z-index: 2;
|
z-index: 99;
|
||||||
inset: 0;
|
inset: 0;
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
background-color: rgba($color: #000000, $alpha: 0.5);
|
background-color: rgba($color: #000000, $alpha: 0.6);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -129,9 +154,20 @@ function isProductAvailable(sellDaysStr, startTimeStr, endTimeStr) {
|
|||||||
margin-right: 2px;
|
margin-right: 2px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.o_price {
|
.limit_wrap {
|
||||||
font-size: 10px;
|
display: flex;
|
||||||
text-decoration: line-through;
|
|
||||||
opacity: .8;
|
.o_price {
|
||||||
|
font-size: 12px;
|
||||||
|
text-decoration: line-through;
|
||||||
|
opacity: .8;
|
||||||
|
margin-right: 4px;
|
||||||
|
position: relative;
|
||||||
|
top: 2px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.sale_price {
|
||||||
|
font-size: 14px;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
@@ -129,10 +129,10 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="right">
|
<div class="right">
|
||||||
<h3>账单明细</h3>
|
<h3>账单明细</h3>
|
||||||
<p class="u-font-12 u-m-b-20">
|
<!-- <p class="u-font-12 u-m-b-20">
|
||||||
<span class="color-red">*</span>
|
<span class="color-red">*</span>
|
||||||
<span class="color-red">餐位费和打包费不参与折扣和满减</span>
|
<span class="color-red">餐位费和打包费不参与折扣和满减</span>
|
||||||
</p>
|
</p> -->
|
||||||
<div class="order-info">
|
<div class="order-info">
|
||||||
<div class="u-flex u-m-b-10 u-row-between">
|
<div class="u-flex u-m-b-10 u-row-between">
|
||||||
<span class="title">订单号:</span>
|
<span class="title">订单号:</span>
|
||||||
@@ -162,6 +162,12 @@
|
|||||||
-¥{{ carts.orderCostSummary.fullReduction.actualAmount }}
|
-¥{{ carts.orderCostSummary.fullReduction.actualAmount }}
|
||||||
</span>
|
</span>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="u-flex u-m-b-10 u-row-between">
|
||||||
|
<span class="title">新客立减</span>
|
||||||
|
<span class="u-m-l-10 value">
|
||||||
|
-¥{{ carts.orderCostSummary.newUserDiscount }}
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
<div class="u-flex u-m-b-10 u-row-between">
|
<div class="u-flex u-m-b-10 u-row-between">
|
||||||
<span class="title">商品优惠券</span>
|
<span class="title">商品优惠券</span>
|
||||||
<span class="u-m-l-10 value">-¥{{ productCouponDiscountAmount }}</span>
|
<span class="u-m-l-10 value">-¥{{ productCouponDiscountAmount }}</span>
|
||||||
@@ -509,6 +515,8 @@ function returnPayParams() {
|
|||||||
roundAmount: props.orderInfo.roundAmount,
|
roundAmount: props.orderInfo.roundAmount,
|
||||||
pointsDiscountAmount: carts.orderCostSummary.pointDeductionAmount, //积分抵扣金额
|
pointsDiscountAmount: carts.orderCostSummary.pointDeductionAmount, //积分抵扣金额
|
||||||
pointsNum: carts.orderCostSummary.pointUsed,
|
pointsNum: carts.orderCostSummary.pointUsed,
|
||||||
|
discountActAmount: carts.orderCostSummary.fullReduction.actualAmount, // 满减活动金额
|
||||||
|
discountActId: carts.orderCostSummary.fullReduction.usedThreshold !== undefined ? carts.orderCostSummary.fullReduction.usedThreshold.activityId : '', // 满减活动id
|
||||||
couponList: carts.coupons.map((v) => v.id),
|
couponList: carts.coupons.map((v) => v.id),
|
||||||
userId: props.user.userId || "",
|
userId: props.user.userId || "",
|
||||||
allPack: carts.dinnerType == "take-out" ? 1 : 0,
|
allPack: carts.dinnerType == "take-out" ? 1 : 0,
|
||||||
|
|||||||
@@ -401,22 +401,26 @@ async function createOrder(key) {
|
|||||||
|
|
||||||
// 清空历史订单回调
|
// 清空历史订单回调
|
||||||
async function clearOldOrderCallback() {
|
async function clearOldOrderCallback() {
|
||||||
// 获取历史订单数据
|
try {
|
||||||
const res = await orderApi.getHistoryList({
|
// 获取历史订单数据
|
||||||
orderId: carts.oldOrder.id,
|
const res = await orderApi.getHistoryList({
|
||||||
});
|
orderId: carts.oldOrder.id,
|
||||||
const noPayStatus = {
|
});
|
||||||
cancelled: "订单已取消",
|
const noPayStatus = {
|
||||||
done: "订单已关闭",
|
cancelled: "订单已取消",
|
||||||
};
|
done: "订单已关闭",
|
||||||
if (noPayStatus[res.status]) {
|
};
|
||||||
// ElMessage.error(noPayStatus[res.status]);
|
if (noPayStatus[res.status]) {
|
||||||
resetOldOrder();
|
// ElMessage.error(noPayStatus[res.status]);
|
||||||
showOrder.value = false;
|
resetOldOrder();
|
||||||
return;
|
showOrder.value = false;
|
||||||
}
|
return;
|
||||||
if (res) {
|
}
|
||||||
carts.setOldOrder(res);
|
if (res) {
|
||||||
|
carts.setOldOrder(res);
|
||||||
|
}
|
||||||
|
} catch (error) {
|
||||||
|
console.log(error);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// 取消历史订单
|
// 取消历史订单
|
||||||
|
|||||||
@@ -30,9 +30,9 @@
|
|||||||
<el-button type="primary" icon="download" @click="showDownloadTableCode">
|
<el-button type="primary" icon="download" @click="showDownloadTableCode">
|
||||||
下载桌台码
|
下载桌台码
|
||||||
</el-button>
|
</el-button>
|
||||||
<el-button type="primary" icon="download" @click="downloadShopCpde">
|
<!-- <el-button type="primary" icon="download" @click="downloadShopCpde">
|
||||||
下载店铺码
|
下载店铺码
|
||||||
</el-button>
|
</el-button> -->
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="u-flex u-p-b-15 u-font-14 u-m-t-16">
|
<div class="u-flex u-p-b-15 u-font-14 u-m-t-16">
|
||||||
|
|||||||
@@ -18,7 +18,7 @@ const modalConfig: IModalConfig<editRequest> = {
|
|||||||
},
|
},
|
||||||
beforeSubmit(data) {
|
beforeSubmit(data) {
|
||||||
console.log("提交之前处理", data);
|
console.log("提交之前处理", data);
|
||||||
data.birthDay = dayjs(data.birthDay).format("YYYY-MM-DD");
|
data.birthDay = data.birthDay ? dayjs(data.birthDay).format("YYYY-MM-DD") : '';
|
||||||
},
|
},
|
||||||
formItems: [
|
formItems: [
|
||||||
// {
|
// {
|
||||||
@@ -34,7 +34,7 @@ const modalConfig: IModalConfig<editRequest> = {
|
|||||||
{
|
{
|
||||||
label: "用户昵称",
|
label: "用户昵称",
|
||||||
prop: "nickName",
|
prop: "nickName",
|
||||||
rules: [{ required: false, message: "请输入用户昵称", trigger: "blur" }],
|
rules: [{ required: true, message: "请输入用户昵称", trigger: "blur" }],
|
||||||
type: "input",
|
type: "input",
|
||||||
attrs: {
|
attrs: {
|
||||||
placeholder: "请输入用户昵称",
|
placeholder: "请输入用户昵称",
|
||||||
@@ -68,7 +68,7 @@ const modalConfig: IModalConfig<editRequest> = {
|
|||||||
{
|
{
|
||||||
label: "会员生日",
|
label: "会员生日",
|
||||||
prop: "birthDay",
|
prop: "birthDay",
|
||||||
rules: [{ required: false, message: "请选择会员生日", trigger: "blur" }],
|
rules: [{ required: true, message: "请选择会员生日", trigger: "blur" }],
|
||||||
type: "date-picker",
|
type: "date-picker",
|
||||||
attrs: {
|
attrs: {
|
||||||
placeholder: "请选择会员生日",
|
placeholder: "请选择会员生日",
|
||||||
@@ -82,7 +82,7 @@ const modalConfig: IModalConfig<editRequest> = {
|
|||||||
type: "radio",
|
type: "radio",
|
||||||
label: "性别",
|
label: "性别",
|
||||||
prop: "sex",
|
prop: "sex",
|
||||||
rules: [{ required: false, message: "请选择性别", trigger: "blur" }],
|
rules: [{ required: true, message: "请选择性别", trigger: "blur" }],
|
||||||
attrs: {
|
attrs: {
|
||||||
placeholder: "请选择性别",
|
placeholder: "请选择性别",
|
||||||
},
|
},
|
||||||
|
|||||||
Reference in New Issue
Block a user