소스 검색

数据源测试环境信息提交

mashengyi 1 년 전
부모
커밋
64ce6d8e74
1개의 변경된 파일28개의 추가작업 그리고 4개의 파일을 삭제
  1. 28 4
      src/main/java/com/jkcredit/invoice/service/lowerservice/impl/NoCarServiceImpl.java

+ 28 - 4
src/main/java/com/jkcredit/invoice/service/lowerservice/impl/NoCarServiceImpl.java

@@ -4,7 +4,25 @@ import cn.com.taiji.sdk.model.comm.protocol.tts.vehicle.VehicleQueryRequest;
 import cn.com.taiji.sdk.model.comm.protocol.tts.vehicle.VehicleQueryResponse;
 import cn.com.taiji.sdk.model.comm.protocol.tts.vehicle.VehicleRegisterRequest;
 import cn.com.taiji.sdk.model.comm.protocol.tts.vehicle.VehicleRegisterResponse;
-import cn.com.taiji.sdk.model.comm.protocol.tts.waybill.*;
+import cn.com.taiji.sdk.model.comm.protocol.tts.waybill.InvoiceProcessingListModel;
+import cn.com.taiji.sdk.model.comm.protocol.tts.waybill.WaybillCountPageRequest;
+import cn.com.taiji.sdk.model.comm.protocol.tts.waybill.WaybillCountQueryRequest;
+import cn.com.taiji.sdk.model.comm.protocol.tts.waybill.WaybillCountQueryResponse;
+import cn.com.taiji.sdk.model.comm.protocol.tts.waybill.WaybillEndRequest;
+import cn.com.taiji.sdk.model.comm.protocol.tts.waybill.WaybillEndResponse;
+import cn.com.taiji.sdk.model.comm.protocol.tts.waybill.WaybillHistoryEndRequest;
+import cn.com.taiji.sdk.model.comm.protocol.tts.waybill.WaybillHistoryEndResponse;
+import cn.com.taiji.sdk.model.comm.protocol.tts.waybill.WaybillHistoryStartRequest;
+import cn.com.taiji.sdk.model.comm.protocol.tts.waybill.WaybillHistoryStartResponse;
+import cn.com.taiji.sdk.model.comm.protocol.tts.waybill.WaybillInvoiceRedQueryModel;
+import cn.com.taiji.sdk.model.comm.protocol.tts.waybill.WaybillInvoiceRedQueryRequest;
+import cn.com.taiji.sdk.model.comm.protocol.tts.waybill.WaybillInvoiceRedQueryResponse;
+import cn.com.taiji.sdk.model.comm.protocol.tts.waybill.WaybillNumFindInvoiceRequest;
+import cn.com.taiji.sdk.model.comm.protocol.tts.waybill.WaybillNumFindInvoiceResponse;
+import cn.com.taiji.sdk.model.comm.protocol.tts.waybill.WaybillOriginEndRequest;
+import cn.com.taiji.sdk.model.comm.protocol.tts.waybill.WaybillOriginEndResponse;
+import cn.com.taiji.sdk.model.comm.protocol.tts.waybill.WaybillStartRequest;
+import cn.com.taiji.sdk.model.comm.protocol.tts.waybill.WaybillStartResponse;
 import com.baomidou.mybatisplus.core.metadata.IPage;
 import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
 import com.jkcredit.invoice.common.CommonConstants;
@@ -287,7 +305,7 @@ public class NoCarServiceImpl implements NoCarService {
         if(StringUtils.isEmpty(waybillStartRequest.getBase64Str())){
             return new RespR(false,"未上传运单文件");
         }
-       if(noCarWayBillDb.getBillwayStatus() == 0){
+       if(null != noCarWayBillDb && noCarWayBillDb.getBillwayStatus() == 0){
             RespR<WaybillOriginEndResponse> responseRespR1 = sendOrgWayBillInfo(noCarWayBill);
             if(responseRespR1.getCode() == 1){
                 noCarWayBill.setBillwayStatus(0);
@@ -344,7 +362,9 @@ public class NoCarServiceImpl implements NoCarService {
      */
     public WaybillStartRequest buildWaybillStartRequest(NoCarWayBill noCarWayBill) {
         WaybillStartRequest waybillStartRequest = new WaybillStartRequest();
-        String companyNum = paramService.getParamsByParamName("REQUEST_COMPANY_NUM").getParamValue();
+        //如果调用上游测试环境, 默认自营平台 10000148
+        //  String companyNum = "10000148";
+       String companyNum = paramService.getParamsByParamName("REQUEST_COMPANY_NUM").getParamValue();
         waybillStartRequest.setCompanyNum(companyNum);
         waybillStartRequest.setNum(noCarWayBill.getBillNum());
         waybillStartRequest.setPlateNum(noCarWayBill.getPlateNum());
@@ -354,6 +374,8 @@ public class NoCarServiceImpl implements NoCarService {
         waybillStartRequest.setDestAddr(noCarWayBill.getDestAddr());
         waybillStartRequest.setPredictEndTime(DateUtil.dateFormate(noCarWayBill.getPredictEndTime()));
         waybillStartRequest.setFee(noCarWayBill.getFee());
+        //如果调用上游测试环境, 抬头 默认抬头,不然调用不通
+        // waybillStartRequest.setTitleType(1);
         waybillStartRequest.setTitleType(noCarWayBill.getTitleType());
         waybillStartRequest.setTaxplayerCode(noCarWayBill.getTaxplayerCode());
         waybillStartRequest.setName(noCarWayBill.getCompanyName());
@@ -623,7 +645,9 @@ public class NoCarServiceImpl implements NoCarService {
     public RespR<WaybillOriginEndResponse> sendOrgWayBillInfo(NoCarWayBill noCarWayBill){
         WaybillOriginEndRequest waybillOriginEndRequest = new WaybillOriginEndRequest();
         waybillOriginEndRequest.setNum(noCarWayBill.getBillNum());
-        waybillOriginEndRequest.setCompanyNum(noCarWayBill.getCompanyNum());
+        //如果调用上游测试环境, 默认自营平台 10000148
+        //waybillOriginEndRequest.setCompanyNum("10000148");
+       waybillOriginEndRequest.setCompanyNum(noCarWayBill.getCompanyNum());
         waybillOriginEndRequest.setBase64Str(noCarWayBill.getBase64Str());
         waybillOriginEndRequest.setWaybillFileName(noCarWayBill.getWaybillFileName());
         if(noCarWayBill.getBase64Str() == null){