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