mirror of
https://gitee.com/binary/weixin-java-tools.git
synced 2025-08-24 07:23:01 +08:00
#345 修复服务商模式下使用仅有sub_openid时无法预下单的问题.
This commit is contained in:
parent
7bb3a1270d
commit
b7443f41ae
@ -339,8 +339,8 @@ public class WxPayUnifiedOrderRequest extends WxPayBaseRequest {
|
|||||||
// Arrays.toString(TRADE_TYPES), this.getTradeType()));
|
// Arrays.toString(TRADE_TYPES), this.getTradeType()));
|
||||||
// }
|
// }
|
||||||
|
|
||||||
if ("JSAPI".equals(this.getTradeType()) && this.getOpenid() == null) {
|
if ("JSAPI".equals(this.getTradeType()) && this.getOpenid() == null && this.getSubOpenid() == null) {
|
||||||
throw new WxPayException("当 trade_type是'JSAPI'时未指定openid");
|
throw new WxPayException("当 trade_type是'JSAPI'时未指定openid或sub_openid");
|
||||||
}
|
}
|
||||||
|
|
||||||
if ("NATIVE".equals(this.getTradeType()) && this.getProductId() == null) {
|
if ("NATIVE".equals(this.getTradeType()) && this.getProductId() == null) {
|
||||||
|
Loading…
Reference in New Issue
Block a user