|
|
|
@ -1,13 +1,12 @@ |
|
|
|
|
package com.hai.order.service.impl; |
|
|
|
|
|
|
|
|
|
import com.alibaba.fastjson.JSON; |
|
|
|
|
import com.alibaba.fastjson.JSONObject; |
|
|
|
|
import com.hai.common.exception.ErrorCode; |
|
|
|
|
import com.hai.common.exception.ErrorHelp; |
|
|
|
|
import com.hai.common.exception.SysCode; |
|
|
|
|
import com.hai.config.WxOrderConfig; |
|
|
|
|
import com.hai.entity.HighChildOrder; |
|
|
|
|
import com.hai.entity.HighGasChannelConfig; |
|
|
|
|
import com.hai.entity.HighMerchantTripartitePlatform; |
|
|
|
|
import com.hai.entity.HighOrder; |
|
|
|
|
import com.hai.entity.*; |
|
|
|
|
import com.hai.enum_type.GasChannel; |
|
|
|
|
import com.hai.enum_type.GasChannelPayPlatformType; |
|
|
|
|
import com.hai.enum_type.MerchantStoreSourceType; |
|
|
|
@ -19,6 +18,8 @@ import com.hai.service.HighGasService; |
|
|
|
|
import com.hai.service.HighMerchantStoreService; |
|
|
|
|
import org.springframework.stereotype.Service; |
|
|
|
|
|
|
|
|
|
import javax.annotation.Resource; |
|
|
|
|
|
|
|
|
|
/** |
|
|
|
|
* @className: payOrderCheckImpl |
|
|
|
|
* @author: HuRui |
|
|
|
@ -27,17 +28,18 @@ import org.springframework.stereotype.Service; |
|
|
|
|
@Service("orderPayBeforeService") |
|
|
|
|
public class OrderPayBeforeServiceImpl implements OrderPayBeforeService { |
|
|
|
|
|
|
|
|
|
@Resource |
|
|
|
|
private HighMerchantStoreService merchantStoreService; |
|
|
|
|
|
|
|
|
|
@Resource |
|
|
|
|
private HighGasService gasService; |
|
|
|
|
|
|
|
|
|
@Resource |
|
|
|
|
private HighGasChannelConfigService gasChannelConfigService; |
|
|
|
|
|
|
|
|
|
@Override |
|
|
|
|
public void payOrderCheck(HighOrder order) { |
|
|
|
|
if (order.getProductType().equals(OrderProductType.PRODUCT_TYPE6.getNumber())) { |
|
|
|
|
// 查询油站
|
|
|
|
|
HighMerchantStoreModel store = merchantStoreService.getMerchantStoreById(order.getHighChildOrderList().get(0).getGoodsId()); |
|
|
|
|
HighMerchantStore store = merchantStoreService.getDetailById(order.getHighChildOrderList().get(0).getGoodsId()); |
|
|
|
|
if (store == null) { |
|
|
|
|
throw ErrorHelp.genException(SysCode.System, ErrorCode.COMMON_ERROR, "未知的加油站"); |
|
|
|
|
} |
|
|
|
|