liyongli 1 ay önce
ebeveyn
işleme
883b3d4c41
1 değiştirilmiş dosya ile 32 ekleme ve 27 silme
  1. 32 27
      src/view/fenghui/index.vue

+ 32 - 27
src/view/fenghui/index.vue

@@ -43,9 +43,9 @@
                     <!-- <h4 class="title" v-text="lang[langType].basicInformation"></h4> -->
                     <h4 class="text" v-text="lang[langType].signUp"></h4>
                     <!-- 国家 -->
-                    <van-field input-align="right" size="large" v-model="from.countryOrRegion" is-link readonly
-                        :placeholder="lang[langType].countryOrRegionContent" @click="showCountryOrRegion = true"
-                        required>
+                    <van-field input-align="right" size="large" v-model="from.countryOrRegion" clickable
+                        right-icon="location-o" readonly :placeholder="lang[langType].countryOrRegionContent"
+                        @click="showCountryOrRegion = true" required>
                         <template #label>
                             <span class="label" v-html="lang[langType].countryOrRegion"></span>
                         </template>
@@ -120,15 +120,15 @@
                     <!-- 生日 -->
                     <van-field input-align="right" size="large"
                         :rules="[{ required: true, trigger: 'onBlur', message: lang[langType].birthdayContent }]"
-                        is-link readonly @click="showBirthday = true" v-model="from.birthday" required
-                        :placeholder="lang[langType].birthdayContent">
+                        clickable right-icon="calendar-o" readonly @click="showBirthday = true" v-model="from.birthday"
+                        required :placeholder="lang[langType].birthdayContent">
                         <template #label>
                             <span class="label" v-html="lang[langType].birthday"></span>
                         </template>
                     </van-field>
                     <van-popup v-model:show="showBirthday" destroy-on-close round position="bottom">
                         <van-date-picker @confirm="packerConfirm" :title="lang[langType].birthday"
-                            @cancal="showBirthday = false" :min-date="new Date(1970, 0, 1)" :max-date="new Date()" />
+                            @cancel="showBirthday = false" :min-date="new Date(1970, 0, 1)" :max-date="new Date()" />
                     </van-popup>
 
                     <!-- 照片 -->
@@ -139,8 +139,9 @@
                             <span class="label" v-html="lang[langType].photo"></span>
                         </template>
                         <template #input>
-                            <van-uploader :preview-full-image="false" accept="image/*" v-model="photo" :before-delete="beforeDelete" :max-count="1"
-                                :max-size="524288000" @oversize="filesize" :after-read="beforeRead" result-type="file">
+                            <van-uploader :preview-full-image="false" accept="image/*" v-model="photo"
+                                :before-delete="beforeDelete" :max-count="1" :max-size="524288000" @oversize="filesize"
+                                :after-read="beforeRead" result-type="file">
                             </van-uploader>
                             <p style="font-size: 12px;" v-text="lang[langType].photoSubContent"> </p>
                         </template>
@@ -183,8 +184,9 @@
                     </van-field>
 
                     <!-- 证件类型 -->
-                    <van-field input-align="right" size="large" v-model="from.cardTypeName" is-link readonly
-                        :placeholder="lang[langType].conferenceTypeContent" @click="showCardType = true" required>
+                    <van-field input-align="right" size="large" v-model="from.cardTypeName" clickable
+                        right-icon="calendar-o" readonly :placeholder="lang[langType].conferenceTypeContent"
+                        @click="showCardType = true" required>
                         <template #label>
                             <span class="label" v-html="lang[langType].conferenceType"></span>
                         </template>
@@ -297,7 +299,8 @@
                     </van-field>
 
                     <!--  抵达西安时间 -->
-                    <van-field input-align="right" size="large" v-model="from.reachTime" is-link readonly @click="showReachTime = true"
+                    <van-field input-align="right" size="large" v-model="from.reachTime" clickable
+                        right-icon="calendar-o" readonly @click="showReachTime = true"
                         :placeholder="lang[langType].reachTimeContent">
                         <template #label>
                             <span class="label" v-html="lang[langType].reachTime"></span>
@@ -305,7 +308,7 @@
                     </van-field>
                     <van-popup v-model:show="showReachTime" destroy-on-close round position="bottom">
                         <van-picker :title="lang[langType].reachTime" :columns="dateTimeColumns"
-                            @confirm="reachTimeConfirm" @calcan="showReachTime = false" />
+                            @confirm="reachTimeConfirm" @cancel="showReachTime = false" />
                     </van-popup>
 
                     <!--  离开车次 -->
