fixbug
This commit is contained in:
parent
64da26706f
commit
a3d1a5059d
@ -3,7 +3,7 @@
|
||||
<div class="page">
|
||||
<div style="margin-top: 350px;">
|
||||
|
||||
<van-field v-model="userName" clearable placeholder="请输入姓名" @input="preventSpace">
|
||||
<van-field v-model="userName" clearable placeholder="请输入姓名" >
|
||||
<template #label>
|
||||
<div style="color: #E5E5E5;">
|
||||
预约人姓名
|
||||
@ -89,7 +89,7 @@ import { getUserInfo, addMeal } from '@/api/login'
|
||||
const showPicker = ref(false)
|
||||
const currentDate = ref([])
|
||||
const currentTime = ref([])
|
||||
const minDate = ref(new Date(2025, 1, 24))
|
||||
const minDate = ref(new Date(2025, 0, 24))
|
||||
const maxDate = ref(new Date(2026, 11, 31))
|
||||
const showsuccess = ref(false)
|
||||
const showfail = ref(false)
|
||||
@ -133,7 +133,7 @@ const addYuyue = async () => {
|
||||
appointDate: appointDate.value,
|
||||
num: parseInt(num.value),
|
||||
remark: remark.value,
|
||||
userName: userName.value
|
||||
userName: userName.value.trim()
|
||||
})
|
||||
|
||||
if (res.status === 0) {
|
||||
@ -147,9 +147,7 @@ const addYuyue = async () => {
|
||||
showfail.value = true
|
||||
}
|
||||
}
|
||||
const preventSpace = (e) => {
|
||||
e.target.value = e.target.value.replace(/\s/g, '')
|
||||
}
|
||||
|
||||
|
||||
const route = useRoute()
|
||||
const router = useRouter()
|
||||
|
Loading…
Reference in New Issue
Block a user