shish 3 lat temu
rodzic
commit
071c32665a
1 zmienionych plików z 7 dodań i 0 usunięć
  1. 7 0
      biz-hd/purchase/classes/PurchaseClass.php

+ 7 - 0
biz-hd/purchase/classes/PurchaseClass.php

@@ -65,8 +65,15 @@ class PurchaseClass extends BaseClass
         $shopLat = isset($shop->lat) ? $shop->lat : '';
         $shopLong = isset($shop->long) ? $shop->long : '';
 
+        if (empty($shopLat) || empty($shopLong)) {
+            util::fail('请完善门店地址');
+        }
+
         $ghsShopLat = isset($ghsShop->lat) ? $ghsShop->lat : '';
         $ghsShopLong = isset($ghsShop->long) ? $ghsShop->long : '';
+        if (empty($ghsShopLat) || empty($ghsShopLong)) {
+            util::fail('商家地址有问题');
+        }
 
         //跑腿费用设置,基础费用8—10元,3—100公里每公里增加2元,超过5公斤,5—21公斤每公斤增加2元