@@ -317,7 +320,8 @@
                     </van-field>
 
                     <!--  离开时间 -->
-                    <van-field input-align="right" size="large" v-model="from.leavingTime" is-link readonly @click="showLeavingTime = true"
+                    <van-field input-align="right" size="large" v-model="from.leavingTime" clickable
+                        right-icon="calendar-o" readonly @click="showLeavingTime = true"
                         :placeholder="lang[langType].leavingTimeContent">
                         <template #label>
                             <span class="label" v-html="lang[langType].leavingTime"></span>
@@ -325,19 +329,20 @@
                     </van-field>
                     <van-popup v-model:show="showLeavingTime" destroy-on-close round position="bottom">
                         <van-picker :title="lang[langType].leavingTime" :columns="dateTimeColumns"
-                            @confirm="leavingTimeConfirm" @calcan="showLeavingTime = false" />
+                            @confirm="leavingTimeConfirm" @cancel="showLeavingTime = false" />
                     </van-popup>
 
                     <!--  离店时间 -->
-                    <van-field input-align="right" size="large" v-model="from.checkOutTime" is-link readonly
-                        @click="showCheckOutTime = true" :placeholder="lang[langType].checkOutTimeContent">
+                    <van-field input-align="right" size="large" v-model="from.checkOutTime" clickable
+                        right-icon="calendar-o" readonly @click="showCheckOutTime = true"
+                        :placeholder="lang[langType].checkOutTimeContent">
                         <template #label>
                             <span class="label" v-html="lang[langType].checkOutTime"></span>
                         </template>
                     </van-field>
                     <van-popup v-model:show="showCheckOutTime" destroy-on-close round position="bottom">
                         <van-picker :title="lang[langType].checkOutTime" :columns="dateTimeColumns"
-                            @confirm="checkOutTimeConfirm" @calcan="showCheckOutTime = false" />
+                            @confirm="checkOutTimeConfirm" @cancel="showCheckOutTime = false" />
                     </van-popup>
 
                     <!-- <br /> -->
@@ -377,20 +382,20 @@ let arrivalTime = []
 const dateTimeColumns = computed(() => {
     const now = new Date();
     const dateList = lang.value[langType.value].dateList;
-    const years = Array.from({ length: Number(now.getFullYear()) + 1 - 1970 }, (_, i) => {
+    const years = [{ text: dateList[0], value: '', disabled: true }, ...Array.from({ length: Number(now.getFullYear()) + 1 - 1970 }, (_, i) => {
         const t = 1970 + i + ''
         return {
             text: t,
             value: t
         }
-    }).reverse().shift({ text: dateList[0], value: '', disabled: true  });
-    const months = Array.from({ length: 12 }, (_, i) => {
+    }).reverse()];
+    const months = [{ text: dateList[1], value: '', disabled: true }, ...Array.from({ length: 12 }, (_, i) => {
         const m = (i + 1).toString().padStart(2, '0')
         return {
             text: m,
             value: m
         }
-    }).shift({ text: dateList[1], value: '', disabled: true  });
+    })];
 
     // 动态计算当前选中年月对应的天数
     const daysInMonth = new Date(
@@ -398,28 +403,28 @@ const dateTimeColumns = computed(() => {
         parseInt(arrivalTime[1] || '0'),
         0
     ).getDate();
-    const days = Array.from({ length: daysInMonth }, (_, i) => {
+    const days = [{ text: dateList[2], value: '', disabled: true }, ...Array.from({ length: daysInMonth }, (_, i) => {
         const d = (i + 1).toString().padStart(2, '0')
         return {
             text: d,
             value: d
         }
-    }).shift({ text: dateList[2], value: '', disabled: true  });
+    })];
 
-    const hours = Array.from({ length: 24 }, (_, i) => {
+    const hours = [{ text: dateList[3], value: '', disabled: true }, ...Array.from({ length: 24 }, (_, i) => {
         const h = i.toString().padStart(2, '0')
         return {
             text: h,
             value: h
         }
-    }).shift({ text: dateList[3], value: '', disabled: true  });
-    const minutes = Array.from({ length: 60 }, (_, i) => {
+    })];
+    const minutes = [{ text: dateList[4], value: '', disabled: true }, ...Array.from({ length: 60 }, (_, i) => {
         const m = i.toString().padStart(2, '0')
         return {
             text: m,
             value: m
         }
-    }).shift({ text: dateList[4], value: '', disabled: true  });
+    })];
     return [years, months, days, hours, minutes];
 });
 /** const langObj = [