Commit 4e1b7234 authored by 曾水平's avatar 曾水平

优化

parent cf4043b0
...@@ -90,7 +90,7 @@ public class Open2DuibaController { ...@@ -90,7 +90,7 @@ public class Open2DuibaController {
public Result<String> autologin(@RequestBody AutologinParam autologinParam) { public Result<String> autologin(@RequestBody AutologinParam autologinParam) {
try { try {
LOGGER.info("autologin,autologinParam={}", JSON.toJSONString(autologinParam)); LOGGER.info("autologin,autologinParam={}", JSON.toJSONString(autologinParam));
JdShopEnum jdShopEnum = JdShopEnum.DUIBA; JdShopEnum jdShopEnum = JdShopEnum.BOSIDENG;
Long shopId = Optional.ofNullable(autologinParam.getShopId()).filter(aLong -> aLong != 0L).orElse(jdShopEnum.getShopId()); Long shopId = Optional.ofNullable(autologinParam.getShopId()).filter(aLong -> aLong != 0L).orElse(jdShopEnum.getShopId());
Long venderId = Optional.ofNullable(autologinParam.getVenderId()).filter(aLong -> aLong != 0L).orElse(jdShopEnum.getVenderId()); Long venderId = Optional.ofNullable(autologinParam.getVenderId()).filter(aLong -> aLong != 0L).orElse(jdShopEnum.getVenderId());
String token = autologinParam.getToken(); String token = autologinParam.getToken();
...@@ -304,7 +304,7 @@ public class Open2DuibaController { ...@@ -304,7 +304,7 @@ public class Open2DuibaController {
String pin = convert2Pin(appEnum, accessToken.getAccessToken(), uid); String pin = convert2Pin(appEnum, accessToken.getAccessToken(), uid);
Result<Boolean> sendCouponResult = jdApiUtil.pushCoupon(appEnum, accessToken.getAccessToken(), couponId, pin, uuid); Result<Boolean> sendCouponResult = jdApiUtil.pushCoupon(appEnum, accessToken.getAccessToken(), couponId, pin, uuid);
LOGGER.info("发放优惠券,sendCouponResult={},uid={},pin={}", JSON.toJSONString(sendCouponResult), uid, pin); LOGGER.info("发放优惠券,sendCouponResult={},uid={},pin={},uuid={}", JSON.toJSONString(sendCouponResult), uid, pin, uuid);
if (sendCouponResult.getSuccess()) { //发券失败 if (sendCouponResult.getSuccess()) { //发券失败
return ResultBuilder.fail(sendCouponResult.getDesc()); return ResultBuilder.fail(sendCouponResult.getDesc());
} }
......
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