Przeglądaj źródła

feat(api): 添加订单类型定义

添加 advanceBookingTime 和 effectiveTime 字段到 API 类型定义中

BREAKING CHANGE: 新增字段可能影响现有 API 调用
zhangtao 4 dni temu
rodzic
commit
7ed25da2b5

+ 8 - 0
src/api/api.type.d.ts

@@ -828,6 +828,14 @@ namespace Api {
      * 核销时间
      */
     verificationTime?: string
+    /**
+     * 需提前预约天数
+     */
+    advanceBookingTime?: number
+    /**
+     * 有效时间
+     */
+    effectiveTime?: number
     [property: string]: any
   }
   interface ChargeOrderInfo {

+ 2 - 2
src/config/index.ts

@@ -8,10 +8,10 @@ const mapEnvVersion = {
   // develop: 'http://192.168.1.253:8080',
   // develop: 'http://192.168.0.19:8080',
   // develop: 'http://192.168.0.217:8080', // 黄
-  develop: 'http://192.168.1.89:8080', // 田
+  // develop: 'http://192.168.1.89:8080', // 田
   // develop: 'http://192.168.0.11:8080', // 王S
   // develop: 'http://74949mkfh190.vicp.fun', // 付
-  // develop: 'http://47.109.84.152:8081',
+  develop: 'http://47.109.84.152:8081',
   // develop: 'https://5ed0f7cc.r9.vip.cpolar.cn',
   // develop: 'https://smqjh.api.zswlgz.com',
   /**

+ 1 - 1
src/pages/index/index.vue

@@ -276,7 +276,7 @@ function handleChangeSwiper(e: UniHelper.SwiperOnChangeEvent) {
             </scroll-view>
           </view>
         </wd-skeleton>
-        <wd-loadmore :state="state" :loading-props="{ color: '#9ED605', size: 20 }" @reload="reload" />
+        <wd-loadmore v-if="goodsList.length > 9" :state="state" :loading-props="{ color: '#9ED605', size: 20 }" @reload="reload" />
         <wd-overlay :show="showoverlay" @click="showoverlay = false">
           <view class="mt-280rpx flex items-center justify-center">
             <view class="relative h-906rpx w-644rpx flex flex-col justify-center text-center" :style="{ backgroundImage: `url(${StaticUrl}/home-overlay-img.png)`, backgroundSize: 'cover', backgroundPosition: 'center' }">

+ 2 - 2
src/subPack-djk/commonTab/index.vue

@@ -49,9 +49,9 @@ function setTabbarItemActive(name: string) {
   <view class="page-xsb">
     <fl v-if="tabbarName == 'djk-fl'" />
     <order v-if="tabbarName == 'djk-order'" />
-    <home v-show="tabbarName == 'djk-home'" />
+    <home v-if="tabbarName == 'djk-home'" />
     <wd-tabbar
-      v-model="tabbarName" placeholder safe-area-inset-bottom fixed :bordered="false" custom-class="custom-tab"
+      v-model="tabbarName" safe-area-inset-bottom placeholder fixed :bordered="false" custom-class="custom-tab"
       :z-index="99999" @change="handleTabbarChange"
     >
       <wd-tabbar-item

+ 6 - 6
src/subPack-djk/orderDetaile/index.vue

@@ -68,13 +68,13 @@ async function handleAfterSale() {
 }
 function handleNav() {
   uni.openLocation({
-    latitude: Number(orderInfo.value?.djkOrderAttachInfo?.shopLat),
-    longitude: Number(orderInfo.value?.djkOrderAttachInfo?.shopLng),
+    latitude: Number(orderInfo.value?.shopInfo?.shopLat),
+    longitude: Number(orderInfo.value?.shopInfo?.shopLng),
   })
 }
 function handlePhone() {
   uni.makePhoneCall({
-    phoneNumber: String(orderInfo.value?.djkOrderAttachInfo?.tel),
+    phoneNumber: String(orderInfo.value?.shopInfo?.tel),
   })
 }
 </script>
@@ -84,7 +84,7 @@ function handlePhone() {
     v-if="orderInfo" class="page-xsb"
   >
     <wd-navbar
-      title="订单详情" :bordered="false" :z-index="99" safe-area-inset-top left-arrow placeholder fixed
+      title="订单详情" :bordered="false" :z-index="99" safe-area-inset-top placeholder left-arrow fixed
       @click-left="router.back()"
     />
     <view class="relative z-90 box-border bg-[#f6f6f6] px-24rpx">
@@ -169,7 +169,7 @@ function handlePhone() {
             {{ orderInfo.djkOrderAttachInfo?.goodsName }}
           </view>
           <view class="mt16rpx text-24rpx text-gray">
-            有效期360天·需提前1天预约
+            有效期{{ orderInfo.djkOrderAttachInfo?.effectiveTime }}天·需提前{{ orderInfo.djkOrderAttachInfo?.advanceBookingTime }}天预约
           </view>
           <view class="mt16rpx flex items-center justify-between">
             <view class="text-36rpx text-#FF4D3A font-semibold">
@@ -213,7 +213,7 @@ function handlePhone() {
       <view class="mt20rpx rounded-16rpx bg-white p24rpx">
         <view class="mt20rpx h160rpx flex items-center justify-between bg-cover bg-center px24rpx" :style="{ backgroundImage: `url(${StaticUrl}/djk-shop-nav-bg.png)` }">
           <view class="flex items-center">
-            {{ orderInfo.djkOrderAttachInfo?.shopAddress }}
+            {{ orderInfo.shopInfo?.shopName }}
           </view>
           <view class="flex items-center">
             <view class="mr40rpx flex flex-col items-center justify-center" @click="handleNav">

+ 1 - 0
src/subPack-djk/welfare/index.vue

@@ -45,6 +45,7 @@ async function handelSubmit() {
   }
   catch {
     uni.hideLoading()
+    show.value = false
     console.log('领取失败')
   }
 }