Commit 6cddac7c authored by terrfly's avatar terrfly
Browse files

添加订单过期时间 单位: 秒 ; 支持接口传入;

parent 76e0389c
......@@ -231,7 +231,13 @@ public abstract class AbstractPayOrderController extends ApiController {
Date nowDate = new Date();
payOrder.setExpiredTime(DateUtil.offsetHour(nowDate, 2)); //订单过期时间 默认两个小时
//订单过期时间 单位: 秒
if(rq.getExpiredTime() != null){
payOrder.setExpiredTime(DateUtil.offsetSecond(nowDate, rq.getExpiredTime()));
}else{
payOrder.setExpiredTime(DateUtil.offsetHour(nowDate, 2)); //订单过期时间 默认两个小时
}
payOrder.setCreatedAt(nowDate); //订单创建时间
return payOrder;
}
......
......@@ -72,8 +72,8 @@ public class UnifiedOrderRQ extends AbstractMchAppRQ {
/** 跳转通知地址 **/
private String returnUrl;
/** 订单失效时间 **/
private String expiredTime;
/** 订单失效时间, 单位:秒 **/
private Integer expiredTime;
/** 特定渠道发起额外参数 **/
private String channelExtra;
......
Supports Markdown
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