Commit 2801a611 by huangjinxin

fix:ak,建单优化

1 parent a8f52547
......@@ -134,7 +134,9 @@ public enum StatusCodeEnum {
FENDAN_IS_TRANSCEND("024", "分单超派", false),
RESOURCE_USER_EXISTS_ROLE("025", "用绑定用户的角色不允许删除,需要解绑后才可以删除角色", false);
RESOURCE_USER_EXISTS_ROLE("025", "用绑定用户的角色不允许删除,需要解绑后才可以删除角色", false),
ORDER_EXISTS("026", "订单已存在", false);
/**
* 状态码
......
......@@ -28,8 +28,7 @@ import java.util.Map;
@Slf4j
public class SaasUtils {
// todo
@Value("284c57cbabad4755a9c657885a8df3e2")
@Value("SaaS.ak")
String ak;
@Value("${SaaS.url}")
......
......@@ -135,6 +135,10 @@ public class OrderCreateServiceImpl implements OrderCreateService {
String s = UUID.randomUUID().toString().replace("-", "");
orderId = s.substring(s.length() - 9);
}
OrderInfoEntity byOrderId = orderInfoDao.getByOrderId(req.getOrderId());
if (ObjectUtil.isNull(byOrderId)) {
return Result.failed(StatusCodeEnum.ORDER_EXISTS);
}
// 分单处理
String peaBrand = fixBrand(req.getBrand());
......
......@@ -177,7 +177,7 @@ public class OrderInfoServiceImpl implements OrderInfoService {
location.setAddressId(orderInfo.getAddressId());
} else {
orderInfo.setX(location.getLongitude().toString());
orderInfo.setY(location.getLongitude().toString());
orderInfo.setY(location.getLatitude().toString());
orderInfo.setAddress(location.getAddress());
orderInfo.setAddressId(location.getAddressId());
}
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!