限制预约客户候选列表高度
This commit is contained in:
@@ -26,11 +26,13 @@
|
|||||||
<div v-if="customerDropdownOpen" class="customer-dropdown">
|
<div v-if="customerDropdownOpen" class="customer-dropdown">
|
||||||
<div v-if="customerSearching" class="customer-muted">正在搜索客户...</div>
|
<div v-if="customerSearching" class="customer-muted">正在搜索客户...</div>
|
||||||
<template v-else>
|
<template v-else>
|
||||||
|
<div v-if="customerOptions.length > 0" class="customer-options-scroll">
|
||||||
<button v-for="customer in customerOptions" :key="String(customer.id)" class="customer-option" type="button" @click="selectCustomer(customer)">
|
<button v-for="customer in customerOptions" :key="String(customer.id)" class="customer-option" type="button" @click="selectCustomer(customer)">
|
||||||
<strong>{{ customer.nickname || customer.account || customer.phone || customer.contactPhone }}</strong>
|
<strong>{{ customer.nickname || customer.account || customer.phone || customer.contactPhone }}</strong>
|
||||||
<span>{{ customer.phone || customer.contactPhone || '未填写手机号' }}</span>
|
<span>{{ customer.phone || customer.contactPhone || '未填写手机号' }}</span>
|
||||||
</button>
|
</button>
|
||||||
<div v-if="customerOptions.length === 0" class="customer-muted">暂无匹配客户,可继续创建新客户</div>
|
</div>
|
||||||
|
<div v-else class="customer-muted">暂无匹配客户,可继续创建新客户</div>
|
||||||
</template>
|
</template>
|
||||||
<div class="customer-new">
|
<div class="customer-new">
|
||||||
<strong>新客户</strong>
|
<strong>新客户</strong>
|
||||||
@@ -684,7 +686,7 @@ watch(timeSheetVisible, syncAppointmentModalState)
|
|||||||
right: 0;
|
right: 0;
|
||||||
left: 0;
|
left: 0;
|
||||||
display: grid;
|
display: grid;
|
||||||
max-height: min(420px, 70vh);
|
max-height: min(520px, 70vh);
|
||||||
gap: 8px;
|
gap: 8px;
|
||||||
overflow-y: auto;
|
overflow-y: auto;
|
||||||
padding: 10px;
|
padding: 10px;
|
||||||
@@ -696,12 +698,22 @@ watch(timeSheetVisible, syncAppointmentModalState)
|
|||||||
-webkit-overflow-scrolling: touch;
|
-webkit-overflow-scrolling: touch;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.customer-options-scroll {
|
||||||
|
display: grid;
|
||||||
|
max-height: calc(44px * 5 + 8px * 4);
|
||||||
|
gap: 8px;
|
||||||
|
overflow-y: auto;
|
||||||
|
padding-right: 2px;
|
||||||
|
-webkit-overflow-scrolling: touch;
|
||||||
|
}
|
||||||
|
|
||||||
.customer-option {
|
.customer-option {
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
gap: 10px;
|
gap: 10px;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
min-height: 44px;
|
||||||
padding: 9px 10px;
|
padding: 9px 10px;
|
||||||
border-radius: 10px;
|
border-radius: 10px;
|
||||||
background: var(--subtle);
|
background: var(--subtle);
|
||||||
|
|||||||
Reference in New Issue
Block a user