Эх сурвалжийг харах

✨ 秒杀:已经接入

YunaiV 1 жил өмнө
parent
commit
39ccc983e0

+ 1 - 1
pages/goods/seckill.vue

@@ -199,7 +199,7 @@
     });
   }
 
-  // 分享信息
+  // 分享信息 TODO 芋艿:待接入
   const shareInfo = computed(() => {
     if (isEmpty(activity)) return {};
     return sheep.$platform.share.getShareInfo(

+ 4 - 2
pages/order/confirm.vue

@@ -209,7 +209,8 @@
       deliveryType: 1, // TODO 芋艿:需要支持【门店自提】
       pointStatus: false, // TODO 芋艿:需要支持【积分选择】
       combinationActivityId: state.orderPayload.combinationActivityId,
-      combinationHeadId: state.orderPayload.combinationHeadId
+      combinationHeadId: state.orderPayload.combinationHeadId,
+      seckillActivityId: state.orderPayload.seckillActivityId
     });
     if (code !== 0) {
       return;
@@ -234,7 +235,8 @@
       deliveryType: 1, // TODO 芋艿:需要支持【门店自提】
       pointStatus: false, // TODO 芋艿:需要支持【积分选择】
       combinationActivityId: state.orderPayload.combinationActivityId,
-      combinationHeadId: state.orderPayload.combinationHeadId
+      combinationHeadId: state.orderPayload.combinationHeadId,
+      seckillActivityId: state.orderPayload.seckillActivityId
     });
     if (code !== 0) {
       return;

+ 7 - 5
pages/user/goods-log.vue

@@ -1,3 +1,4 @@
+<!-- 商品浏览记录  -->
 <template>
   <s-layout title="我的足迹" :bgStyle="{ color: '#f2f2f2' }">
     <view class="cart-box ss-flex ss-flex-col ss-row-between">
@@ -150,11 +151,7 @@
 
     state.pagination.list = _.concat(state.pagination.list, data.list);
     state.pagination.total = data.total;
-    if (state.pagination.list.length < state.pagination.total) {
-      state.loadStatus = 'more';
-    } else {
-      state.loadStatus = 'noMore';
-    }
+    state.loadStatus = state.pagination.list.length < state.pagination.total ? 'more' : 'noMore';
   }
 
   // 单选选中
@@ -166,6 +163,7 @@
     }
     state.selectAll = state.selectedSpuIdList.length === state.pagination.list.length;
   };
+
   // 全选
   const onSelectAll = () => {
     state.selectAll = !state.selectAll;
@@ -180,6 +178,7 @@
       });
     }
   };
+
   // 删除足迹
   async function onDelete() {
     if (state.selectedSpuIdList.length <= 0) {
@@ -191,6 +190,7 @@
       reload();
     }
   }
+
   // 清空
   async function onClean() {
     const { code } = await SpuHistoryApi.cleanBrowseHistory();
@@ -214,9 +214,11 @@
       getList();
     }
   }
+
   onReachBottom(() => {
     loadMore();
   });
+
   onLoad(() => {
     getList();
   });

+ 0 - 7
sheep/api/product/history.js

@@ -23,13 +23,6 @@ const SpuHistoryApi = {
             method: 'GET',
             data
         });
-    },
-    // 获得商品浏览记录数量
-    getBrowseHistoryCount: () => {
-        return request({
-            url: '/app-api/product/browse-history/get-count',
-            method: 'GET',
-        });
     }
 };
 export default SpuHistoryApi;

+ 3 - 0
sheep/api/trade/order.js

@@ -19,6 +19,9 @@ const OrderApi = {
     if (!(data.combinationHeadId > 0)) {
       delete data2.combinationHeadId;
     }
+    if (!(data.seckillActivityId > 0)) {
+      delete data2.seckillActivityId;
+    }
     // 解决 SpringMVC 接受 List<Item> 参数的问题
     delete data2.items;
     for (let i = 0; i < data.items.length; i++) {