Explorar o código

史上腿费用

shish hai 7 meses
pai
achega
7ae496cb78

+ 1 - 11
mallApp/src/pages/goods/components/sel-popup.vue

@@ -90,17 +90,7 @@ export default {
         return false;
         return false;
       }
       }
       uni.setStorageSync("buyGoodsDetil", this.info);
       uni.setStorageSync("buyGoodsDetil", this.info);
-      this.$util.pageTo({
-        url: "/pages/order/buy",
-        query: {
-          hdId: this.hdId,
-          goodsId: this.info.id,
-          goodsNum: this.buyNum,
-          selIndex: this.selIndex,
-          account: this.account,
-        },
-        type: 2,
-      });
+      this.$util.pageTo({url: "/pages/order/buy?hdId="+this.hdId+'&goodsId='+this.info.id+'&goodsNum='+this.buyNum+'&selIndex='+this.selIndex+'&account='+this.account+'&freightType='+this.info.freightType,type: 2})
     },
     },
   },
   },
 };
 };

+ 3 - 6
mallApp/src/pages/goods/detail.vue

@@ -37,6 +37,9 @@
             <view class="preview-page">
             <view class="preview-page">
               <!-- 预览内容区域 -->
               <!-- 预览内容区域 -->
               <view class="preview-content">
               <view class="preview-content">
+                <view v-if="data.freightType == 0" style="color:red;padding-bottom:10upx;font-size:34upx;padding-left:24upx;background-color: white;width:100%;font-weight:bold;">
+                  本商品没有包配送,需要付跑腿费
+                </view>
                 <rich-media-viewer
                 <rich-media-viewer
                   ref="richMediaViewerGoods"
                   ref="richMediaViewerGoods"
                   :content="previewContent"
                   :content="previewContent"
@@ -347,13 +350,7 @@ export default {
         this.$msg("客户数据异常,请稍后再试");
         this.$msg("客户数据异常,请稍后再试");
         return;
         return;
       }
       }
-      // if(isNaN(parseInt(this.shopInfo.shopAdminId))){ // 无需 staffId
-      //   this.$msg("门店员工数据异常,请稍后再试");
-      //   return;
-      // }
       if (isNaN(parseInt(this.shopInfo.shopId))) {
       if (isNaN(parseInt(this.shopInfo.shopId))) {
-        console.log("---------- this.shopInfo: ", this.shopInfo)
-        console.error("门店数据异常,请稍后再试:", this.shopInfo.shopId)
         this.$msg("门店数据异常,请稍后再试");
         this.$msg("门店数据异常,请稍后再试");
         return;
         return;
       }
       }

+ 4 - 1
mallApp/src/pages/order/buy.vue

@@ -27,6 +27,7 @@
           ref="appDelivery"
           ref="appDelivery"
           @countFreight="countFreight" 
           @countFreight="countFreight" 
           :hasMap="hasMap"
           :hasMap="hasMap"
+          :freightType="freightType"
           :showDistance="showDistance"
           :showDistance="showDistance"
           :isFreight="isFreight"
           :isFreight="isFreight"
           :openIntraCity="openIntraCity"
           :openIntraCity="openIntraCity"
@@ -99,12 +100,14 @@ export default {
       deliveryPlatform: '', // 跑腿平台
       deliveryPlatform: '', // 跑腿平台
       deliveryPrice: 0, // 跑腿报价
       deliveryPrice: 0, // 跑腿报价
       deliveryDistance: 0, // 跑腿距离
       deliveryDistance: 0, // 跑腿距离
-      deliveryBracketContent: '' // 跑腿平台括号里的内容
+      deliveryBracketContent: '',// 跑腿平台括号里的内容
+      freightType:1
     };
     };
   },
   },
   onLoad(option) {
   onLoad(option) {
     this.option = option || {};
     this.option = option || {};
     this.init();
     this.init();
+    this.freightType = this.option.freightType?this.option.freightType:1
   },
   },
   computed: {
   computed: {
     /**
     /**

+ 6 - 2
mallApp/src/pages/order/components/app-delivery.vue

@@ -52,7 +52,7 @@
                   @click="selectDelivery(item, index)"
                   @click="selectDelivery(item, index)"
                 >
                 >
                   <view class="platform-name">{{ item.displayName || item.name }}</view>
                   <view class="platform-name">{{ item.displayName || item.name }}</view>
-                  <view class="platform-price">{{ item.priceText }}元</view>
+                  <view class="platform-price" v-if="freightType==0">{{ item.priceText }}元</view>
                   <view v-if="item.type" class="platform-type">{{ item.type }}</view>
                   <view v-if="item.type" class="platform-type">{{ item.type }}</view>
                 </view>
                 </view>
               </view>
               </view>
@@ -72,7 +72,7 @@
               <view class="tui-input">
               <view class="tui-input">
                 <text :class="isFreeDelivery ? 'delivery-price-free' : 'delivery-price-normal'" v-if="Number(form.sendCost)>0">¥{{ form.sendCost }}</text>
                 <text :class="isFreeDelivery ? 'delivery-price-free' : 'delivery-price-normal'" v-if="Number(form.sendCost)>0">¥{{ form.sendCost }}</text>
                 <text v-if="isFreeDelivery" class="free-delivery-tag">¥0</text>
                 <text v-if="isFreeDelivery" class="free-delivery-tag">¥0</text>
-                <text v-if="showDeliveryPolicy" class="delivery-policy-link" @click="showDeliveryPolicyModal">免费配送范围</text>
+                <text v-if="showDeliveryPolicy" class="delivery-policy-link" @click="showDeliveryPolicyModal">免跑腿费条件</text>
               </view>
               </view>
           </tui-list-cell>
           </tui-list-cell>
           
           
@@ -235,6 +235,10 @@ export default {
       type: Number,
       type: Number,
       default: 0
       default: 0
     },
     },
+    freightType:{
+      type: Number,
+      default: 1
+    },
     showDistance: {
     showDistance: {
       type: Number,
       type: Number,
       default: 0
       default: 0