feat(pricing): introduce real-time budget estimator

This commit introduces a real-time budget estimator for event services. A new summary sidebar now displays a live,
itemized breakdown of costs as the user selects options in the order form.

Key changes include:
- A new `OrderSummary` component to display the price breakdown and total.
- Comprehensive pricing logic implemented in the `useEventOrder` composable.
- A responsive two-column layout on the main page to accommodate the summary.
- UI/UX improvements across the form, including clearer labels and subtle transition animations for conditional fields.
This commit is contained in:
xiaomai
2025-10-16 21:14:44 +08:00
parent eb69f6c48e
commit a5ac00baa1
12 changed files with 449 additions and 136 deletions

View File

@@ -1,23 +1,23 @@
<template>
<UCard>
<template #header>
<h2 class="text-xl font-bold">{{ secIdx }}. 您的活动信息</h2>
<h2 class="text-xl font-bold">{{ secIdx }}. 基本信息</h2>
<p class="text-muted text-sm">
您提供的联系方式与活动信息仅用于沟通与履约本工作室将妥善保护不会未经同意向第三方公开或出售
请留下联系方式与活动基础信息便于预算估算
</p>
</template>
<div class="grid gap-4">
<div class="grid grid-cols-1 sm:grid-cols-2 gap-4">
<UFormField name="contactName" label="联络人姓名" required>
<UFormField name="contactName" label="联系人" required>
<UInput v-model="orderState.contactName" class="w-full" />
</UFormField>
<UFormField name="contactNumber" label="联系方式(推荐 WhatsApp">
<UFormField name="contactNumber" label="联系电话(或 WhatsApp">
<div class="flex items-center gap-2">
<UCheckbox
v-model="orderState.isSameContact"
label="当前手机号码?"
label="同活动联系人"
class="whitespace-nowrap"
/>
<UInput
@@ -38,7 +38,7 @@
<UInput
v-model="orderState.eventName"
class="w-full"
placeholder="如果可能,请写上活动全名"
placeholder="例: ACME 集团 2025 年终晚会暨 50 周年庆典"
/>
</UFormField>