...
|
...
|
@@ -6,6 +6,7 @@ import com.yohoufo.common.utils.DateUtil; |
|
|
import com.yohoufo.dal.order.OrdersPayMapper;
|
|
|
import com.yohoufo.dal.order.model.OrdersPay;
|
|
|
import com.yohoufo.order.mq.DelayTime;
|
|
|
import com.yohoufo.order.service.proxy.DeliveryMinutesService;
|
|
|
import org.springframework.beans.factory.annotation.Autowired;
|
|
|
import org.springframework.stereotype.Service;
|
|
|
|
...
|
...
|
@@ -18,12 +19,16 @@ public class OrdersPayService { |
|
|
@Autowired
|
|
|
private OrdersPayMapper ordersPayMapper;
|
|
|
|
|
|
@Autowired
|
|
|
private DeliveryMinutesService deliveryMinutesService;
|
|
|
|
|
|
public TimeoutBo getDeliverLeftTime(int buyerUid, long orderCode){
|
|
|
OrdersPay ordersPay = ordersPayMapper.selectOrdersPay(orderCode, buyerUid);
|
|
|
if (ordersPay == null){
|
|
|
return null;
|
|
|
}
|
|
|
int timelimit = DelayTime.MINUTES_36_HOURS * 60;
|
|
|
//int timelimit = DelayTime.MINUTES_36_HOURS * 60;
|
|
|
int timelimit = deliveryMinutesService.getDeliverMinutesThird();
|
|
|
Integer createTime = ordersPay.getCreateTime();
|
|
|
|
|
|
int left = timelimit - (DateUtil.getCurrentTimeSecond()-createTime);
|
...
|
...
|
|