Commit d6a97012 by weijiguang

下单时校验订单中sku数量

parent 770c75ff
......@@ -109,7 +109,7 @@ public class WeixinController {
boolean testFlag = false;
if (loginUser != null) {
Customer customer = customerService.selectCustById(loginUser.getOpenId());
if(customer!=null) {
if (customer != null) {
testFlag = customer.getTestFlag();
}
}
......@@ -123,7 +123,7 @@ public class WeixinController {
boolean testFlag = false;
if (loginUser != null) {
Customer customer = customerService.selectCustById(loginUser.getOpenId());
if(customer!=null) {
if (customer != null) {
testFlag = customer.getTestFlag();
}
}
......
......@@ -95,6 +95,7 @@ public class AppServiceImpl {
}
// 超出最大配送距离10KM 或 超出店铺设置最大距离
if (!StringUtils.isEmpty(lng) && !StringUtils.isEmpty(lat)) {
double realDistance = DistanceUtil.getRealDistance(Double.parseDouble(lng), Double.parseDouble(lat), Double.parseDouble(shop.getLng()), Double.parseDouble(shop.getLat()));
double realKm = realDistance / 1000;
double shopLimit = shop.getDistanceLimit() == null ? 0 : shop.getDistanceLimit();
......@@ -103,6 +104,7 @@ public class AppServiceImpl {
shop.setStateDesc("距离较远,门店暂停接单");
return false;
}
}
shop.setOrderState(1);
return true;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment