Просмотр исходного кода

fix car pay

release_toaliyun_real
winter 3 лет назад
Родитель
Сommit
f2f0dade89
1 измененных файлов: 10 добавлений и 5 удалений
  1. +10
    -5
      mallinkService/src/main/java/com/iformall/service/park/impl/fute/FuteParkService.java

+ 10
- 5
mallinkService/src/main/java/com/iformall/service/park/impl/fute/FuteParkService.java Просмотреть файл

@@ -195,15 +195,20 @@ public class FuteParkService extends BaseParkService implements ParkAdapterServi
} }
String price = result.getString("price"); String price = result.getString("price");
Integer fee = new BigDecimal(price).multiply(new BigDecimal(100)).intValue(); Integer fee = new BigDecimal(price).multiply(new BigDecimal(100)).intValue();
return new ParkCreatePayOrder(result.getString("parking_order_id"), fee);
return new ParkCreatePayOrder(result.getString("order_id"), fee);
} }


@Override @Override
public ParkPaidNotifyResult notifyPaid(WxPark park,ParkNotifyPaid notifyPaid) throws Exception { public ParkPaidNotifyResult notifyPaid(WxPark park,ParkNotifyPaid notifyPaid) throws Exception {
String result = fute.notifyPaid(park, notifyPaid.getParkOrderNo(), notifyPaid.getFee());
if (StringUtils.isBlank(result)) {
return null;
}
String retCode = fute.notifyPaid(park, notifyPaid.getParkOrderNo(), notifyPaid.getFee());
if (StringUtils.isBlank(retCode)) {
throw new MallinkException(ErrorCode.SYS_SERVER_ERROR.getCode(), "fute notifyPaid error. has no result");
}
JSONObject result = JSON.parseObject(retCode);
if (result.getInteger("state") != 1 ) {
String message = result.getString("errmsg");
throw new MallinkException(ErrorCode.SYS_SERVER_ERROR.getCode(), "fute notifyPaid error."+message);
}
return new ParkPaidNotifyResult(true, result, null); return new ParkPaidNotifyResult(true, result, null);
} }




Загрузка…
Отмена
Сохранить